Skip to content
Snippets Groups Projects
Verified Commit 9e40acdd authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

fix: css issues

parent 554c5286
No related branches found
No related tags found
No related merge requests found
Showing
with 80 additions and 58 deletions
...@@ -13,11 +13,14 @@ import "../../../source/components/style/form.pcss"; ...@@ -13,11 +13,14 @@ import "../../../source/components/style/form.pcss";
import "../../../source/components/datatable/datasource/rest.mjs"; import "../../../source/components/datatable/datasource/rest.mjs";
import "../../../source/components/datatable/save-button.mjs"; import "../../../source/components/datatable/save-button.mjs";
import "../../../source/components/form/form.mjs"; import "../../../source/components/form/form.mjs";
import "../../../source/components/form/field-set.mjs"; import "../../../source/components/form/field-set.mjs";
import "../../../source/components/form/select.mjs"; import "../../../source/components/form/select.mjs";
import "../../../source/components/form/context-help.mjs"; import "../../../source/components/form/context-help.mjs";
import "../../../source/components/form/context-error.mjs"; import "../../../source/components/form/context-error.mjs";
import {domReady} from "../../../source/dom/ready.mjs"; import {domReady} from "../../../source/dom/ready.mjs";
domReady.then(() => { domReady.then(() => {
......
...@@ -68,9 +68,6 @@ ...@@ -68,9 +68,6 @@
<div slot="bar" class="monster-button-group"> <div slot="bar" class="monster-button-group">
<div class="row-action-buttons">
<monster-button data-monster-role="row-action-button" id="action-button-1">ACTION</monster-button>
</div>
<monster-embedded-pagination data-monster-datasource-selector="#ds277"></monster-embedded-pagination> <monster-embedded-pagination data-monster-datasource-selector="#ds277"></monster-embedded-pagination>
<monster-datasource-status <monster-datasource-status
......
...@@ -35,7 +35,7 @@ import "../../../source/components/layout/tabs.mjs"; ...@@ -35,7 +35,7 @@ import "../../../source/components/layout/tabs.mjs";
import "../../../source/components/datatable/datatable.mjs"; import "../../../source/components/datatable/datatable.mjs";
import "../../../source/components/notify/monitor-attribute-errors.mjs"; import "../../../source/components/notify/monitor-attribute-errors.mjs";
const actionButton = document.getElementById("action-button-1") //const actionButton = document.getElementById("action-button-1")
const datatable = document.getElementById("dt277"); const datatable = document.getElementById("dt277");
const eventHandler = function () { const eventHandler = function () {
......
...@@ -342,7 +342,9 @@ class DataTable extends CustomElement { ...@@ -342,7 +342,9 @@ class DataTable extends CustomElement {
initControlReferences.call(this); initControlReferences.call(this);
initEventHandler.call(this); initEventHandler.call(this);
getSlottedElements.call(this,"[data-monster-role=row-action-button]","bar").forEach((i,e) => { getSlottedElements
.call(this, "[data-monster-role=row-action-button]", "bar")
.forEach((i, e) => {
if (e instanceof HTMLElement) { if (e instanceof HTMLElement) {
e.style.visibility = "hidden"; e.style.visibility = "hidden";
e.style.width = "max-content"; e.style.width = "max-content";
...@@ -354,7 +356,7 @@ class DataTable extends CustomElement { ...@@ -354,7 +356,7 @@ class DataTable extends CustomElement {
pN.style.justifyContent = "flex-start"; pN.style.justifyContent = "flex-start";
} }
} }
}) });
getHostConfig getHostConfig
.call(this, getColumnVisibilityConfigKey) .call(this, getColumnVisibilityConfigKey)
...@@ -887,7 +889,7 @@ function initEventHandler() { ...@@ -887,7 +889,7 @@ function initEventHandler() {
return; return;
} }
const parentNode= element.parentNode const parentNode = element.parentNode;
if (!(parentNode instanceof HTMLDivElement)) { if (!(parentNode instanceof HTMLDivElement)) {
return; return;
} }
...@@ -929,13 +931,15 @@ function initEventHandler() { ...@@ -929,13 +931,15 @@ function initEventHandler() {
`[data-monster-role="select-all"]`, `[data-monster-role="select-all"]`,
); );
getSlottedElements.call(this,"[data-monster-role=row-action-button]","bar").forEach((i,e) => { getSlottedElements
.call(this, "[data-monster-role=row-action-button]", "bar")
.forEach((i, e) => {
const selected = self.getSelectedRows(); const selected = self.getSelectedRows();
const mode = (selected.length === 0) ? "hidden" : "visible"; const mode = selected.length === 0 ? "hidden" : "visible";
if (e instanceof HTMLElement) { if (e instanceof HTMLElement) {
e.style.visibility = mode; e.style.visibility = mode;
} }
}) });
if (selectAll) { if (selectAll) {
selectAll.checked = allSelected; selectAll.checked = allSelected;
...@@ -965,12 +969,13 @@ function initEventHandler() { ...@@ -965,12 +969,13 @@ function initEventHandler() {
fireCustomEvent(this, "monster-datatable-all-rows-deselected", {}); fireCustomEvent(this, "monster-datatable-all-rows-deselected", {});
} }
getSlottedElements.call(this,"[data-monster-role=row-action-button]","bar").forEach((i,e) => { getSlottedElements
.call(this, "[data-monster-role=row-action-button]", "bar")
.forEach((i, e) => {
if (e instanceof HTMLElement) { if (e instanceof HTMLElement) {
e.style.visibility = mode ? "visible" : "hidden"; e.style.visibility = mode ? "visible" : "hidden";
} }
}) });
fireCustomEvent(this, "monster-datatable-selection-changed", {}); fireCustomEvent(this, "monster-datatable-selection-changed", {});
} }
......
...@@ -32,6 +32,7 @@ import { Datasource } from "./datasource.mjs"; ...@@ -32,6 +32,7 @@ import { Datasource } from "./datasource.mjs";
import { Rest as RestDatasource } from "./datasource/rest.mjs"; import { Rest as RestDatasource } from "./datasource/rest.mjs";
import { BadgeStyleSheet } from "../stylesheet/badge.mjs"; import { BadgeStyleSheet } from "../stylesheet/badge.mjs";
import { SaveButtonStyleSheet } from "./stylesheet/save-button.mjs"; import { SaveButtonStyleSheet } from "./stylesheet/save-button.mjs";
import "../form/state-button.mjs";
import { import {
handleDataSourceChanges, handleDataSourceChanges,
......
Source diff could not be displayed: it is too large. Options to address this: view the blob.
...@@ -90,7 +90,7 @@ class ActionButton extends PopperButton { ...@@ -90,7 +90,7 @@ class ActionButton extends PopperButton {
button: "<slot></slot>", button: "<slot></slot>",
}, },
classes: { classes: {
button: "monster-button-primary-1", button: "monster-button-primary",
}, },
buttons: [], buttons: [],
}); });
......
...@@ -211,7 +211,7 @@ class Button extends CustomControl { ...@@ -211,7 +211,7 @@ class Button extends CustomControl {
button: "<slot></slot>", button: "<slot></slot>",
}, },
classes: { classes: {
button: "monster-button-primary-1", button: "monster-button-outline-primary",
}, },
disabled: false, disabled: false,
actions: { actions: {
......
...@@ -161,7 +161,6 @@ class MessageStateButton extends Popper { ...@@ -161,7 +161,6 @@ class MessageStateButton extends Popper {
for (const [, mode] of Object.entries(modes)) { for (const [, mode] of Object.entries(modes)) {
initEventHandlerByMode.call(this, mode); initEventHandlerByMode.call(this, mode);
} }
} }
/** /**
......
...@@ -13,9 +13,7 @@ ...@@ -13,9 +13,7 @@
*/ */
import { instanceSymbol } from "../../constants.mjs"; import { instanceSymbol } from "../../constants.mjs";
import { import { ATTRIBUTE_ROLE } from "../../dom/constants.mjs";
ATTRIBUTE_ROLE,
} from "../../dom/constants.mjs";
import { import {
assembleMethodSymbol, assembleMethodSymbol,
registerCustomElement, registerCustomElement,
...@@ -148,7 +146,6 @@ class PopperButton extends Popper { ...@@ -148,7 +146,6 @@ class PopperButton extends Popper {
role: null, role: null,
label: null, label: null,
}, },
}); });
} }
......
...@@ -80,7 +80,6 @@ class StateButton extends Button { ...@@ -80,7 +80,6 @@ class StateButton extends Button {
role: null, role: null,
label: null, label: null,
}, },
}); });
} }
......
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment