@schukai/monster 3.101.2 → 3.102.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,27 @@
2
2
 
3
3
 
4
4
 
5
+ ## [3.102.0] - 2025-01-27
6
+
7
+ ### Add Features
8
+
9
+ - new databind for int[] and string[]
10
+ - **select:** new ignoreValues feature [#287](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/287)
11
+ ### Changes
12
+
13
+ - close issue [#285](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/285) [#286](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/286)
14
+
15
+
16
+
17
+ ## [3.101.3] - 2025-01-27
18
+
19
+ ### Bug Fixes
20
+
21
+ - add part attribute to field-set and remove min-with from the datatable
22
+ - update column selection [#286](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/286) [#266](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/266)
23
+
24
+
25
+
5
26
  ## [3.101.2] - 2025-01-23
6
27
 
7
28
  ### Bug Fixes
package/package.json CHANGED
@@ -1 +1 @@
1
- {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.6.13","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"3.101.2"}
1
+ {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.6.13","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"3.102.0"}
@@ -268,19 +268,15 @@ function attachResizeObserver() {
268
268
  });
269
269
 
270
270
  requestAnimationFrame(() => {
271
-
272
271
  let parent = this.parentNode;
273
- while(!(parent instanceof HTMLElement) && parent !== null) {
272
+ while (!(parent instanceof HTMLElement) && parent !== null) {
274
273
  parent = parent.parentNode;
275
274
  }
276
275
 
277
276
  if (parent instanceof HTMLElement) {
278
277
  this[resizeObserverSymbol].observe(parent);
279
278
  }
280
-
281
-
282
279
  });
283
-
284
280
  }
285
281
 
286
282
  /**
@@ -291,17 +291,14 @@ class DataTable extends CustomElement {
291
291
  });
292
292
 
293
293
  requestAnimationFrame(() => {
294
-
295
294
  let parent = this.parentNode;
296
- while(!(parent instanceof HTMLElement) && parent !== null) {
295
+ while (!(parent instanceof HTMLElement) && parent !== null) {
297
296
  parent = parent.parentNode;
298
297
  }
299
298
 
300
299
  if (parent instanceof HTMLElement) {
301
300
  this[resizeObserverSymbol].observe(parent);
302
301
  }
303
-
304
-
305
302
  });
306
303
  }
307
304
 
@@ -1145,7 +1142,7 @@ function initGridAndStructs(hostConfig, headerOrderMap) {
1145
1142
  index: i,
1146
1143
  mode: mode,
1147
1144
  grid: grid,
1148
- labelKey: labelKey,
1145
+ labelKey: labelKey+ "-"+i,
1149
1146
  direction: direction,
1150
1147
  features: features,
1151
1148
  orderTemplate: orderTemplate,
@@ -1312,9 +1309,12 @@ function updateGrid() {
1312
1309
  for (let i = 0; i < headers.length; i++) {
1313
1310
  const header = headers[i];
1314
1311
 
1315
- if (header.mode === ATTRIBUTE_DATATABLE_MODE_HIDDEN) {
1316
- styles += `[data-monster-role=datatable]>[data-monster-head="${header.labelKey}"] { display: none; }\n`;
1312
+ if (
1313
+ header.mode === ATTRIBUTE_DATATABLE_MODE_HIDDEN &&
1314
+ header.mode !== ATTRIBUTE_DATATABLE_MODE_FIXED
1315
+ ) {
1317
1316
  styles += `[data-monster-role=datatable-headers]>[data-monster-index="${header.index}"] { display: none; }\n`;
1317
+ styles += `[data-monster-role=datatable] > div:nth-child(${headers.length}n+${i+1}) { display: none; }\n`;
1318
1318
  } else {
1319
1319
  gridTemplateColumns += `${header.grid} `;
1320
1320
  }
@@ -1465,7 +1465,7 @@ function getTemplate() {
1465
1465
  data-monster-attributes="class path:features.help | ?::hidden"
1466
1466
  data-monster-replace="path:labels.helpText"
1467
1467
  ></monster-context-help>
1468
- <a href="#" data-monster-attributes="class path:features.copyAll | ?::hidden"
1468
+ <a href="#" data-monster-attributes="class path:features.copyAll | ?::copyAllHidden"
1469
1469
  data-monster-role="copy-all" data-monster-replace="path:labels.copyAll">Copy all</a>
1470
1470
  <monster-column-bar
1471
1471
  data-monster-attributes="class path:features.settings | ?::hidden"></monster-column-bar>
@@ -690,9 +690,8 @@ function attachResizeObserver() {
690
690
  });
691
691
 
692
692
  requestAnimationFrame(() => {
693
-
694
693
  let parent = this.parentNode;
695
- while(!(parent instanceof HTMLElement) && parent !== null) {
694
+ while (!(parent instanceof HTMLElement) && parent !== null) {
696
695
  parent = parent.parentNode;
697
696
  }
698
697
 
@@ -700,7 +699,6 @@ function attachResizeObserver() {
700
699
  this[resizeObserverSymbol].observe(parent);
701
700
  }
702
701
  });
703
-
704
702
  }
705
703
 
706
704
  function disconnectResizeObserver() {
@@ -108,7 +108,7 @@
108
108
  height: 16px;
109
109
  margin: 2px 3px 0 5px;
110
110
  padding-top: 4px;
111
- background-color: var(--monster-color-primary-1);
111
+ background-color: var(--monster-color-primary-1);
112
112
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M0 1.5A1.5 1.5 0 0 1 1.5 0h13A1.5 1.5 0 0 1 16 1.5v13a1.5 1.5 0 0 1-1.5 1.5h-13A1.5 1.5 0 0 1 0 14.5v-13zM1.5 1a.5.5 0 0 0-.5.5v13a.5.5 0 0 0 .5.5H5V1H1.5zM10 15V1H6v14h4zm1 0h3.5a.5.5 0 0 0 .5-.5v-13a.5.5 0 0 0-.5-.5H11v14z' fill='%23000'/%3E%3C/svg%3E");
113
113
  mask-size: cover;
114
114
  }
@@ -40,7 +40,7 @@
40
40
  overflow-y: visible;
41
41
  padding: 20px;
42
42
  box-sizing: border-box;
43
- min-width: fit-content;
43
+
44
44
  @mixin text;
45
45
 
46
46
  & .bar {
@@ -254,6 +254,10 @@
254
254
  }
255
255
 
256
256
  .hidden {
257
+ display: none;
258
+ }
259
+
260
+ .copyAllHidden {
257
261
  display: none !important;
258
262
  }
259
263