@proximus/lavender-container 1.4.6-beta.2 → 1.4.6
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/Container.d.ts +4 -17
- package/dist/index.es.js +54 -124
- package/package.json +1 -1
package/dist/Container.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { VerticallyExtendedElement } from '@proximus/lavender-common';
|
|
2
2
|
export declare const anchorSpacingValues: string[];
|
|
3
|
-
export declare
|
|
4
|
-
export declare class Container extends WithExtraAttributes {
|
|
3
|
+
export declare class Container extends VerticallyExtendedElement<HTMLDivElement> {
|
|
5
4
|
static nativeName: string;
|
|
6
5
|
private template;
|
|
7
6
|
private _bgObserver;
|
|
@@ -26,8 +25,6 @@ export declare class Container extends WithExtraAttributes {
|
|
|
26
25
|
updateAnchorOffset(oldValue: string, newValue: string, attrValue: string[]): void;
|
|
27
26
|
addAnchorClass(): void;
|
|
28
27
|
updateAnchorSpacing(oldValue: string, newValue: string, attrValue: string[]): void;
|
|
29
|
-
updateSubgridRows(attrName: string, oldValue: string, newValue: string, attrValues: string[]): void;
|
|
30
|
-
get $el(): HTMLElement;
|
|
31
28
|
get $slotAnchor(): HTMLSlotElement;
|
|
32
29
|
get padding(): string;
|
|
33
30
|
set padding(value: string);
|
|
@@ -141,16 +138,6 @@ export declare class Container extends WithExtraAttributes {
|
|
|
141
138
|
set anchorOffset(value: string);
|
|
142
139
|
get anchorSpacing(): string;
|
|
143
140
|
set anchorSpacing(value: string);
|
|
144
|
-
get inverted():
|
|
145
|
-
set inverted(value:
|
|
146
|
-
get subgridRows(): string;
|
|
147
|
-
set subgridRows(value: string);
|
|
148
|
-
get subgridGap(): string;
|
|
149
|
-
set subgridGap(value: string);
|
|
150
|
-
get subgridGapMobile(): string;
|
|
151
|
-
set subgridGapMobile(value: string);
|
|
152
|
-
get subgridGapTablet(): string;
|
|
153
|
-
set subgridGapTablet(value: string);
|
|
154
|
-
get subgridGapLaptop(): string;
|
|
155
|
-
set subgridGapLaptop(value: string);
|
|
141
|
+
get inverted(): string;
|
|
142
|
+
set inverted(value: string);
|
|
156
143
|
}
|
package/dist/index.es.js
CHANGED
|
@@ -1,86 +1,65 @@
|
|
|
1
|
-
import { cssTokenBreakpoints as
|
|
2
|
-
const C = ':host{display:block}.container{font-family:var(--px-font-family);background-color:var(--background-color);border-radius:var(--px-radius-main);box-sizing:border-box;height:100%}:host([background-image]) .container{background-image:var(--background-image)}:host([background-gradient]) .container{background-image:var(--background-gradient)}:host([inverted]) .container{background-color:var(--background-color-inverted);color:var(--px-color-text-neutral-inverted)}.border-none{border:none}.border-s{border:var(--px-size-border-s) solid var(--border-color)}.border-m{border:var(--px-size-border-m) solid var(--border-color)}.border-l{border:var(--px-size-border-l) solid var(--border-color)}.border-side-top{border-bottom-style:none;border-right-style:none;border-left-style:none}.border-side-right{border-top-style:none;border-bottom-style:none;border-left-style:none}.border-side-bottom{border-top-style:none;border-right-style:none;border-left-style:none}.border-side-left{border-top-style:none;border-right-style:none;border-bottom-style:none}.border-side-block{border-inline-style:none}.border-side-inline{border-block-style:none}:host([inverted]) .border-s,:host([inverted]) .border-m,:host([inverted]) .border-l{border-color:var(--border-color-inverted)}.border-radius-main{border-radius:var(--px-radius-main)}.border-radius-pill{border-radius:var(--px-radius-pill)}.no-border-radius-top{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all,.border-radius-none{border-radius:var(--px-radius-none)}.bgimg{background-repeat:no-repeat}.background-size-cover{background-size:cover;background-position:center center}.background-size-contain{background-size:contain}.box-shadow-none{box-shadow:none}.box-shadow-s{box-shadow:0 1px 2px #2525251f}.box-shadow-m{box-shadow:0 4px 6px -1px #25252514}.box-shadow-l{box-shadow:0 10px 15px -3px #25252514}.box-shadow-xl{box-shadow:0 20px 25px -5px #25252514}.anchored{position:relative}::slotted([slot="anchor-right"]),::slotted([slot="anchor-left"]),::slotted([slot="anchor-full"]){position:absolute;top:0}::slotted([slot="anchor-right"]),::slotted([slot="anchor-left"]){transform:translateY(-50%);z-index:3}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--mobile, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--mobile, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-full"]){transform:translateY(-100%);right:0;left:0;text-align:center;z-index:2}::slotted(px-vstack:only-of-type),::slotted(px-hstack:only-of-type),::slotted(px-stack:only-of-type),::slotted(px-grid:only-of-type){height:100%}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--mobile)}.border-s ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-s) * -1);left:calc(var(--px-size-border-s) * -1)}.border-m ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-m) * -1);left:calc(var(--px-size-border-m) * -1)}.border-l ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-l) * -1);left:calc(var(--px-size-border-l) * -1)}:host([subgrid-rows]){display:contents}:host([subgrid-rows]) .container{display:grid;grid-template-rows:subgrid;grid-row:span var(--subgrid-rows)}:host([subgrid-rows]):host([grow]) .container{flex-grow:var(--grow-value)}:host([subgrid-rows]):host([shrink]) .container{flex-shrink:var(--shrink-value)}:host([subgrid-rows]):host([basis]) .container{flex-basis:var(--basis-value)}:host([subgrid-rows]):host([align-self]) .container{align-self:var(--align-self-value)}:host([subgrid-rows]):host([col-span]) .container{grid-column:span var(--col-span-value) / span var(--col-span-value)}:host([subgrid-rows]):host([justify-self]) .container{justify-self:var(--justify-self-value)}:host([subgrid-rows]):host([order]) .container{order:var(--order-value)}@media only screen and (max-width: 47.938em){.container{background-color:var(--background-color--mobile, var(--background-color))}:host([background-image--mobile]) .container{background-image:var(--background-image--mobile, var(--background-image))}:host([background-gradient--mobile]) .container{background-image:var( --background-gradient--mobile, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--mobile, var(--background-color-inverted) )}.border-side-top--mobile{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--mobile{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--mobile{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--mobile{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--mobile{border-inline-style:none;border-block-style:solid}.border-side-inline--mobile{border-block-style:none;border-inline-style:solid}.no-border-radius-top--mobile{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--mobile{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--mobile{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--mobile{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--mobile{border-radius:var(--px-radius-none)}:host([subgrid-rows]):host([grow--mobile]) .container{flex-grow:var(--grow--mobile-value)}:host([subgrid-rows]):host([shrink--mobile]) .container{flex-shrink:var(--shrink--mobile-value)}:host([subgrid-rows]):host([basis--mobile]) .container{flex-basis:var(--basis--mobile-value)}:host([subgrid-rows]):host([align-self--mobile]) .container{align-self:var(--align-self--mobile-value)}:host([subgrid-rows]):host([col-span--mobile]) .container{grid-column:span var(--col-span--mobile-value) / span var(--col-span--mobile-value)}:host([subgrid-rows]):host([justify-self--mobile]) .container{justify-self:var(--justify-self--mobile-value)}:host([subgrid-rows]):host([order--mobile]) .container{order:var(--order--mobile-value)}}@media only screen and (min-width: 48em) and (max-width: 64em){.container{background-color:var(--background-color--tablet, var(--background-color))}:host([background-image--tablet]) .container{background-image:var(--background-image--tablet, var(--background-image))}:host([background-gradient--tablet]) .container{background-image:var( --background-gradient--tablet, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--tablet, var(--background-color-inverted) )}.no-border-radius-top--tablet{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--tablet{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--tablet{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--tablet{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--tablet{border-radius:var(--px-radius-none)}.border-side-top--tablet{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--tablet{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--tablet{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--tablet{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--tablet{border-inline-style:none;border-block-style:solid}.border-side-inline--tablet{border-block-style:none;border-inline-style:solid}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--tablet, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--tablet, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--tablet)}:host([subgrid-rows]):host([col-span--tablet]) .container{grid-column:span var(--col-span--tablet-value) / span var(--col-span--tablet-value)}:host([subgrid-rows]):host([grow--tablet]) .container{flex-grow:var(--grow--tablet-value)}:host([subgrid-rows]):host([shrink--tablet]) .container{flex-shrink:var(--shrink--tablet-value)}:host([subgrid-rows]):host([basis--tablet]) .container{flex-basis:var(--basis--tablet-value)}:host([subgrid-rows]):host([align-self--tablet]) .container{align-self:var(--align-self--tablet-value)}:host([subgrid-rows]):host([justify-self--tablet]) .container{justify-self:var(--justify-self--tablet-value)}:host([subgrid-rows]):host([order--tablet]) .container{order:var(--order--tablet-value)}}@media only screen and (min-width: 1025px) and (max-width: 1440px){:host([subgrid-rows]):host([col-span--laptop]) .container{grid-column:span var(--col-span--laptop-value) / span var(--col-span--laptop-value)}:host([subgrid-rows]):host([grow--laptop]) .container{flex-grow:var(--grow--laptop-value)}:host([subgrid-rows]):host([shrink--laptop]) .container{flex-shrink:var(--shrink--laptop-value)}:host([subgrid-rows]):host([basis--laptop]) .container{flex-basis:var(--basis--laptop-value)}:host([subgrid-rows]):host([align-self--laptop]) .container{align-self:var(--align-self--laptop-value)}:host([subgrid-rows]):host([justify-self--laptop]) .container{justify-self:var(--justify-self--laptop-value)}:host([subgrid-rows]):host([order--laptop]) .container{order:var(--order--laptop-value)}}@media only screen and (min-width: 64.0625em){.container{background-color:var(--background-color--laptop, var(--background-color))}:host([background-image--laptop]) .container{background-image:var(--background-image--laptop, var(--background-image))}:host([background-gradient--laptop]) .container{background-image:var( --background-gradient--laptop, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--laptop, var(--background-color-inverted) )}.no-border-radius-top--laptop{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--laptop{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--laptop{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--laptop{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--laptop{border-radius:var(--px-radius-none)}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--laptop, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--laptop, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--laptop)}.border-side-top--laptop{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--laptop{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--laptop{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--laptop{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--laptop{border-inline-style:none;border-block-style:solid}.border-side-inline--laptop{border-block-style:none;border-inline-style:solid}}@media screen and (min-width: 1441px){:host([subgrid-rows]):host([col-span--desktop]) .container{grid-column:span var(--col-span--desktop-value) / span var(--col-span--desktop-value)}:host([subgrid-rows]):host([grow--desktop]) .container{flex-grow:var(--grow--desktop-value)}:host([subgrid-rows]):host([shrink--desktop]) .container{flex-shrink:var(--shrink--desktop-value)}:host([subgrid-rows]):host([basis--desktop]) .container{flex-basis:var(--basis--desktop-value)}:host([subgrid-rows]):host([align-self--desktop]) .container{align-self:var(--align-self--desktop-value)}:host([subgrid-rows]):host([justify-self--desktop]) .container{justify-self:var(--justify-self--desktop-value)}:host([subgrid-rows]):host([order--desktop]) .container{order:var(--order--desktop-value)}}', c = new CSSStyleSheet();
|
|
3
|
-
|
|
1
|
+
import { cssTokenBreakpoints as d, paddingValues as a, VerticallyExtendedElement as k, boxShadowValues as m, backgroundSizeValues as f, noBorderRadiusValues as v, borderRadiusValues as A, borderSideValues as y, borderValues as x, gradientValues as $, log as n, backgroundColorValues as L, borderColorValues as B, checkName as c } from "@proximus/lavender-common";
|
|
2
|
+
const C = ':host{display:block}.container{font-family:var(--px-font-family);background-color:var(--background-color);border-radius:var(--px-radius-main);box-sizing:border-box;height:100%}:host([background-image]) .container{background-image:var(--background-image)}:host([background-gradient]) .container{background-image:var(--background-gradient)}:host([inverted]) .container{background-color:var(--background-color-inverted);color:var(--px-color-text-neutral-inverted)}.border-none{border:none}.border-s{border:var(--px-size-border-s) solid var(--border-color)}.border-m{border:var(--px-size-border-m) solid var(--border-color)}.border-l{border:var(--px-size-border-l) solid var(--border-color)}.border-side-top{border-bottom-style:none;border-right-style:none;border-left-style:none}.border-side-right{border-top-style:none;border-bottom-style:none;border-left-style:none}.border-side-bottom{border-top-style:none;border-right-style:none;border-left-style:none}.border-side-left{border-top-style:none;border-right-style:none;border-bottom-style:none}.border-side-block{border-inline-style:none}.border-side-inline{border-block-style:none}:host([inverted]) .border-s,:host([inverted]) .border-m,:host([inverted]) .border-l{border-color:var(--border-color-inverted)}.border-radius-main{border-radius:var(--px-radius-main)}.border-radius-pill{border-radius:var(--px-radius-pill)}.no-border-radius-top{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all,.border-radius-none{border-radius:var(--px-radius-none)}.bgimg{background-repeat:no-repeat}.background-size-cover{background-size:cover;background-position:center center}.background-size-contain{background-size:contain}.box-shadow-none{box-shadow:none}.box-shadow-s{box-shadow:0 1px 2px #2525251f}.box-shadow-m{box-shadow:0 4px 6px -1px #25252514}.box-shadow-l{box-shadow:0 10px 15px -3px #25252514}.box-shadow-xl{box-shadow:0 20px 25px -5px #25252514}.anchored{position:relative}::slotted([slot="anchor-right"]),::slotted([slot="anchor-left"]),::slotted([slot="anchor-full"]){position:absolute;top:0}::slotted([slot="anchor-right"]),::slotted([slot="anchor-left"]){transform:translateY(-50%);z-index:3}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--mobile, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--mobile, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-full"]){transform:translateY(-100%);right:0;left:0;text-align:center;z-index:2}::slotted(px-vstack:only-of-type),::slotted(px-hstack:only-of-type),::slotted(px-stack:only-of-type),::slotted(px-grid:only-of-type){height:100%}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--mobile)}.border-s ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-s) * -1);left:calc(var(--px-size-border-s) * -1)}.border-m ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-m) * -1);left:calc(var(--px-size-border-m) * -1)}.border-l ::slotted([slot="anchor-full"]){right:calc(var(--px-size-border-l) * -1);left:calc(var(--px-size-border-l) * -1)}@media only screen and (max-width: 47.938em){.container{background-color:var(--background-color--mobile, var(--background-color))}:host([background-image--mobile]) .container{background-image:var(--background-image--mobile, var(--background-image))}:host([background-gradient--mobile]) .container{background-image:var( --background-gradient--mobile, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--mobile, var(--background-color-inverted) )}.border-side-top--mobile{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--mobile{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--mobile{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--mobile{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--mobile{border-inline-style:none;border-block-style:solid}.border-side-inline--mobile{border-block-style:none;border-inline-style:solid}.no-border-radius-top--mobile{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--mobile{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--mobile{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--mobile{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--mobile{border-radius:var(--px-radius-none)}}@media only screen and (min-width: 48em) and (max-width: 64em){.container{background-color:var(--background-color--tablet, var(--background-color))}:host([background-image--tablet]) .container{background-image:var(--background-image--tablet, var(--background-image))}:host([background-gradient--tablet]) .container{background-image:var( --background-gradient--tablet, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--tablet, var(--background-color-inverted) )}.no-border-radius-top--tablet{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--tablet{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--tablet{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--tablet{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--tablet{border-radius:var(--px-radius-none)}.border-side-top--tablet{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--tablet{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--tablet{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--tablet{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--tablet{border-inline-style:none;border-block-style:solid}.border-side-inline--tablet{border-block-style:none;border-inline-style:solid}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--tablet, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--tablet, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--tablet)}}@media only screen and (min-width: 64.0625em){.container{background-color:var(--background-color--laptop, var(--background-color))}:host([background-image--laptop]) .container{background-image:var(--background-image--laptop, var(--background-image))}:host([background-gradient--laptop]) .container{background-image:var( --background-gradient--laptop, var(--background-gradient) )}:host([inverted]) .container{background-color:var( --background-color-inverted--laptop, var(--background-color-inverted) )}.no-border-radius-top--laptop{border-top-left-radius:var(--px-radius-none);border-top-right-radius:var(--px-radius-none)}.no-border-radius-right--laptop{border-top-right-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-bottom--laptop{border-bottom-left-radius:var(--px-radius-none);border-bottom-right-radius:var(--px-radius-none)}.no-border-radius-left--laptop{border-top-left-radius:var(--px-radius-none);border-bottom-left-radius:var(--px-radius-none)}.no-border-radius-all--laptop{border-radius:var(--px-radius-none)}::slotted([slot="anchor-right"]){right:var( --container-anchor-offset--laptop, var( --container-padding-right, var(--container-padding-inline, var(--container-padding)) ) )}::slotted([slot="anchor-left"]){left:var( --container-anchor-offset--laptop, var( --container-padding-left, var(--container-padding-inline, var(--container-padding)) ) )}:host([anchor-spacing]){margin-top:var(--container-anchor-spacing--laptop)}.border-side-top--laptop{border-top-style:solid;border-right-style:none;border-bottom-style:none;border-left-style:none}.border-side-right--laptop{border-top-style:none;border-right-style:solid;border-bottom-style:none;border-left-style:none}.border-side-bottom--laptop{border-top-style:none;border-right-style:none;border-bottom-style:solid;border-left-style:none}.border-side-left--laptop{border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:solid}.border-side-block--laptop{border-inline-style:none;border-block-style:solid}.border-side-inline--laptop{border-block-style:none;border-inline-style:solid}}', u = new CSSStyleSheet();
|
|
3
|
+
u.replaceSync(C);
|
|
4
4
|
const S = [
|
|
5
5
|
"has-patch",
|
|
6
6
|
"neighbor-has-patch",
|
|
7
7
|
"has-ribbon",
|
|
8
8
|
"neighbor-has-ribbon"
|
|
9
|
-
], T = [
|
|
10
|
-
|
|
11
|
-
"2",
|
|
12
|
-
"3",
|
|
13
|
-
"4",
|
|
14
|
-
"5",
|
|
15
|
-
"6",
|
|
16
|
-
"7",
|
|
17
|
-
"8",
|
|
18
|
-
"9",
|
|
19
|
-
"10",
|
|
20
|
-
"11",
|
|
21
|
-
"12"
|
|
22
|
-
], n = (h, t, e) => `:host([${h}${e ? `--${e}` : ""}='${t}']) .container`, b = "px-padding", R = [
|
|
23
|
-
a(
|
|
9
|
+
], s = (h, t, e) => `:host([${h}${e ? `--${e}` : ""}='${t}']) .container`, b = "px-padding", T = [
|
|
10
|
+
d(
|
|
24
11
|
"padding",
|
|
25
|
-
|
|
26
|
-
|
|
12
|
+
s,
|
|
13
|
+
a,
|
|
27
14
|
b,
|
|
28
15
|
"--container-padding"
|
|
29
16
|
),
|
|
30
|
-
|
|
17
|
+
d(
|
|
31
18
|
"padding-inline",
|
|
32
|
-
|
|
33
|
-
|
|
19
|
+
s,
|
|
20
|
+
a,
|
|
34
21
|
b
|
|
35
22
|
),
|
|
36
|
-
|
|
23
|
+
d(
|
|
37
24
|
"padding-block",
|
|
38
|
-
|
|
39
|
-
|
|
25
|
+
s,
|
|
26
|
+
a,
|
|
40
27
|
b
|
|
41
28
|
),
|
|
42
|
-
|
|
29
|
+
d(
|
|
43
30
|
"padding-top",
|
|
44
|
-
|
|
45
|
-
|
|
31
|
+
s,
|
|
32
|
+
a,
|
|
46
33
|
b
|
|
47
34
|
),
|
|
48
|
-
|
|
35
|
+
d(
|
|
49
36
|
"padding-right",
|
|
50
|
-
|
|
51
|
-
|
|
37
|
+
s,
|
|
38
|
+
a,
|
|
52
39
|
b,
|
|
53
40
|
"--container-padding-right"
|
|
54
41
|
),
|
|
55
|
-
|
|
42
|
+
d(
|
|
56
43
|
"padding-bottom",
|
|
57
|
-
|
|
58
|
-
|
|
44
|
+
s,
|
|
45
|
+
a,
|
|
59
46
|
b
|
|
60
47
|
),
|
|
61
|
-
|
|
48
|
+
d(
|
|
62
49
|
"padding-left",
|
|
63
|
-
|
|
64
|
-
|
|
50
|
+
s,
|
|
51
|
+
a,
|
|
65
52
|
b,
|
|
66
53
|
"--container-padding-left"
|
|
67
|
-
),
|
|
68
|
-
a(
|
|
69
|
-
"gap",
|
|
70
|
-
n,
|
|
71
|
-
k,
|
|
72
|
-
"px-spacing",
|
|
73
|
-
void 0,
|
|
74
|
-
"subgrid-gap"
|
|
75
54
|
)
|
|
76
|
-
],
|
|
55
|
+
], p = class p extends k {
|
|
77
56
|
constructor() {
|
|
78
|
-
super(
|
|
57
|
+
super(u, ...T), this.template = () => `<div class="container">
|
|
79
58
|
<slot></slot>
|
|
80
59
|
<slot name="anchor-left"></slot>
|
|
81
60
|
<slot name="anchor-right"></slot>
|
|
82
61
|
<slot name="anchor-full"></slot>
|
|
83
|
-
</div>`, this._bgObserver = null, this._isInViewport = !1, this.
|
|
62
|
+
</div>`, this._bgObserver = null, this._isInViewport = !1, this.shadowRoot.innerHTML = this.template();
|
|
84
63
|
}
|
|
85
64
|
static get observedAttributes() {
|
|
86
65
|
return [
|
|
@@ -113,12 +92,11 @@ const S = [
|
|
|
113
92
|
"box-shadow",
|
|
114
93
|
"anchor-offset",
|
|
115
94
|
"anchor-spacing",
|
|
116
|
-
"inverted"
|
|
117
|
-
"subgrid-rows"
|
|
95
|
+
"inverted"
|
|
118
96
|
];
|
|
119
97
|
}
|
|
120
98
|
connectedCallback() {
|
|
121
|
-
this.padding || (this.padding = "m"), this.backgroundColor || (this.backgroundColor = "surface-light"), this.borderColor || (this.borderColor = "main"), this.$slotAnchor && this.addAnchorClass(), this.contentObserver = new MutationObserver(() => {
|
|
99
|
+
super.connectedCallback(), this.padding || (this.padding = "m"), this.backgroundColor || (this.backgroundColor = "surface-light"), this.borderColor || (this.borderColor = "main"), this.$slotAnchor && this.addAnchorClass(), this.contentObserver = new MutationObserver(() => {
|
|
122
100
|
this.$slotAnchor && this.addAnchorClass();
|
|
123
101
|
}), this.contentObserver.observe(this, {
|
|
124
102
|
childList: !0,
|
|
@@ -132,14 +110,14 @@ const S = [
|
|
|
132
110
|
}), this._bgObserver.observe(this.$el);
|
|
133
111
|
}
|
|
134
112
|
disconnectedCallback() {
|
|
135
|
-
var t
|
|
136
|
-
(t = this._bgObserver) == null || t.disconnect(),
|
|
113
|
+
var t;
|
|
114
|
+
(t = this._bgObserver) == null || t.disconnect(), this.contentObserver.disconnect();
|
|
137
115
|
}
|
|
138
116
|
attributeChangedCallback(t, e, r) {
|
|
139
117
|
if (e !== r)
|
|
140
118
|
switch (t) {
|
|
141
119
|
case "border":
|
|
142
|
-
this.updateAttribute(t, e, r,
|
|
120
|
+
this.updateAttribute(t, e, r, x);
|
|
143
121
|
break;
|
|
144
122
|
case "border-color":
|
|
145
123
|
this.updateBorderColor(t, r);
|
|
@@ -148,14 +126,14 @@ const S = [
|
|
|
148
126
|
case "border-side--mobile":
|
|
149
127
|
case "border-side--tablet":
|
|
150
128
|
case "border-side--laptop":
|
|
151
|
-
this.updateAttribute(t, e, r,
|
|
129
|
+
this.updateAttribute(t, e, r, y);
|
|
152
130
|
break;
|
|
153
131
|
case "border-radius":
|
|
154
132
|
this.updateAttribute(
|
|
155
133
|
t,
|
|
156
134
|
e,
|
|
157
135
|
r,
|
|
158
|
-
|
|
136
|
+
A
|
|
159
137
|
);
|
|
160
138
|
break;
|
|
161
139
|
case "no-border-radius":
|
|
@@ -166,7 +144,7 @@ const S = [
|
|
|
166
144
|
t,
|
|
167
145
|
e,
|
|
168
146
|
r,
|
|
169
|
-
|
|
147
|
+
v
|
|
170
148
|
);
|
|
171
149
|
break;
|
|
172
150
|
case "background-color":
|
|
@@ -202,19 +180,11 @@ const S = [
|
|
|
202
180
|
this.updateAttribute(t, e, r, m);
|
|
203
181
|
break;
|
|
204
182
|
case "anchor-offset":
|
|
205
|
-
this.updateAnchorOffset(e, r,
|
|
183
|
+
this.updateAnchorOffset(e, r, a);
|
|
206
184
|
break;
|
|
207
185
|
case "anchor-spacing":
|
|
208
186
|
this.updateAnchorSpacing(e, r, S);
|
|
209
187
|
break;
|
|
210
|
-
case "subgrid-rows":
|
|
211
|
-
this.updateSubgridRows(
|
|
212
|
-
t,
|
|
213
|
-
e,
|
|
214
|
-
r,
|
|
215
|
-
T
|
|
216
|
-
);
|
|
217
|
-
break;
|
|
218
188
|
default:
|
|
219
189
|
super.attributeChangedCallback(t, e, r);
|
|
220
190
|
break;
|
|
@@ -235,7 +205,7 @@ const S = [
|
|
|
235
205
|
this.$el.style.setProperty(`--${t}`, `url("${e}")`);
|
|
236
206
|
}
|
|
237
207
|
updateGradient(t, e) {
|
|
238
|
-
if (this.checkName(
|
|
208
|
+
if (this.checkName($, e)) {
|
|
239
209
|
const r = this.splitAttrNameFromBreakpoint(t);
|
|
240
210
|
t = r.attrName;
|
|
241
211
|
const i = r.breakpoint;
|
|
@@ -244,7 +214,7 @@ const S = [
|
|
|
244
214
|
`linear-gradient(var(--px-color-background-gradient-${e}))`
|
|
245
215
|
);
|
|
246
216
|
} else
|
|
247
|
-
|
|
217
|
+
n(
|
|
248
218
|
`${e} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
249
219
|
);
|
|
250
220
|
}
|
|
@@ -260,7 +230,7 @@ const S = [
|
|
|
260
230
|
`var(--px-color-background-${e}${r ? "" : "-inverted"})`
|
|
261
231
|
);
|
|
262
232
|
} else
|
|
263
|
-
|
|
233
|
+
n(
|
|
264
234
|
`${e} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
265
235
|
);
|
|
266
236
|
}
|
|
@@ -271,13 +241,13 @@ const S = [
|
|
|
271
241
|
), this.$el.style.setProperty(
|
|
272
242
|
`--${t}-inverted`,
|
|
273
243
|
`var(--px-color-border-${e}-inverted)`
|
|
274
|
-
)) :
|
|
244
|
+
)) : n(
|
|
275
245
|
`${e} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
276
246
|
);
|
|
277
247
|
}
|
|
278
248
|
updateNoBorderRadius(t, e, r, i) {
|
|
279
249
|
if (!this.checkName(i, r))
|
|
280
|
-
|
|
250
|
+
n(
|
|
281
251
|
`${r} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
282
252
|
);
|
|
283
253
|
else {
|
|
@@ -291,7 +261,7 @@ const S = [
|
|
|
291
261
|
}
|
|
292
262
|
updateAttribute(t, e, r, i) {
|
|
293
263
|
if (!this.checkName(i, r))
|
|
294
|
-
|
|
264
|
+
n(
|
|
295
265
|
`${r} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
296
266
|
);
|
|
297
267
|
else {
|
|
@@ -314,8 +284,8 @@ const S = [
|
|
|
314
284
|
return { attrName: t, breakpoint: e };
|
|
315
285
|
}
|
|
316
286
|
updateAnchorOffset(t, e, r) {
|
|
317
|
-
if (!
|
|
318
|
-
|
|
287
|
+
if (!c(r, e)) {
|
|
288
|
+
n(
|
|
319
289
|
`${e} is not a valid anchor-offset value for ${this.tagName.toLowerCase()}`
|
|
320
290
|
);
|
|
321
291
|
return;
|
|
@@ -338,8 +308,8 @@ const S = [
|
|
|
338
308
|
this.$el.classList.contains("anchored") || this.$el.classList.add("anchored");
|
|
339
309
|
}
|
|
340
310
|
updateAnchorSpacing(t, e, r) {
|
|
341
|
-
if (!
|
|
342
|
-
|
|
311
|
+
if (!c(r, e)) {
|
|
312
|
+
n(
|
|
343
313
|
`${e} is not a valid anchor-spacing value for ${this.tagName.toLowerCase()}`
|
|
344
314
|
);
|
|
345
315
|
return;
|
|
@@ -358,15 +328,6 @@ const S = [
|
|
|
358
328
|
};
|
|
359
329
|
i(t), i(e);
|
|
360
330
|
}
|
|
361
|
-
updateSubgridRows(t, e, r, i) {
|
|
362
|
-
g(i, r) ? this.style.setProperty(`--${t}`, r) : s(
|
|
363
|
-
`${r} is not an allowed ${t} value for ${this.tagName.toLowerCase()}`
|
|
364
|
-
);
|
|
365
|
-
}
|
|
366
|
-
get $el() {
|
|
367
|
-
var t;
|
|
368
|
-
return (t = this == null ? void 0 : this.shadowRoot) == null ? void 0 : t.querySelector(".container");
|
|
369
|
-
}
|
|
370
331
|
get $slotAnchor() {
|
|
371
332
|
return this.querySelector('[slot^="anchor"]');
|
|
372
333
|
}
|
|
@@ -707,47 +668,16 @@ const S = [
|
|
|
707
668
|
this.setAttribute("anchor-spacing", t);
|
|
708
669
|
}
|
|
709
670
|
get inverted() {
|
|
710
|
-
return this.
|
|
671
|
+
return this.getAttribute("inverted");
|
|
711
672
|
}
|
|
712
673
|
set inverted(t) {
|
|
713
|
-
|
|
714
|
-
}
|
|
715
|
-
get subgridRows() {
|
|
716
|
-
return this.getAttribute("subgrid-rows");
|
|
717
|
-
}
|
|
718
|
-
set subgridRows(t) {
|
|
719
|
-
this.setAttribute("subgrid-rows", t);
|
|
720
|
-
}
|
|
721
|
-
get subgridGap() {
|
|
722
|
-
return this.getAttribute("subgrid-gap");
|
|
723
|
-
}
|
|
724
|
-
set subgridGap(t) {
|
|
725
|
-
this.setAttribute("subgrid-gap", t);
|
|
726
|
-
}
|
|
727
|
-
get subgridGapMobile() {
|
|
728
|
-
return this.getAttribute("subgrid-gap--mobile");
|
|
729
|
-
}
|
|
730
|
-
set subgridGapMobile(t) {
|
|
731
|
-
this.setAttribute("subgrid-gap--mobile", t);
|
|
732
|
-
}
|
|
733
|
-
get subgridGapTablet() {
|
|
734
|
-
return this.getAttribute("subgrid-gap--tablet");
|
|
735
|
-
}
|
|
736
|
-
set subgridGapTablet(t) {
|
|
737
|
-
this.setAttribute("subgrid-gap--tablet", t);
|
|
738
|
-
}
|
|
739
|
-
get subgridGapLaptop() {
|
|
740
|
-
return this.getAttribute("subgrid-gap--laptop");
|
|
741
|
-
}
|
|
742
|
-
set subgridGapLaptop(t) {
|
|
743
|
-
this.setAttribute("subgrid-gap--laptop", t);
|
|
674
|
+
this.setAttribute("inverted", t);
|
|
744
675
|
}
|
|
745
676
|
};
|
|
746
|
-
|
|
747
|
-
let
|
|
748
|
-
customElements.get("px-container") || customElements.define("px-container",
|
|
677
|
+
p.nativeName = "div";
|
|
678
|
+
let g = p;
|
|
679
|
+
customElements.get("px-container") || customElements.define("px-container", g);
|
|
749
680
|
export {
|
|
750
|
-
|
|
751
|
-
S as anchorSpacingValues
|
|
752
|
-
T as subgridRowsValues
|
|
681
|
+
g as Container,
|
|
682
|
+
S as anchorSpacingValues
|
|
753
683
|
};
|