@proximus/lavender-section 1.0.0-alpha.7 → 1.0.0-alpha.8

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.
@@ -1,12 +1,12 @@
1
- import { bgColorValues as g } from "@proximus/lavender-common";
1
+ import { bgColorValues as a } from "@proximus/lavender-common";
2
2
  import "@proximus/lavender-container";
3
3
  import "@proximus/lavender-layout";
4
- const s = ":host,:host *{box-sizing:border-box}:host .content-wrapper{margin-inline:1rem;max-width:1200px}@media only screen and (min-width: 1232px){:host .content-wrapper{margin-inline:auto}}", i = new CSSStyleSheet();
5
- i.replaceSync(s);
6
- class r extends HTMLElement {
4
+ const r = ":host,:host *{box-sizing:border-box}:host .content-wrapper{margin-inline:1rem;max-width:1200px}@media only screen and (min-width: 1232px){:host .content-wrapper{margin-inline:auto}}", i = new CSSStyleSheet();
5
+ i.replaceSync(r);
6
+ class n extends HTMLElement {
7
7
  constructor() {
8
8
  super(), this.template = () => `
9
- <px-container borderradius="none" padding="none" bgcolor="${this.bgColor}">
9
+ <px-container border-radius="none" padding="none" background-color="${this.bgColor}">
10
10
  <div class="content-wrapper">
11
11
  <px-vstack gap="under-display-vertical">
12
12
  <slot name="heading"></slot>
@@ -23,16 +23,16 @@ class r extends HTMLElement {
23
23
  }
24
24
  static get observedAttributes() {
25
25
  return [
26
- "bgcolor",
27
- "gradient",
28
- "bgimg-mobile",
29
- "bgimg-tablet",
30
- "bgimg-laptop",
31
- "bgimgsize",
32
- "bgimgposition",
33
- "paddingblock",
34
- "paddingtop",
35
- "paddingbottom"
26
+ "background-color",
27
+ "background-gradient",
28
+ "background-image-mobile",
29
+ "background-image-tablet",
30
+ "background-image-laptop",
31
+ "background-size",
32
+ "background-position",
33
+ "padding-block",
34
+ "padding-top",
35
+ "padding-bottom"
36
36
  ];
37
37
  }
38
38
  get $container() {
@@ -41,100 +41,100 @@ class r extends HTMLElement {
41
41
  attributeChangedCallback(t, o, e) {
42
42
  if (o !== e)
43
43
  switch (t) {
44
- case "bgcolor":
45
- this.$container.bgColor = g.indexOf(e) > 0 ? e : "none";
44
+ case "background-color":
45
+ this.$container.bgColor = a.indexOf(e) > 0 ? e : "none";
46
46
  break;
47
- case "gradient":
47
+ case "background-gradient":
48
48
  this.$container.gradient = this.gradient;
49
49
  break;
50
- case "bgimg-mobile":
50
+ case "background-image-mobile":
51
51
  this.$container.bgImgMobile = e;
52
52
  break;
53
- case "bgimg-tablet":
53
+ case "background-image-tablet":
54
54
  this.$container.bgImgTablet = e;
55
55
  break;
56
- case "bgimg-laptop":
56
+ case "background-image-laptop":
57
57
  this.$container.bgImgLaptop = e;
58
58
  break;
59
- case "bgimgsize":
59
+ case "background-size":
60
60
  this.$container.bgImgSize = e;
61
61
  break;
62
- case "bgimgposition":
62
+ case "background-position":
63
63
  this.$container.bgImgPosition = e;
64
64
  break;
65
- case "paddingblock":
65
+ case "padding-block":
66
66
  this.$container.paddingBlock = e;
67
67
  break;
68
- case "paddingtop":
68
+ case "padding-top":
69
69
  this.$container.paddingTop = e;
70
70
  break;
71
- case "paddingbottom":
71
+ case "padding-bottom":
72
72
  this.$container.paddingBottom = e;
73
73
  break;
74
74
  }
75
75
  }
76
76
  get bgColor() {
77
- return this.getAttribute("bgcolor") || "none";
77
+ return this.getAttribute("background-color") || "none";
78
78
  }
79
79
  set bgColor(t) {
80
- this.setAttribute("bgcolor", t);
80
+ this.setAttribute("background-color", t);
81
81
  }
82
82
  get gradient() {
83
- return this.getAttribute("gradient");
83
+ return this.getAttribute("background-gradient");
84
84
  }
85
85
  set gradient(t) {
86
- this.setAttribute("gradient", t);
86
+ this.setAttribute("background-gradient", t);
87
87
  }
88
88
  get bgImgMobile() {
89
- return this.getAttribute("bgimg-mobile");
89
+ return this.getAttribute("background-image-mobile");
90
90
  }
91
91
  set bgImgMobile(t) {
92
- this.setAttribute("bgimg-mobile", t);
92
+ this.setAttribute("background-image-mobile", t);
93
93
  }
94
94
  get bgImgTablet() {
95
- return this.getAttribute("bgimg-tablet");
95
+ return this.getAttribute("background-image-tablet");
96
96
  }
97
97
  set bgImgTablet(t) {
98
- this.setAttribute("bgimg-tablet", t);
98
+ this.setAttribute("background-image-tablet", t);
99
99
  }
100
100
  get bgImgLaptop() {
101
- return this.getAttribute("bgimg-laptop");
101
+ return this.getAttribute("background-image-laptop");
102
102
  }
103
103
  set bgImgLaptop(t) {
104
- this.setAttribute("bgimg-laptop", t);
104
+ this.setAttribute("background-image-laptop", t);
105
105
  }
106
106
  get bgImgSize() {
107
- return this.getAttribute("bgimgsize");
107
+ return this.getAttribute("background-size");
108
108
  }
109
109
  set bgImgSize(t) {
110
- this.setAttribute("bgimgsize", t);
110
+ this.setAttribute("background-size", t);
111
111
  }
112
112
  get bgImgPosition() {
113
- return this.getAttribute("bgimgposition");
113
+ return this.getAttribute("background-position");
114
114
  }
115
115
  set bgImgPosition(t) {
116
- this.setAttribute("bgimgposition", t);
116
+ this.setAttribute("background-position", t);
117
117
  }
118
118
  get paddingBlock() {
119
- return this.getAttribute("paddingblock");
119
+ return this.getAttribute("padding-block");
120
120
  }
121
121
  set paddingBlock(t) {
122
- this.setAttribute("paddingblock", t);
122
+ this.setAttribute("padding-block", t);
123
123
  }
124
124
  get paddingTop() {
125
- return this.getAttribute("paddingtop");
125
+ return this.getAttribute("padding-top");
126
126
  }
127
127
  set paddingTop(t) {
128
- this.setAttribute("paddingtop", t);
128
+ this.setAttribute("padding-top", t);
129
129
  }
130
130
  get paddingBottom() {
131
- return this.getAttribute("paddingbottom");
131
+ return this.getAttribute("padding-bottom");
132
132
  }
133
133
  set paddingBottom(t) {
134
- this.setAttribute("paddingbottom", t);
134
+ this.setAttribute("padding-bottom", t);
135
135
  }
136
136
  }
137
- customElements.define("px-section", r);
137
+ customElements.define("px-section", n);
138
138
  export {
139
- r as Section
139
+ n as Section
140
140
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@proximus/lavender-section",
3
- "version": "1.0.0-alpha.7",
3
+ "version": "1.0.0-alpha.8",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "exports": {
@@ -36,5 +36,5 @@
36
36
  }
37
37
  }
38
38
  },
39
- "gitHead": "3bf7639ce5c999b5c8e5b0b12b9e2a5913b9c76b"
39
+ "gitHead": "08fb9ddab89cd17f18333bee8be670cf03f369d5"
40
40
  }