@justeattakeaway/pie-divider 1.5.13 → 1.5.15

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.
@@ -34,7 +34,7 @@
34
34
  "type": {
35
35
  "text": "DefaultProps"
36
36
  },
37
- "default": "{\n variant: 'default',\n orientation: 'horizontal',\n label: '',\n}"
37
+ "default": "{\r\n variant: 'default',\r\n orientation: 'horizontal',\r\n label: '',\r\n}"
38
38
  }
39
39
  ],
40
40
  "exports": [
package/dist/index.js CHANGED
@@ -1,15 +1,15 @@
1
- import { LitElement as u, unsafeCSS as m, html as h } from "lit";
1
+ import { LitElement as m, unsafeCSS as u, html as h } from "lit";
2
2
  import { property as b } from "lit/decorators.js";
3
- import { classMap as g } from "lit/directives/class-map.js";
4
- import { validPropertyValues as f, safeCustomElement as w } from "@justeattakeaway/pie-webc-core";
5
- const v = class v extends u {
3
+ import { classMap as f } from "lit/directives/class-map.js";
4
+ import { validPropertyValues as g, safeCustomElement as y } from "@justeattakeaway/pie-webc-core";
5
+ const v = class v extends m {
6
6
  willUpdate() {
7
7
  this.getAttribute("v") || this.setAttribute("v", v.v);
8
8
  }
9
9
  };
10
- v.v = "1.5.13";
10
+ v.v = "1.5.15";
11
11
  let p = v;
12
- const x = "*,*:after,*:before{box-sizing:inherit}:host{display:block}:host([orientation=vertical]){height:100%}.c-divider{--divider-bg-color: var(--dt-color-divider-default);--divider-width: 100%;--divider-min-width: 16px;--divider-height: 1px;--divider-label-max-width: 90%;--divider-font-size: calc(var(--dt-font-body-l-size) * 1px);--divider-line-height: calc(var(--dt-font-body-l-line-height) * 1px);width:var(--divider-width)}.c-divider,.c-divider hr{margin:0;border:0;background-color:var(--divider-bg-color)}.c-divider:not(.c-divider--labelled){height:var(--divider-height)}.c-divider.c-divider--labelled{display:flex;align-items:center;text-align:center;gap:var(--dt-spacing-b);background-color:transparent;color:var(--dt-color-content-subdued-solid)}.c-divider.c-divider--labelled .c-divider-label{font-size:var(--divider-font-size);line-height:var(--divider-line-height);max-width:var(--divider-label-max-width);word-wrap:break-word}.c-divider.c-divider--labelled hr{flex-grow:1;height:var(--divider-height);min-width:var(--divider-min-width)}.c-divider.c-divider--labelled.c-divider--inverse{color:var(--dt-color-content-inverse-solid)}.c-divider.c-divider--inverse{--divider-bg-color: var(--dt-color-divider-inverse)}.c-divider.c-divider--vertical{--divider-width: 1px;--divider-height: 100%}", y = ["default", "inverse"], $ = ["horizontal", "vertical"], l = {
12
+ const w = "*,*:after,*:before{box-sizing:inherit}:host{display:block}:host([orientation=vertical]){height:100%}.c-divider{--divider-bg-color: var(--dt-color-divider-default);--divider-width: 100%;--divider-min-width: 16px;--divider-height: 1px;--divider-label-max-width: 90%;--divider-font-family: var(--dt-font-body-l-family);--divider-font-size: calc(var(--dt-font-body-l-size) * 1px);--divider-line-height: calc(var(--dt-font-body-l-line-height) * 1px);width:var(--divider-width)}.c-divider,.c-divider hr{margin:0;border:0;background-color:var(--divider-bg-color)}.c-divider:not(.c-divider--labelled){height:var(--divider-height)}.c-divider.c-divider--labelled{display:flex;align-items:center;text-align:center;gap:var(--dt-spacing-b);background-color:transparent;color:var(--dt-color-content-subdued-solid)}.c-divider.c-divider--labelled .c-divider-label{font-size:var(--divider-font-size);line-height:var(--divider-line-height);font-family:var(--divider-font-family);max-width:var(--divider-label-max-width);word-wrap:break-word}.c-divider.c-divider--labelled hr{flex-grow:1;height:var(--divider-height);min-width:var(--divider-min-width)}.c-divider.c-divider--labelled.c-divider--inverse{color:var(--dt-color-content-inverse-solid)}.c-divider.c-divider--inverse{--divider-bg-color: var(--dt-color-divider-inverse)}.c-divider.c-divider--vertical{--divider-width: 1px;--divider-height: 100%}", x = ["default", "inverse"], $ = ["horizontal", "vertical"], l = {
13
13
  variant: "default",
14
14
  orientation: "horizontal",
15
15
  label: ""
@@ -36,7 +36,7 @@ let a = class extends p {
36
36
  <div
37
37
  id="${e}"
38
38
  data-test-id="${e}"
39
- class="${g(i)}"
39
+ class="${f(i)}"
40
40
  aria-labelledby="${e}-label">
41
41
  <hr aria-hidden="true"/>
42
42
  <span id="${e}-label" class="c-divider-label">${d}</span>
@@ -44,29 +44,29 @@ let a = class extends p {
44
44
  </div>` : h`
45
45
  <hr id="${e}"
46
46
  data-test-id="${e}"
47
- class="${g(i)}"
47
+ class="${f(i)}"
48
48
  aria-hidden="true"
49
49
  />`}`;
50
50
  }
51
51
  };
52
- a.styles = m(x);
52
+ a.styles = u(w);
53
53
  n([
54
54
  b({ type: String }),
55
- f(e, y, l.variant)
55
+ g(e, x, l.variant)
56
56
  ], a.prototype, "variant", 2);
57
57
  n([
58
58
  b({ type: String, reflect: !0 }),
59
- f(e, $, l.orientation)
59
+ g(e, $, l.orientation)
60
60
  ], a.prototype, "orientation", 2);
61
61
  n([
62
62
  b({ type: String })
63
63
  ], a.prototype, "label", 2);
64
64
  a = n([
65
- w("pie-divider")
65
+ y("pie-divider")
66
66
  ], a);
67
67
  export {
68
68
  a as PieDivider,
69
69
  l as defaultProps,
70
70
  $ as orientations,
71
- y as variants
71
+ x as variants
72
72
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@justeattakeaway/pie-divider",
3
3
  "description": "PIE Design System Divider built using Web Components",
4
- "version": "1.5.13",
4
+ "version": "1.5.15",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "https://github.com/justeattakeaway/pie",
@@ -45,13 +45,13 @@
45
45
  "devDependencies": {
46
46
  "@custom-elements-manifest/analyzer": "0.9.0",
47
47
  "@justeattakeaway/pie-components-config": "0.21.0",
48
- "@justeattakeaway/pie-css": "0.30.0",
48
+ "@justeattakeaway/pie-css": "0.31.0",
49
49
  "@justeattakeaway/pie-monorepo-utils": "0.7.0",
50
50
  "@justeattakeaway/pie-wrapper-react": "0.14.3",
51
51
  "cem-plugin-module-file-extensions": "0.0.5"
52
52
  },
53
53
  "dependencies": {
54
- "@justeattakeaway/pie-webc-core": "10.0.0"
54
+ "@justeattakeaway/pie-webc-core": "11.0.0"
55
55
  },
56
56
  "volta": {
57
57
  "extends": "../../../package.json"
package/src/divider.scss CHANGED
@@ -14,6 +14,7 @@
14
14
  --divider-min-width: 16px;
15
15
  --divider-height: 1px;
16
16
  --divider-label-max-width: 90%;
17
+ --divider-font-family: var(--dt-font-body-l-family);
17
18
  --divider-font-size: #{p.font-size(--dt-font-body-l-size)};
18
19
  --divider-line-height: #{p.font-size(--dt-font-body-l-line-height)};
19
20
 
@@ -41,6 +42,7 @@
41
42
  .c-divider-label {
42
43
  font-size: var(--divider-font-size);
43
44
  line-height: var(--divider-line-height);
45
+ font-family: var(--divider-font-family);
44
46
  max-width: var(--divider-label-max-width);
45
47
  word-wrap: break-word;
46
48
  }