@designsystem-se/af 41.0.1-beta.1 → 41.0.1-beta.2

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.
Files changed (30) hide show
  1. package/components/digi-calendar-datepicker.js +4 -4
  2. package/components/digi-calendar.js +1 -1
  3. package/components/digi-form-file-upload.js +1 -1
  4. package/components/digi-form-input-search.js +2 -2
  5. package/components/digi-form-input.js +1 -1
  6. package/components/digi-form-label.js +1 -1
  7. package/components/digi-form-select-filter.js +2 -2
  8. package/components/digi-form-select.js +1 -1
  9. package/components/digi-form-textarea.js +1 -1
  10. package/components/{p-2QoafdpB.js → p-B7_lQTCU.js} +19 -5
  11. package/components/{p-CsnkG9DM.js → p-C9upnau2.js} +1 -1
  12. package/components/{p-DL56hj-Q.js → p-DdGvmUiV.js} +2 -2
  13. package/components/{p-CZNczF84.js → p-stxQJv63.js} +1 -1
  14. package/dist/cjs/digi-arbetsformedlingen.cjs.js +1 -1
  15. package/dist/cjs/digi-button_83.cjs.entry.js +11 -4
  16. package/dist/cjs/loader.cjs.js +1 -1
  17. package/dist/collection/components/_form/form-label/form-label.js +12 -4
  18. package/dist/collection/design-tokens/components/_logo.variables.scss +18 -14
  19. package/dist/collection/styles/project.json +1 -2
  20. package/dist/digi-arbetsformedlingen/digi-arbetsformedlingen.esm.js +1 -1
  21. package/dist/digi-arbetsformedlingen/p-189d472b.entry.js +1 -0
  22. package/dist/digi-arbetsformedlingen/styles/project.json +1 -2
  23. package/dist/esm/digi-arbetsformedlingen.js +1 -1
  24. package/dist/esm/digi-button_83.entry.js +11 -4
  25. package/dist/esm/loader.js +1 -1
  26. package/dist/types/components/_form/form-label/form-label.d.ts +2 -1
  27. package/hydrate/index.js +12 -4
  28. package/hydrate/index.mjs +12 -4
  29. package/package.json +1 -1
  30. package/dist/digi-arbetsformedlingen/p-5c8111ef.entry.js +0 -1
@@ -30,7 +30,7 @@ export class FormLabel {
30
30
  this.afAnnounceIfOptionalText = _t.optional.toLowerCase();
31
31
  }
32
32
  componentWillLoad() {
33
- this.warnIfMissingLabel();
33
+ this.setLabelText();
34
34
  this.validateFor();
35
35
  this.handleSlotVisibility();
36
36
  }
@@ -39,7 +39,8 @@ export class FormLabel {
39
39
  logger.warn(`digi-form-label must have a for attribute. Please add a for attribute using af-for`, this.hostElement);
40
40
  }
41
41
  }
42
- warnIfMissingLabel() {
42
+ setLabelText() {
43
+ this.labelText = `${this.afLabel} ${this.requiredText}`;
43
44
  if (!this.afLabel) {
44
45
  logger.warn(`digi-form-label must have a label. Please add a label using af-label`, this.hostElement);
45
46
  }
@@ -61,7 +62,7 @@ export class FormLabel {
61
62
  }
62
63
  }
63
64
  render() {
64
- return (h("div", { key: 'd505cd974e5fad197c27502bbd5a69e03b6da4c9', class: "digi-form-label" }, h("div", { key: '438d01b31f6b2814ae6a1ca04c824ea08ea2be23', class: "digi-form-label__label-group" }, this.afFor && this.afLabel && (h("label", { key: 'f339da21e44bd1d80bc2bcd71f2a7b85ded421a3', class: "digi-form-label__label", htmlFor: this.afFor, id: this.afId }, h("span", { key: '49c6e41049caafd257d39c8e4bbd61054e618ac9', tabindex: "-1", class: "digi-form-label__label--label" }, `${this.afLabel} ${this.requiredText}`), this.afDescription && (h("span", { key: '857cf559d405dc425fb16289d216cc5ed500775f', tabindex: "-1", class: "digi-form-label__label--description" }, this.afDescription)))), this.hasActionSlot && (h("div", { key: '11a7132c78dc5467b25c8a09724a1d13f3a324c3', class: "digi-form-label__actions" }, h("slot", { key: 'f499d1b9d31ccc825723a880bea8f110658b462d', name: "actions" }))))));
65
+ return (h("div", { key: '78c3c9cc7609ede22abcd68c16514c85b52c945e', class: "digi-form-label" }, h("div", { key: '5bd7a74e6508c261f489716673f011391bf7c0d8', class: "digi-form-label__label-group" }, this.afFor && this.afLabel && (h("label", { key: '6952422ebe4e447857befae6116fd7336046dc1f', class: "digi-form-label__label", htmlFor: this.afFor, id: this.afId }, h("span", { key: '2da61e9396c9c20b40ee4d80c21ae96e2a491e8f', tabindex: "-1", class: "digi-form-label__label--label" }, this.labelText), this.afDescription && (h("span", { key: '858d2ae39681662c278352e42b7bccb511279bd0', tabindex: "-1", class: "digi-form-label__label--description" }, this.afDescription)))), this.hasActionSlot && (h("div", { key: '7719bef7cfe38637a5ef4b71d5e9a6237ed48ff2', class: "digi-form-label__actions" }, h("slot", { key: '37bd2332a7d4e7fa15c4ff61a0cc26c92bed08d8', name: "actions" }))))));
65
66
  }
66
67
  static get is() { return "digi-form-label"; }
67
68
  static get encapsulation() { return "scoped"; }
@@ -261,6 +262,7 @@ export class FormLabel {
261
262
  }
262
263
  static get states() {
263
264
  return {
265
+ "labelText": {},
264
266
  "hasActionSlot": {}
265
267
  };
266
268
  }
@@ -271,7 +273,13 @@ export class FormLabel {
271
273
  "methodName": "validateFor"
272
274
  }, {
273
275
  "propName": "afLabel",
274
- "methodName": "warnIfMissingLabel"
276
+ "methodName": "setLabelText"
277
+ }, {
278
+ "propName": "afRequired",
279
+ "methodName": "setLabelText"
280
+ }, {
281
+ "propName": "afAnnounceIfOptional",
282
+ "methodName": "setLabelText"
275
283
  }];
276
284
  }
277
285
  }
@@ -1,16 +1,20 @@
1
- @mixin digi-title-logo--variables() {
2
- --digi--title-logo-text-color: var(--digi--color--text--primary);
3
- --digi--title-logo-font-weight: var(--digi--global--typography--font-weight--bold);
4
- --digi--title-logo-font-size: var(--digi--typography--title-logo--font-size--mobile);
5
- --digi--title-logo-font-size-small: var(--digi--global--typography--font-size--large);
6
- --digi--title-logo-line-height-small: 1.25rem;
7
- --digi--title-logo-symbol-color: var(--digi--color--logotype--primary--symbol);
8
- --digi--title-logo-symbol-width: 36px;
9
- --digi--title-logo-symbol-height: 36px;
10
- --digi--title-logo-symbol-width-mobile: 44px;
11
- --digi--title-logo-symbol-height-mobile: 44px;
12
- --digi--title-logo-text-height: 40px;
13
- --digi--title-logo-border-width: var(--digi--global--border-width--base);
14
- --digi--title-logo-vertical-padding: 1.375rem;
1
+ @use '../../../../../../styles/src/digi-styles.utils' as *;
2
+
3
+ @mixin digi-logo--variables() {
4
+ --digi--logo--img--min-width: #{rem(256)};
5
+ --digi--logo--img--max-width:#{rem(292)};
6
+ --digi--logo--img--max-width--large: #{rem(368)};
7
+ --digi--logo--img--max-width--system: #{rem(44)};
8
+
9
+ --digi--logo--padding: 1.375rem;
10
+ --digi--logo--padding--wide: var(--digi--gutter--larger);
11
+ --digi--logo--padding--large: var(--digi--gutter--medium);
12
+ --digi--logo--padding--large--wide: var(--digi--gutter--larger);
13
+
14
+ --digi--logo--primary--symbol: var(--digi--color--logotype--primary--symbol);
15
+ --digi--logo--secondary--symbol: var(--digi--color--logotype--secondary--symbol);
16
+ --digi--logo--primary--text: var(--digi--color--logotype--primary--text);
17
+ --digi--logo--secondary--text: var(--digi--color--logotype--secondary--text);
18
+ }g: 1.375rem;
15
19
  --digi--title-logo-gap: 9px;
16
20
  }
@@ -5,8 +5,7 @@
5
5
  "projectType": "library",
6
6
  "targets": {
7
7
  "lint": {
8
- "executor": "@nx/eslint:lint",
9
- "ignores": ["**/*"]
8
+ "executor": "nx:noop"
10
9
  }
11
10
  }
12
11
  }