@proximus/lavender 1.0.0-alpha.17 → 1.0.0-alpha.18
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/dist/lavender.cjs.js +1 -1
- package/dist/lavender.es.js +215 -19
- package/dist/lavender.umd.js +1 -1
- package/package.json +2 -2
package/dist/lavender.es.js
CHANGED
|
@@ -1060,6 +1060,203 @@ class Page extends WithFlexAttributes {
|
|
|
1060
1060
|
if (customElements.get("px-page") === void 0) {
|
|
1061
1061
|
customElements.define("px-page", Page);
|
|
1062
1062
|
}
|
|
1063
|
+
const buttonCss = ".btn{display:inline-flex;vertical-align:middle;align-items:center;justify-content:center;font-family:var(--px-font-family);font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);font-weight:700;gap:var(--px-spacing-between-icon-horizontal);cursor:pointer;text-decoration:none;--btn-transition: all .2s ease-in-out 0s;transition:var(--btn-transition);border:var(--px-border-m) solid transparent}.btn,.btn *{box-sizing:border-box}.btn ::slotted(px-icon){line-height:0}.btn:hover:not([disabled],[aria-disabled=true],.loading){border-color:var(--px-color-border-action-hover-default)}.btn:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset-s);outline:var(--px-outline-s) solid var(--px-color-outline-default)}.btn:active{transform:scale(.95)}.btn[disabled],.btn[aria-disabled=true]{cursor:default;pointer-events:none}.btn.loading{cursor:inherit}.btn.loading ::slotted(px-spinner){line-height:0}.btn:not(.secondary,.tertiary,.patch){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-primary-default);min-height:var(--px-size-action-mobile);padding:0 var(--px-padding-m);border-radius:var(--px-radius-button-small) var(--px-radius-button-small) var(--px-radius-button-big) var(--px-radius-button-small)}.btn:not(.secondary,.tertiary,.patch):hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn:not(.secondary,.tertiary,.patch)[disabled],.btn:not(.secondary,.tertiary,.patch)[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}.btn:not(.secondary,.tertiary,.patch).loading{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-primary-default);border-color:transparent}.btn:not(.secondary,.tertiary,.patch).extended{width:100%}.btn:not(.secondary,.tertiary,.patch).alternative{border-radius:var(--px-radius-button-small)}.btn.secondary{color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-secondary-default);min-height:var(--px-size-action-mobile);padding:0 var(--px-padding-m);border-radius:var(--px-radius-button-small) var(--px-radius-button-small) var(--px-radius-button-big) var(--px-radius-button-small)}.btn.secondary:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn.secondary[disabled],.btn.secondary[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}.btn.secondary.loading{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-primary-default);border-color:transparent}.btn.secondary.extended{width:100%}.btn.secondary.alternative{border-radius:var(--px-radius-button-small)}.btn.tertiary{background:none;color:var(--px-color-txt-primary-default);border-radius:var(--px-radius-pill);padding:var(--px-padding-2xs) 0}.btn.tertiary ::slotted(px-icon){display:flex;align-items:center;justify-content:center;width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);border-radius:var(--px-radius-pill);background:var(--px-color-bg-action-secondary-default);transition:var(--btn-transition)}.btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading){padding:var(--px-padding-2xs) var(--px-padding-s)}.btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading) ::slotted(px-icon){background:transparent;width:inherit;height:inherit}.btn.tertiary[disabled],.btn.tertiary[aria-disabled=true]{color:var(--px-color-txt-disabled-default)}.btn.tertiary[disabled] ::slotted(px-icon),.btn.tertiary[aria-disabled=true] ::slotted(px-icon){background:var(--px-color-bg-action-disabled-default)}.btn.tertiary.loading{color:var(--px-color-txt-primary-default);border-color:transparent}.btn.tertiary.loading ::slotted(px-spinner){display:flex;align-items:center;justify-content:center;width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);border-radius:var(--px-radius-pill);background:var(--px-color-bg-action-disabled-default)}.btn.patch{display:inline-flex}.btn.patch:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn.patch[disabled],.btn.patch[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}button.link{background:none;border:none;text-decoration:underline;padding:0;cursor:pointer}button.link[disabled],button.link[aria-disabled=true]{cursor:default;pointer-events:none;color:var(--px-color-txt-disabled-default)}:host([inverted]) .btn:hover:not([disabled],[aria-disabled=true],.loading){border-color:var(--px-color-border-action-hover-inverted)}:host([inverted]) .btn:focus:not([disabled],[aria-disabled=true]){outline-color:var(--px-color-outline-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-primary-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch):hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch)[disabled],:host([inverted]) .btn:not(.secondary,.tertiary,.patch)[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch).loading{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-primary-inverted);border-color:transparent}:host([inverted]) .btn.secondary{color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-secondary-inverted)}:host([inverted]) .btn.secondary:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn.secondary[disabled],:host([inverted]) .btn.secondary[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn.secondary.loading{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-primary-inverted);border-color:transparent}:host([inverted]) .btn.tertiary{color:var(--px-color-txt-primary-inverted)}:host([inverted]) .btn.tertiary ::slotted(px-icon){background:var(--px-color-bg-action-secondary-inverted)}:host([inverted]) .btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading) ::slotted(px-icon){background:transparent}:host([inverted]) .btn.tertiary[disabled],:host([inverted]) .btn.tertiary[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn.tertiary[disabled] ::slotted(px-icon),:host([inverted]) .btn.tertiary[aria-disabled=true] ::slotted(px-icon){background:var(--px-color-bg-action-disabled-inverted)}:host([inverted]) .btn.tertiary.loading{color:var(--px-color-txt-primary-inverted)}:host([inverted]) .btn.tertiary.loading ::slotted(px-spinner){background:var(--px-color-bg-action-disabled-inverted)}:host([inverted]) .btn.patch:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn.patch[disabled],:host([inverted]) .btn.patch[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) button.link[disabled],:host([inverted]) button.link[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}@media only screen and (min-width: 768px){.btn{font-size:var(--px-text-size-base-tablet)}.btn:not(.secondary,.tertiary,.patch){min-height:var(--px-size-action-desktop)}.btn.secondary{min-height:var(--px-size-action-desktop)}.btn.tertiary ::slotted(px-spinner){width:var(--px-icon-size-m-tablet);height:var(--px-icon-size-m-tablet)}}@media only screen and (min-width: 1441px){.btn{font-size:var(--px-text-size-base-desktop)}.btn:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset);outline-width:var(--px-outline)}.btn.tertiary ::slotted(px-spinner){width:var(--px-icon-size-m-desktop);height:var(--px-icon-size-m-desktop)}}@keyframes anim-spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}";
|
|
1064
|
+
const linkCss = 'a,.link,::slotted(a){font-family:var(--px-font-family);font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);font-weight:500;color:var(--px-color-txt-body-default)}a:hover,.link:hover{color:var(--px-color-txt-hover-default)}a:focus,.link:focus{outline-offset:var(--px-offset-s);outline:var(--px-outline-s) solid var(--px-color-outline-default)}a[aria-disabled=true],.link[aria-disabled=true]{cursor:default;pointer-events:none;color:var(--px-color-txt-disabled-default)}a ::slotted([slot="after"]),.link ::slotted([slot="after"]){margin-left:var(--px-spacing-text-to-icon-compact-horizontal)}a ::slotted(span[slot="after"]),a ::slotted(span[slot="before"]),.link ::slotted(span[slot="after"]),.link ::slotted(span[slot="before"]){display:inline-block}::slotted(a:hover){color:var(--px-color-txt-hover-default)}a.no-style{color:inherit;text-decoration:none}a.no-style:hover,a.no-style:focus{color:inherit}a.skip-link{position:absolute;left:-10000px;top:auto;overflow:hidden;background-color:var(--px-color-bg-container-weak-default);padding:var(--px-padding-xs)}a.skip-link:focus{left:auto;z-index:999}:host([inverted]) a,:host([inverted]) .link,:host([inverted]) ::slotted(a){color:var(--px-color-txt-body-inverted)}:host([inverted]) a:hover,:host([inverted]) .link:hover{color:var(--px-color-txt-hover-inverted)}:host([inverted]) a:focus,:host([inverted]) .link:focus{outline-color:var(--px-color-outline-inverted)}:host([inverted]) a[aria-disabled=true],:host([inverted]) .link[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}:host([inverted]) ::slotted(a:hover){color:var(--px-color-txt-hover-inverted)}:host([inverted]) a.skip-link{background-color:var(--px-color-bg-container-weak-inverted)}@media only screen and (min-width: 768px){a,.link,::slotted(a){font-size:var(--px-text-size-base-tablet)}}@media only screen and (min-width: 1441px){a,.link,::slotted(a){font-size:var(--px-text-size-base-desktop)}a:focus,.link:focus{outline-offset:var(--px-offset);outline-width:var(--px-outline)}}';
|
|
1065
|
+
const styles$b = ".patch{display:inline-flex;align-items:center;padding:0 var(--px-padding-s);height:1.625rem;border:var(--px-border-m) solid transparent;border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small);font-family:var(--px-font-family);font-weight:700;font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);text-align:center;background-color:var(--px-color-bg-promo-default);color:var(--px-color-txt-primary-inverted)}.patch,.patch *{box-sizing:border-box}@media only screen and (min-width: 768px){.patch{font-size:var(--px-text-size-base-tablet)}}@media only screen and (min-width: 1025px){.patch{font-size:var(--px-text-size-base-desktop)}}:host([inverted]) .patch{background-color:var(--px-color-bg-promo-inverted);color:var(--px-color-txt-primary-inverted)}.bottom-right{border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small) var(--px-radius-patch-big)}.bottom-left{border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small)}.info{background-color:var(--px-color-illu-blue-core);color:var(--px-color-txt-body-default)}:host([inverted]) .info{background-color:var(--px-color-illu-blue-core);color:var(--px-color-txt-body-default)}.black-friday{background-color:var(--px-color-bg-container-rich-default);color:var(--px-color-txt-body-inverted)}:host([inverted]) .black-friday{background-color:var(--px-color-bg-container-rich-inverted);color:var(--px-color-txt-body-default)}.eco{background-color:var(--px-color-bg-success-default);color:var(--px-color-txt-body-inverted)}:host([inverted]) .eco{background-color:var(--px-color-bg-success-inverted);color:var(--px-color-txt-inverted-default)}.greyed{background-color:var(--px-color-bg-action-disabled-default);color:var(--px-color-icon-disabled-default)}:host([inverted]) .greyed{background-color:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-icon-disabled-inverted)}";
|
|
1066
|
+
const buttonStyles$1 = new CSSStyleSheet();
|
|
1067
|
+
const linkStyles$2 = new CSSStyleSheet();
|
|
1068
|
+
const patchStyles = new CSSStyleSheet();
|
|
1069
|
+
buttonStyles$1.replaceSync(buttonCss);
|
|
1070
|
+
linkStyles$2.replaceSync(linkCss);
|
|
1071
|
+
patchStyles.replaceSync(styles$b);
|
|
1072
|
+
const variantValues$1 = [
|
|
1073
|
+
"",
|
|
1074
|
+
"default",
|
|
1075
|
+
"secondary",
|
|
1076
|
+
"tertiary",
|
|
1077
|
+
"link",
|
|
1078
|
+
"patch",
|
|
1079
|
+
"patch-info",
|
|
1080
|
+
"patch-black-friday",
|
|
1081
|
+
"patch-eco"
|
|
1082
|
+
];
|
|
1083
|
+
const _Button = class _Button extends PxElement {
|
|
1084
|
+
constructor() {
|
|
1085
|
+
super(buttonStyles$1, linkStyles$2, patchStyles);
|
|
1086
|
+
this.template = () => `<slot name="before"></slot><slot></slot><slot name="after"></slot>`;
|
|
1087
|
+
const $root = document.createElement(this.nativeName);
|
|
1088
|
+
$root.classList.add("btn");
|
|
1089
|
+
$root.innerHTML = this.template();
|
|
1090
|
+
this.shadowRoot.appendChild($root);
|
|
1091
|
+
}
|
|
1092
|
+
static get observedAttributes() {
|
|
1093
|
+
return [
|
|
1094
|
+
...super.observedAttributes,
|
|
1095
|
+
"variant",
|
|
1096
|
+
"state",
|
|
1097
|
+
"extended",
|
|
1098
|
+
"loading",
|
|
1099
|
+
"shape",
|
|
1100
|
+
"inverted"
|
|
1101
|
+
];
|
|
1102
|
+
}
|
|
1103
|
+
connectedCallback() {
|
|
1104
|
+
super.connectedCallback();
|
|
1105
|
+
const icons = this.querySelectorAll("px-icon");
|
|
1106
|
+
if (icons) {
|
|
1107
|
+
icons.forEach((icon) => {
|
|
1108
|
+
const iconSize = icon.getAttribute("size");
|
|
1109
|
+
const iconColor = icon.getAttribute("color");
|
|
1110
|
+
if (icon) {
|
|
1111
|
+
icon.addEventListener("click", () => {
|
|
1112
|
+
this.$el.focus();
|
|
1113
|
+
});
|
|
1114
|
+
if (!iconSize) {
|
|
1115
|
+
icon.setAttribute("size", "xs");
|
|
1116
|
+
}
|
|
1117
|
+
if (!iconColor) {
|
|
1118
|
+
icon.setAttribute("color", "inherit");
|
|
1119
|
+
}
|
|
1120
|
+
}
|
|
1121
|
+
});
|
|
1122
|
+
}
|
|
1123
|
+
}
|
|
1124
|
+
attributeChangedCallback(attrName, oldValue, newValue) {
|
|
1125
|
+
if (oldValue !== newValue) {
|
|
1126
|
+
switch (attrName) {
|
|
1127
|
+
case "variant":
|
|
1128
|
+
this.updateVariant(oldValue, newValue, variantValues$1);
|
|
1129
|
+
break;
|
|
1130
|
+
case "state":
|
|
1131
|
+
this.updateState(oldValue, newValue);
|
|
1132
|
+
break;
|
|
1133
|
+
case "extended":
|
|
1134
|
+
this.updateExtended();
|
|
1135
|
+
break;
|
|
1136
|
+
case "loading":
|
|
1137
|
+
this.updateLoading();
|
|
1138
|
+
break;
|
|
1139
|
+
case "shape":
|
|
1140
|
+
this.updateShape(oldValue, newValue);
|
|
1141
|
+
break;
|
|
1142
|
+
default:
|
|
1143
|
+
super.attributeChangedCallback(attrName, oldValue, newValue);
|
|
1144
|
+
break;
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
}
|
|
1148
|
+
checkName(values, value) {
|
|
1149
|
+
if (values.includes(value)) {
|
|
1150
|
+
return true;
|
|
1151
|
+
}
|
|
1152
|
+
return false;
|
|
1153
|
+
}
|
|
1154
|
+
checkClass(value) {
|
|
1155
|
+
if (value.startsWith("patch-")) {
|
|
1156
|
+
const splittedValue = value.split(/-(.*)/s);
|
|
1157
|
+
for (const classVar of splittedValue) {
|
|
1158
|
+
if (classVar != "") {
|
|
1159
|
+
this.$el.classList.toggle(classVar);
|
|
1160
|
+
}
|
|
1161
|
+
}
|
|
1162
|
+
} else {
|
|
1163
|
+
this.$el.classList.toggle(value);
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
1166
|
+
_toggleClass(oldValue, newValue) {
|
|
1167
|
+
if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
|
|
1168
|
+
this.checkClass(oldValue);
|
|
1169
|
+
}
|
|
1170
|
+
if (newValue !== null && newValue !== "" && newValue !== "default") {
|
|
1171
|
+
this.checkClass(newValue);
|
|
1172
|
+
}
|
|
1173
|
+
}
|
|
1174
|
+
updateVariant(oldValue, newValue, attrValue) {
|
|
1175
|
+
if (newValue === "link") {
|
|
1176
|
+
this.$el.classList.remove("btn");
|
|
1177
|
+
} else {
|
|
1178
|
+
this.$el.classList.add("btn");
|
|
1179
|
+
}
|
|
1180
|
+
this._toggleClass(oldValue, newValue);
|
|
1181
|
+
if (!this.checkName(attrValue, newValue)) {
|
|
1182
|
+
console.error(`Bad "variant" value for ${this.$el}`);
|
|
1183
|
+
}
|
|
1184
|
+
}
|
|
1185
|
+
updateState(oldValue, newValue) {
|
|
1186
|
+
const values = ["", "default", "success", "error"];
|
|
1187
|
+
this._toggleClass(oldValue, newValue);
|
|
1188
|
+
if (!this.checkName(values, newValue)) {
|
|
1189
|
+
console.error(`Bad "sate" value for ${this.$el}`);
|
|
1190
|
+
}
|
|
1191
|
+
}
|
|
1192
|
+
updateExtended() {
|
|
1193
|
+
this.$el.classList.toggle("extended");
|
|
1194
|
+
}
|
|
1195
|
+
updateLoading() {
|
|
1196
|
+
const spinner = this.querySelector("px-spinner");
|
|
1197
|
+
if (spinner) {
|
|
1198
|
+
const spinnerSize = spinner.getAttribute("size");
|
|
1199
|
+
if (!spinnerSize) {
|
|
1200
|
+
spinner.setAttribute("size", "xs");
|
|
1201
|
+
}
|
|
1202
|
+
}
|
|
1203
|
+
this.$el.classList.toggle("loading");
|
|
1204
|
+
}
|
|
1205
|
+
updateShape(oldValue, newValue) {
|
|
1206
|
+
const values = [
|
|
1207
|
+
"",
|
|
1208
|
+
"default",
|
|
1209
|
+
"bottom-right",
|
|
1210
|
+
"bottom-left",
|
|
1211
|
+
"alternative"
|
|
1212
|
+
];
|
|
1213
|
+
this._toggleClass(oldValue, newValue);
|
|
1214
|
+
if (!this.checkName(values, newValue)) {
|
|
1215
|
+
console.error(`Bad "shape" value for ${this.$el}`);
|
|
1216
|
+
}
|
|
1217
|
+
}
|
|
1218
|
+
get variant() {
|
|
1219
|
+
return this.getAttribute("variant");
|
|
1220
|
+
}
|
|
1221
|
+
set variant(value) {
|
|
1222
|
+
this.setAttribute("variant", value);
|
|
1223
|
+
}
|
|
1224
|
+
get state() {
|
|
1225
|
+
return this.getAttribute("state");
|
|
1226
|
+
}
|
|
1227
|
+
set state(value) {
|
|
1228
|
+
this.setAttribute("state", value);
|
|
1229
|
+
}
|
|
1230
|
+
get extended() {
|
|
1231
|
+
return this.getAttribute("extended");
|
|
1232
|
+
}
|
|
1233
|
+
set extended(value) {
|
|
1234
|
+
this.setAttribute("extended", value);
|
|
1235
|
+
}
|
|
1236
|
+
get loading() {
|
|
1237
|
+
return this.getAttribute("loading");
|
|
1238
|
+
}
|
|
1239
|
+
set loading(value) {
|
|
1240
|
+
this.setAttribute("loading", value);
|
|
1241
|
+
}
|
|
1242
|
+
get shape() {
|
|
1243
|
+
return this.getAttribute("shape");
|
|
1244
|
+
}
|
|
1245
|
+
set shape(value) {
|
|
1246
|
+
this.setAttribute("shape", value);
|
|
1247
|
+
}
|
|
1248
|
+
get inverted() {
|
|
1249
|
+
return this.getAttribute("inverted");
|
|
1250
|
+
}
|
|
1251
|
+
set inverted(value) {
|
|
1252
|
+
this.setAttribute("inverted", value);
|
|
1253
|
+
}
|
|
1254
|
+
};
|
|
1255
|
+
_Button.nativeName = "button";
|
|
1256
|
+
let Button = _Button;
|
|
1257
|
+
if (!customElements.get("px-button")) {
|
|
1258
|
+
customElements.define("px-button", Button);
|
|
1259
|
+
}
|
|
1063
1260
|
class IconSet extends HTMLElement {
|
|
1064
1261
|
constructor() {
|
|
1065
1262
|
super();
|
|
@@ -1210,9 +1407,9 @@ class Icon extends WithFlexAttributes {
|
|
|
1210
1407
|
this.setAttribute("from", value);
|
|
1211
1408
|
}
|
|
1212
1409
|
}
|
|
1213
|
-
const styles$
|
|
1410
|
+
const styles$a = ":host{line-height:1;display:inline-flex;flex-direction:column;justify-content:center}i{font-family:lavender;color:var(--px-color-icon-primary-default);font-size:var(--px-icon-size-m-mobile);line-height:1;font-style:unset;font-weight:400;-webkit-user-select:none;user-select:none;font-display:swap}svg{width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);color:var(--px-color-icon-primary-default)}.inherit{color:inherit}.primary{color:var(--px-color-icon-primary-default)}.body{color:var(--px-color-icon-body-default)}.details{color:var(--px-color-icon-details-default)}.hover:hover{color:var(--px-color-icon-hover-default)}.hover:active{color:var(--px-color-icon-active-default)}.disabled{color:var(--px-color-icon-disabled-default)}.success{color:var(--px-color-icon-success-default)}.warning{color:var(--px-color-icon-warning-default)}.error{color:var(--px-color-icon-error-default)}.unlimited{color:var(--px-color-icon-unlimited-default)}.promo{color:var(--px-color-icon-promo-default)}:host([inverted]) i{color:var(--px-color-icon-primary-inverted)}:host([inverted]) svg{color:var(--px-color-icon-primary-inverted)}:host([inverted]) .primary{color:var(--px-color-icon-primary-inverted)}:host([inverted]) .body{color:var(--px-color-icon-body-inverted)}:host([inverted]) .details{color:var(--px-color-icon-details-inverted)}:host([inverted]) .hover:hover{color:var(--px-color-icon-hover-inverted)}:host([inverted]) .hover:active{color:var(--px-color-icon-active-inverted)}:host([inverted]) .disabled{color:var(--px-color-icon-disabled-inverted)}:host([inverted]) .success{color:var(--px-color-icon-success-inverted)}:host([inverted]) .warning{color:var(--px-color-icon-warning-inverted)}:host([inverted]) .error{color:var(--px-color-icon-error-inverted)}:host([inverted]) .unlimited{color:var(--px-color-icon-unlimited-inverted)}:host([inverted]) .promo{color:var(--px-color-icon-promo-inverted)}.size-2xs{width:var(--px-icon-size-2xs-mobile);height:var(--px-icon-size-2xs-mobile);font-size:var(--px-icon-size-2xs-mobile)}.size-xs{width:var(--px-icon-size-xs-mobile);height:var(--px-icon-size-xs-mobile);font-size:var(--px-icon-size-xs-mobile)}.size-s{width:var(--px-icon-size-s-mobile);height:var(--px-icon-size-s-mobile);font-size:var(--px-icon-size-s-mobile)}.size-m{width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);font-size:var(--px-icon-size-m-mobile)}.size-l{width:var(--px-icon-size-l-mobile);height:var(--px-icon-size-l-mobile);font-size:var(--px-icon-size-l-mobile)}.size-xl{width:var(--px-icon-size-xl-mobile);height:var(--px-icon-size-xl-mobile);font-size:var(--px-icon-size-xl-mobile)}.size-2xl{width:var(--px-icon-size-2xl-mobile);height:var(--px-icon-size-2xl-mobile);font-size:var(--px-icon-size-2xl-mobile)}@media only screen and (min-width: 64rem){.size-2xs{width:var(--px-icon-size-2xs-tablet);height:var(--px-icon-size-2xs-tablet);font-size:var(--px-icon-size-2xs-tablet)}.size-xs{width:var(--px-icon-size-xs-tablet);height:var(--px-icon-size-xs-tablet);font-size:var(--px-icon-size-xs-tablet)}.size-s{width:var(--px-icon-size-s-tablet);height:var(--px-icon-size-s-tablet);font-size:var(--px-icon-size-s-tablet)}.size-m{width:var(--px-icon-size-m-tablet);height:var(--px-icon-size-m-tablet);font-size:var(--px-icon-size-m-tablet)}.size-l{width:var(--px-icon-size-l-tablet);height:var(--px-icon-size-l-tablet);font-size:var(--px-icon-size-l-tablet)}.size-xl{width:var(--px-icon-size-xl-tablet);height:var(--px-icon-size-xl-tablet);font-size:var(--px-icon-size-xl-tablet)}.size-2xl{width:var(--px-icon-size-2xl-tablet);height:var(--px-icon-size-2xl-tablet);font-size:var(--px-icon-size-2xl-tablet)}}@media only screen and (min-width: 90rem){.size-2xs{width:var(--px-icon-size-2xs-desktop);height:var(--px-icon-size-2xs-desktop);font-size:var(--px-icon-size-2xs-desktop)}.size-xs{width:var(--px-icon-size-xs-desktop);height:var(--px-icon-size-xs-desktop);font-size:var(--px-icon-size-xs-desktop)}.size-s{width:var(--px-icon-size-s-desktop);height:var(--px-icon-size-s-desktop);font-size:var(--px-icon-size-s-desktop)}.size-m{width:var(--px-icon-size-m-desktop);height:var(--px-icon-size-m-desktop);font-size:var(--px-icon-size-m-desktop)}.size-l{width:var(--px-icon-size-l-desktop);height:var(--px-icon-size-l-desktop);font-size:var(--px-icon-size-l-desktop)}.size-xl{width:var(--px-icon-size-xl-desktop);height:var(--px-icon-size-xl-desktop);font-size:var(--px-icon-size-xl-desktop)}.size-2xl{width:var(--px-icon-size-2xl-desktop);height:var(--px-icon-size-2xl-desktop);font-size:var(--px-icon-size-2xl-desktop)}}i.icon-large:before{vertical-align:-10%;font-size:1.3333333333em}";
|
|
1214
1411
|
const styleSheet$b = new CSSStyleSheet();
|
|
1215
|
-
styleSheet$b.replaceSync(styles$
|
|
1412
|
+
styleSheet$b.replaceSync(styles$a);
|
|
1216
1413
|
class SVGIcon extends Icon {
|
|
1217
1414
|
constructor() {
|
|
1218
1415
|
super(styleSheet$b);
|
|
@@ -1259,7 +1456,7 @@ const iconFontStyles = '.lavender-3g_tablet:before{content:""}.lavender-acces
|
|
|
1259
1456
|
const iconFontStyleSheet = new CSSStyleSheet();
|
|
1260
1457
|
const styleSheet$a = new CSSStyleSheet();
|
|
1261
1458
|
iconFontStyleSheet.replaceSync(iconFontStyles);
|
|
1262
|
-
styleSheet$a.replaceSync(styles$
|
|
1459
|
+
styleSheet$a.replaceSync(styles$a);
|
|
1263
1460
|
class FontIcon extends Icon {
|
|
1264
1461
|
constructor() {
|
|
1265
1462
|
super(iconFontStyleSheet, styleSheet$a);
|
|
@@ -2097,9 +2294,9 @@ const _H6 = class _H6 extends AbstractHeading {
|
|
|
2097
2294
|
_H6.nativeName = "h6";
|
|
2098
2295
|
let H6 = _H6;
|
|
2099
2296
|
customElements.define("px-h6", H6);
|
|
2100
|
-
const styles$
|
|
2297
|
+
const styles$9 = ":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}}";
|
|
2101
2298
|
const styleSheet$9 = new CSSStyleSheet();
|
|
2102
|
-
styleSheet$9.replaceSync(styles$
|
|
2299
|
+
styleSheet$9.replaceSync(styles$9);
|
|
2103
2300
|
class Section extends HTMLElement {
|
|
2104
2301
|
constructor() {
|
|
2105
2302
|
super();
|
|
@@ -2253,7 +2450,7 @@ customElements.define("px-section", Section);
|
|
|
2253
2450
|
const accordionCss = `details{font-family:var(--px-font-family);display:flex;flex-direction:column;align-items:flex-start}details:not(.single){border-bottom:var(--px-border-m) solid var(--px-color-border-main-default)}details:not(.single) ::slotted([slot="title"]){flex-grow:1}details:not(.single) slot[name=content]{display:block;padding-block:var(--px-spacing-component-default-vertical)}summary{align-items:center;transition:all .2s ease-out 0s,backdrop-filter 0s,-webkit-backdrop-filter 0s}details:not(.single) summary{display:flex;padding:var(--px-padding-s);gap:var(--px-spacing-text-to-icon-horizontal);align-self:stretch}summary:after{content:"";width:24px;height:24px;flex-shrink:0;background-color:var(--px-color-bg-action-secondary-default);background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Cg id='CHEVRON DOWN'%3E%3Cpath id='Vector' fill-rule='evenodd' clip-rule='evenodd' d='M12.4714 6.19524C12.2111 5.93489 11.7889 5.93489 11.5286 6.19524L8 9.72384L4.4714 6.19524C4.21105 5.93489 3.78894 5.93489 3.52859 6.19524C3.26824 6.45559 3.26824 6.8777 3.52859 7.13805L7.52859 11.1381C7.78894 11.3984 8.21105 11.3984 8.4714 11.1381L12.4714 7.13805C12.7318 6.8777 12.7318 6.45559 12.4714 6.19524Z' fill='%235C2D91'/%3E%3C/g%3E%3C/svg%3E");background-repeat:no-repeat;background-position:center center;border-radius:var(--px-radius-pill);border:var(--px-border-s) solid transparent;transition:all .2s ease-out 0s,backdrop-filter 0s,-webkit-backdrop-filter 0s}summary:hover{cursor:pointer}details:not(.single) summary:hover{background-color:var(--px-color-bg-container-weak-default)}summary:hover:after{background-color:var(--px-color-bg-action-hover-bordered-default);border:var(--px-border-s) solid var(--px-color-border-action-hover-default);-webkit-backdrop-filter:blur(15px);backdrop-filter:blur(15px)}details.single summary{display:inline-flex;gap:var(--px-spacing-between-icon-horizontal-mobile);justify-content:center;color:var(--px-color-txt-primary-default);font-weight:700;border:var(--px-border-m) solid transparent;border-radius:var(--px-radius-pill)}details.single summary:hover{gap:0;padding:0 var(--px-padding-xs);border-color:var(--px-color-border-action-hover-default)}details.single summary:hover:after{border-color:transparent;margin-right:calc(var(--px-padding-xs) * -1)}details.single slot[name=content]{display:block;padding-top:var(--px-spacing-component-default-vertical)}details[open] summary slot[name=title]{color:var(--px-color-txt-primary-default);font-weight:700}details[open] summary:after{transform:rotate(180deg)}summary::-webkit-details-marker{display:none}:host([inverted]) details{color:var(--px-color-txt-body-inverted)}:host([inverted]) details:not(.single){border-bottom:var(--px-border-m) solid var(--px-color-border-main-inverted)}:host([inverted]) details[open] summary slot[name=title]{color:var(--px-color-txt-primary-inverted)}:host([inverted]) details.single summary{color:var(--px-color-txt-primary-inverted)}:host([inverted]) details.single summary:hover{border-color:var(--px-color-bg-container-weak-inverted)}:host([inverted]) details.single summary:hover:after{border-color:transparent}:host([inverted]) summary:after{background-color:var(--px-color-bg-action-secondary-inverted);background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M12.4714 6.19524C12.2111 5.93489 11.789 5.93489 11.5286 6.19524L8.00002 9.72384L4.47142 6.19524C4.21107 5.93489 3.78897 5.93489 3.52862 6.19524C3.26827 6.45559 3.26827 6.8777 3.52862 7.13805L7.52862 11.1381C7.78897 11.3984 8.21108 11.3984 8.47142 11.1381L12.4714 7.13805C12.7318 6.8777 12.7318 6.45559 12.4714 6.19524Z' fill='white'/%3E%3C/svg%3E")}:host([inverted]) summary:hover{background-color:var(--px-color-bg-container-moderate-inverted)}:host([inverted]) summary:hover:after{background-color:var(--px-color-bg-action-bordered-inverted);border:var(--px-border-s) solid var(--px-color-border-action-hover-inverted)}`;
|
|
2254
2451
|
const accordionStyles = new CSSStyleSheet();
|
|
2255
2452
|
accordionStyles.replaceSync(accordionCss);
|
|
2256
|
-
const variantValues
|
|
2453
|
+
const variantValues = ["", "none", "single"];
|
|
2257
2454
|
const _Accordion = class _Accordion extends PxElement {
|
|
2258
2455
|
constructor() {
|
|
2259
2456
|
super(accordionStyles);
|
|
@@ -2282,7 +2479,7 @@ const _Accordion = class _Accordion extends PxElement {
|
|
|
2282
2479
|
if (oldValue !== newValue) {
|
|
2283
2480
|
switch (attrName) {
|
|
2284
2481
|
case "variant":
|
|
2285
|
-
this.updateAttribute(attrName, oldValue, newValue, variantValues
|
|
2482
|
+
this.updateAttribute(attrName, oldValue, newValue, variantValues);
|
|
2286
2483
|
break;
|
|
2287
2484
|
default:
|
|
2288
2485
|
super.attributeChangedCallback(attrName, oldValue, newValue);
|
|
@@ -2587,9 +2784,8 @@ const _Picture = class _Picture extends AbstractImage {
|
|
|
2587
2784
|
_Picture.nativeName = "picture";
|
|
2588
2785
|
let Picture = _Picture;
|
|
2589
2786
|
customElements.define("px-picture", Picture);
|
|
2590
|
-
const styles$9 = ".patch{display:inline-flex;align-items:center;padding:0 var(--px-padding-s);height:1.625rem;border:var(--px-border-m) solid transparent;border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small);font-family:var(--px-font-family);font-weight:700;font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);text-align:center;background-color:var(--px-color-bg-promo-default);color:var(--px-color-txt-primary-inverted)}.patch,.patch *{box-sizing:border-box}@media only screen and (min-width: 768px){.patch{font-size:var(--px-text-size-base-tablet)}}@media only screen and (min-width: 1025px){.patch{font-size:var(--px-text-size-base-desktop)}}:host([inverted]) .patch{background-color:var(--px-color-bg-promo-inverted);color:var(--px-color-txt-primary-inverted)}.bottom-right{border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small) var(--px-radius-patch-big)}.bottom-left{border-radius:var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-big) var(--px-radius-patch-small)}.info{background-color:var(--px-color-illu-blue-core);color:var(--px-color-txt-body-default)}:host([inverted]) .info{background-color:var(--px-color-illu-blue-core);color:var(--px-color-txt-body-default)}.black-friday{background-color:var(--px-color-bg-container-rich-default);color:var(--px-color-txt-body-inverted)}:host([inverted]) .black-friday{background-color:var(--px-color-bg-container-rich-inverted);color:var(--px-color-txt-body-default)}.eco{background-color:var(--px-color-bg-success-default);color:var(--px-color-txt-body-inverted)}:host([inverted]) .eco{background-color:var(--px-color-bg-success-inverted);color:var(--px-color-txt-inverted-default)}.greyed{background-color:var(--px-color-bg-action-disabled-default);color:var(--px-color-icon-disabled-default)}:host([inverted]) .greyed{background-color:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-icon-disabled-inverted)}";
|
|
2591
2787
|
const styleSheet$7 = new CSSStyleSheet();
|
|
2592
|
-
styleSheet$7.replaceSync(styles$
|
|
2788
|
+
styleSheet$7.replaceSync(styles$b);
|
|
2593
2789
|
const patchVariantValues = [
|
|
2594
2790
|
"",
|
|
2595
2791
|
"default",
|
|
@@ -2812,7 +3008,7 @@ const styles$6 = ".separator{--separator-size: var(--px-border-m);--px-separator
|
|
|
2812
3008
|
const styleSheet$6 = new CSSStyleSheet();
|
|
2813
3009
|
styleSheet$6.replaceSync(styles$6);
|
|
2814
3010
|
const directionValues = ["", "default", "horizontal", "vertical"];
|
|
2815
|
-
const sizeValues
|
|
3011
|
+
const sizeValues = ["", "none", "s", "m", "l"];
|
|
2816
3012
|
const colorValues = [
|
|
2817
3013
|
"",
|
|
2818
3014
|
"contrasted",
|
|
@@ -2903,7 +3099,7 @@ const _Separator = class _Separator extends PxElement {
|
|
|
2903
3099
|
this.updateDirection(attrName, newValue);
|
|
2904
3100
|
break;
|
|
2905
3101
|
case "size":
|
|
2906
|
-
this.updateSize(newValue, sizeValues
|
|
3102
|
+
this.updateSize(newValue, sizeValues);
|
|
2907
3103
|
break;
|
|
2908
3104
|
case "color":
|
|
2909
3105
|
this.updateColor(newValue, colorValues);
|
|
@@ -3614,8 +3810,6 @@ const _Span = class _Span extends PxElement {
|
|
|
3614
3810
|
_Span.nativeName = "span";
|
|
3615
3811
|
let Span = _Span;
|
|
3616
3812
|
customElements.define("px-span", Span);
|
|
3617
|
-
const linkCss = 'a,.link,::slotted(a){font-family:var(--px-font-family);font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);font-weight:500;color:var(--px-color-txt-body-default)}a:hover,.link:hover{color:var(--px-color-txt-hover-default)}a:focus,.link:focus{outline-offset:var(--px-offset-s);outline:var(--px-outline-s) solid var(--px-color-outline-default)}a[aria-disabled=true],.link[aria-disabled=true]{cursor:default;pointer-events:none;color:var(--px-color-txt-disabled-default)}a ::slotted([slot="after"]),.link ::slotted([slot="after"]){margin-left:var(--px-spacing-text-to-icon-compact-horizontal)}a ::slotted(span[slot="after"]),a ::slotted(span[slot="before"]),.link ::slotted(span[slot="after"]),.link ::slotted(span[slot="before"]){display:inline-block}::slotted(a:hover){color:var(--px-color-txt-hover-default)}a.no-style{color:inherit;text-decoration:none}a.no-style:hover,a.no-style:focus{color:inherit}a.skip-link{position:absolute;left:-10000px;top:auto;overflow:hidden;background-color:var(--px-color-bg-container-weak-default);padding:var(--px-padding-xs)}a.skip-link:focus{left:auto;z-index:999}:host([inverted]) a,:host([inverted]) .link,:host([inverted]) ::slotted(a){color:var(--px-color-txt-body-inverted)}:host([inverted]) a:hover,:host([inverted]) .link:hover{color:var(--px-color-txt-hover-inverted)}:host([inverted]) a:focus,:host([inverted]) .link:focus{outline-color:var(--px-color-outline-inverted)}:host([inverted]) a[aria-disabled=true],:host([inverted]) .link[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}:host([inverted]) ::slotted(a:hover){color:var(--px-color-txt-hover-inverted)}:host([inverted]) a.skip-link{background-color:var(--px-color-bg-container-weak-inverted)}@media only screen and (min-width: 768px){a,.link,::slotted(a){font-size:var(--px-text-size-base-tablet)}}@media only screen and (min-width: 1441px){a,.link,::slotted(a){font-size:var(--px-text-size-base-desktop)}a:focus,.link:focus{outline-offset:var(--px-offset);outline-width:var(--px-outline)}}';
|
|
3618
|
-
const buttonCss = ".btn{display:inline-flex;vertical-align:middle;align-items:center;justify-content:center;font-family:var(--px-font-family);font-size:var(--px-text-size-base-mobile);line-height:var(--px-line-height-m);font-weight:700;gap:var(--px-spacing-between-icon-horizontal);cursor:pointer;text-decoration:none;--btn-transition: all .2s ease-in-out 0s;transition:var(--btn-transition);border:var(--px-border-m) solid transparent}.btn,.btn *{box-sizing:border-box}.btn ::slotted(px-icon){line-height:0}.btn:hover:not([disabled],[aria-disabled=true],.loading){border-color:var(--px-color-border-action-hover-default)}.btn:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset-s);outline:var(--px-outline-s) solid var(--px-color-outline-default)}.btn:active{transform:scale(.95)}.btn[disabled],.btn[aria-disabled=true]{cursor:default;pointer-events:none}.btn.loading{cursor:inherit}.btn.loading ::slotted(px-spinner){line-height:0}.btn:not(.secondary,.tertiary,.patch){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-primary-default);min-height:var(--px-size-action-mobile);padding:0 var(--px-padding-m);border-radius:var(--px-radius-button-small) var(--px-radius-button-small) var(--px-radius-button-big) var(--px-radius-button-small)}.btn:not(.secondary,.tertiary,.patch):hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn:not(.secondary,.tertiary,.patch)[disabled],.btn:not(.secondary,.tertiary,.patch)[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}.btn:not(.secondary,.tertiary,.patch).loading{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-primary-default);border-color:transparent}.btn:not(.secondary,.tertiary,.patch).extended{width:100%}.btn:not(.secondary,.tertiary,.patch).alternative{border-radius:var(--px-radius-button-small)}.btn.secondary{color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-secondary-default);min-height:var(--px-size-action-mobile);padding:0 var(--px-padding-m);border-radius:var(--px-radius-button-small) var(--px-radius-button-small) var(--px-radius-button-big) var(--px-radius-button-small)}.btn.secondary:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn.secondary[disabled],.btn.secondary[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}.btn.secondary.loading{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-primary-default);border-color:transparent}.btn.secondary.extended{width:100%}.btn.secondary.alternative{border-radius:var(--px-radius-button-small)}.btn.tertiary{background:none;color:var(--px-color-txt-primary-default);border-radius:var(--px-radius-pill);padding:var(--px-padding-2xs) 0}.btn.tertiary ::slotted(px-icon){display:flex;align-items:center;justify-content:center;width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);border-radius:var(--px-radius-pill);background:var(--px-color-bg-action-secondary-default);transition:var(--btn-transition)}.btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading){padding:var(--px-padding-2xs) var(--px-padding-s)}.btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading) ::slotted(px-icon){background:transparent;width:inherit;height:inherit}.btn.tertiary[disabled],.btn.tertiary[aria-disabled=true]{color:var(--px-color-txt-disabled-default)}.btn.tertiary[disabled] ::slotted(px-icon),.btn.tertiary[aria-disabled=true] ::slotted(px-icon){background:var(--px-color-bg-action-disabled-default)}.btn.tertiary.loading{color:var(--px-color-txt-primary-default);border-color:transparent}.btn.tertiary.loading ::slotted(px-spinner){display:flex;align-items:center;justify-content:center;width:var(--px-icon-size-m-mobile);height:var(--px-icon-size-m-mobile);border-radius:var(--px-radius-pill);background:var(--px-color-bg-action-disabled-default)}.btn.patch{display:inline-flex}.btn.patch:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-hover-bordered-default)}.btn.patch[disabled],.btn.patch[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-txt-disabled-default)}button.link{background:none;border:none;text-decoration:underline;padding:0;cursor:pointer}button.link[disabled],button.link[aria-disabled=true]{cursor:default;pointer-events:none;color:var(--px-color-txt-disabled-default)}:host([inverted]) .btn:hover:not([disabled],[aria-disabled=true],.loading){border-color:var(--px-color-border-action-hover-inverted)}:host([inverted]) .btn:focus:not([disabled],[aria-disabled=true]){outline-color:var(--px-color-outline-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch){color:var(--px-color-txt-primary-default);background:var(--px-color-bg-action-primary-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch):hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch)[disabled],:host([inverted]) .btn:not(.secondary,.tertiary,.patch)[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn:not(.secondary,.tertiary,.patch).loading{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-primary-inverted);border-color:transparent}:host([inverted]) .btn.secondary{color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-secondary-inverted)}:host([inverted]) .btn.secondary:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn.secondary[disabled],:host([inverted]) .btn.secondary[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn.secondary.loading{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-primary-inverted);border-color:transparent}:host([inverted]) .btn.tertiary{color:var(--px-color-txt-primary-inverted)}:host([inverted]) .btn.tertiary ::slotted(px-icon){background:var(--px-color-bg-action-secondary-inverted)}:host([inverted]) .btn.tertiary:hover:not([disabled],[aria-disabled=true],.loading) ::slotted(px-icon){background:transparent}:host([inverted]) .btn.tertiary[disabled],:host([inverted]) .btn.tertiary[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}:host([inverted]) .btn.tertiary[disabled] ::slotted(px-icon),:host([inverted]) .btn.tertiary[aria-disabled=true] ::slotted(px-icon){background:var(--px-color-bg-action-disabled-inverted)}:host([inverted]) .btn.tertiary.loading{color:var(--px-color-txt-primary-inverted)}:host([inverted]) .btn.tertiary.loading ::slotted(px-spinner){background:var(--px-color-bg-action-disabled-inverted)}:host([inverted]) .btn.patch:hover:not([disabled],[aria-disabled=true],.loading){color:var(--px-color-txt-primary-inverted);background:var(--px-color-bg-action-hover-bordered-default-inverted)}:host([inverted]) .btn.patch[disabled],:host([inverted]) .btn.patch[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-txt-disabled-inverted)}:host([inverted]) button.link[disabled],:host([inverted]) button.link[aria-disabled=true]{color:var(--px-color-txt-disabled-inverted)}@media only screen and (min-width: 768px){.btn{font-size:var(--px-text-size-base-tablet)}.btn:not(.secondary,.tertiary,.patch){min-height:var(--px-size-action-desktop)}.btn.secondary{min-height:var(--px-size-action-desktop)}.btn.tertiary ::slotted(px-spinner){width:var(--px-icon-size-m-tablet);height:var(--px-icon-size-m-tablet)}}@media only screen and (min-width: 1441px){.btn{font-size:var(--px-text-size-base-desktop)}.btn:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset);outline-width:var(--px-outline)}.btn.tertiary ::slotted(px-spinner){width:var(--px-icon-size-m-desktop);height:var(--px-icon-size-m-desktop)}}@keyframes anim-spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}";
|
|
3619
3813
|
const linkStyles$1 = new CSSStyleSheet();
|
|
3620
3814
|
const buttonStyles = new CSSStyleSheet();
|
|
3621
3815
|
const typographyStyles$3 = new CSSStyleSheet();
|
|
@@ -3969,8 +4163,8 @@ customElements.define("px-typography", Typography);
|
|
|
3969
4163
|
const buttonIconCss = ".btn-icon{display:inline-flex;vertical-align:middle;align-items:center;justify-content:center;cursor:pointer;--btn-transition: all .2s ease-in-out 0s;transition:var(--btn-transition);background:var(--px-color-bg-action-primary-default);color:var(--px-color-icon-primary-inverted);border-radius:var(--px-radius-pill);padding:var(--px-padding-xs);border:var(--px-border-m) solid transparent}.btn-icon,.btn-icon *{box-sizing:border-box}.btn-icon ::slotted(px-icon){line-height:0}.btn-icon:hover:not([disabled],[aria-disabled=true],.btn-icon--state-loading){background:var(--px-color-bg-action-hover-bordered-default);color:var(--px-color-icon-primary-default);border-color:var(--px-color-border-action-hover-default)}.btn-icon:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset-s);outline:var(--px-outline-s) solid var(--px-color-outline-default)}.btn-icon[disabled],.btn-icon[aria-disabled=true]{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-icon-disabled-default);cursor:default;pointer-events:none}.btn-icon.btn-icon--state-loading{background:var(--px-color-bg-action-disabled-default);color:var(--px-color-icon-primary-default);cursor:inherit}.btn-icon--size-small{padding:var(--px-padding-2xs)}.btn-icon--variant-secondary{background-color:var(--px-color-bg-action-secondary-default);color:var(--px-color-icon-primary-default)}:host([inverted]) .btn-icon{background:var(--px-color-bg-action-primary-inverted);color:var(--px-color-icon-primary-default)}:host([inverted]) .btn-icon:hover:not([disabled],[aria-disabled=true],.btn-icon--state-loading){background:var(--px-color-bg-action-hover-bordered-default);color:var(--px-color-icon-primary-inverted);border-color:var(--px-color-border-action-hover-inverted)}:host([inverted]) .btn-icon:focus:not([disabled],[aria-disabled=true]){outline-color:var(--px-color-outline-inverted)}:host([inverted]) .btn-icon[disabled],:host([inverted]) .btn-icon[aria-disabled=true]{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-icon-disabled-inverted)}:host([inverted]) .btn-icon.btn-icon--state-loading{background:var(--px-color-bg-action-disabled-inverted);color:var(--px-color-icon-primary-inverted);border-color:transparent}:host([inverted]) .btn-icon--variant-secondary{background-color:var(--px-color-bg-action-secondary-inverted);color:var(--px-color-icon-primary-inverted)}@media screen and (min-width: 1441px){.btn-icon:focus:not([disabled],[aria-disabled=true]){outline-offset:var(--px-offset);outline-width:var(--px-outline)}}";
|
|
3970
4164
|
const buttonIconStyles = new CSSStyleSheet();
|
|
3971
4165
|
buttonIconStyles.replaceSync(buttonIconCss);
|
|
3972
|
-
const
|
|
3973
|
-
const
|
|
4166
|
+
const buttonIconSizeValues = ["", "default", "small"];
|
|
4167
|
+
const buttonIconVariantValues = ["", "default", "secondary"];
|
|
3974
4168
|
const _ButtonIcon = class _ButtonIcon extends PxElement {
|
|
3975
4169
|
constructor() {
|
|
3976
4170
|
super(buttonIconStyles);
|
|
@@ -4013,10 +4207,10 @@ const _ButtonIcon = class _ButtonIcon extends PxElement {
|
|
|
4013
4207
|
this.updateLoading();
|
|
4014
4208
|
break;
|
|
4015
4209
|
case "size":
|
|
4016
|
-
this.updateSize(oldValue, newValue,
|
|
4210
|
+
this.updateSize(oldValue, newValue, buttonIconSizeValues);
|
|
4017
4211
|
break;
|
|
4018
4212
|
case "variant":
|
|
4019
|
-
this.updateVariant(oldValue, newValue,
|
|
4213
|
+
this.updateVariant(oldValue, newValue, buttonIconVariantValues);
|
|
4020
4214
|
break;
|
|
4021
4215
|
default:
|
|
4022
4216
|
super.attributeChangedCallback(attrName, oldValue, newValue);
|
|
@@ -4316,6 +4510,7 @@ class Spinner extends HTMLElement {
|
|
|
4316
4510
|
customElements.define("px-spinner", Spinner);
|
|
4317
4511
|
export {
|
|
4318
4512
|
Accordion,
|
|
4513
|
+
Button,
|
|
4319
4514
|
ButtonIcon,
|
|
4320
4515
|
Container,
|
|
4321
4516
|
Entrypoint,
|
|
@@ -4360,6 +4555,8 @@ export {
|
|
|
4360
4555
|
bgImgSizeValues,
|
|
4361
4556
|
borderRadiusValues,
|
|
4362
4557
|
borderValues,
|
|
4558
|
+
buttonIconSizeValues,
|
|
4559
|
+
buttonIconVariantValues,
|
|
4363
4560
|
colorValues$1 as colorValues,
|
|
4364
4561
|
fontsizeValues,
|
|
4365
4562
|
fontweightValues,
|
|
@@ -4379,9 +4576,8 @@ export {
|
|
|
4379
4576
|
priceSizeValues,
|
|
4380
4577
|
priceVariantValues,
|
|
4381
4578
|
shadowValues,
|
|
4382
|
-
sizeValues,
|
|
4383
4579
|
tagShapeValues,
|
|
4384
4580
|
tagVariantValues,
|
|
4385
4581
|
textalignValues,
|
|
4386
|
-
variantValues
|
|
4582
|
+
variantValues$1 as variantValues
|
|
4387
4583
|
};
|