web: fix console log leftover (#9096)
* web: disallow console.log Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix easy fixes Signed-off-by: Jens Langhammer <jens@goauthentik.io> --------- Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
@ -32,6 +32,7 @@
|
||||
"varsIgnorePattern": "^_",
|
||||
"caughtErrorsIgnorePattern": "^_"
|
||||
}
|
||||
]
|
||||
],
|
||||
"no-console": ["error", { "allow": ["debug", "warn", "error"] }]
|
||||
}
|
||||
}
|
||||
|
@ -48,7 +48,7 @@ const displayMessage = (result: any) => {
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
const displayMessage2 = (result: any) => {
|
||||
console.log("Huh.");
|
||||
console.debug("Huh.");
|
||||
const doc = new DOMParser().parseFromString(`<p><i>Behavior</i>: ${result}</p>`, "text/xml");
|
||||
const target = document.querySelector("#action-button-message-pad-2");
|
||||
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
||||
|
@ -44,7 +44,7 @@ const container = (testItem: TemplateResult) =>
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
const handleMoveChanged = (result: any) => {
|
||||
console.log(result);
|
||||
console.debug(result);
|
||||
const target = document.querySelector("#action-button-message-pad");
|
||||
target!.append(
|
||||
new DOMParser().parseFromString(
|
||||
|
@ -110,20 +110,15 @@ export class RoleAssignedObjectPermissionTable extends Table<RoleAssignedObjectP
|
||||
this.modelPermissions?.results.forEach((perm) => {
|
||||
const granted =
|
||||
item.permissions.filter((uperm) => uperm.codename === perm.codename).length > 0;
|
||||
baseRow.push(html`
|
||||
<ak-action-button
|
||||
.apiRequest=${async () => {
|
||||
console.log(granted);
|
||||
}}
|
||||
class="pf-m-link"
|
||||
>
|
||||
${granted
|
||||
? html`<pf-tooltip position="top" content=${msg("Directly assigned")}
|
||||
>✓</pf-tooltip
|
||||
>`
|
||||
: html`X`}
|
||||
</ak-action-button>
|
||||
`);
|
||||
baseRow.push(
|
||||
html`${granted
|
||||
? html`<pf-tooltip
|
||||
position="top"
|
||||
content=${msg("Directly assigned")}
|
||||
>✓</pf-tooltip
|
||||
>`
|
||||
: html`X`} `,
|
||||
);
|
||||
});
|
||||
return baseRow;
|
||||
}
|
||||
|
Reference in New Issue
Block a user