@cupra/ui-kit 2.0.0-canary.208 → 2.0.0-canary.209
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/cjs/components/ds-banner/styles/common.styles.cjs +21 -0
- package/dist/cjs/components/ds-map-pin/ds-map-pin.cjs +4 -4
- package/dist/cjs/components/ds-theme-provider/ds-theme-provider.cjs +1 -1
- package/dist/cjs/decorators/customUiKitElement.cjs +1 -1
- package/dist/cjs/utils/IconsManager.cjs +1 -1
- package/dist/cjs/utils/PubSub.cjs +1 -1
- package/dist/cjs/utils/StylesRegistry/StylesRegistry.cjs +1 -1
- package/dist/cjs/utils/version.cjs +1 -1
- package/dist/esm/components/ds-banner/styles/common.styles.js +21 -0
- package/dist/esm/components/ds-map-pin/ds-map-pin.js +37 -24
- package/dist/esm/components/ds-theme-provider/ds-theme-provider.js +1 -1
- package/dist/esm/decorators/customUiKitElement.js +1 -1
- package/dist/esm/utils/IconsManager.js +1 -1
- package/dist/esm/utils/PubSub.js +1 -1
- package/dist/esm/utils/StylesRegistry/StylesRegistry.js +1 -1
- package/dist/esm/utils/version.js +1 -1
- package/dist/types/components/ds-map-pin/ds-map-pin.d.ts +5 -1
- package/dist/types/components/ds-map-pin/ds-map-pin.types.d.ts +1 -0
- package/dist-react/cjs/components/ds-banner/styles/common.styles.cjs +21 -0
- package/dist-react/cjs/components/ds-map-pin/ds-map-pin.cjs +4 -4
- package/dist-react/cjs/components/ds-theme-provider/ds-theme-provider.cjs +1 -1
- package/dist-react/cjs/decorators/customUiKitElement.cjs +1 -1
- package/dist-react/cjs/utils/IconsManager.cjs +1 -1
- package/dist-react/cjs/utils/PubSub.cjs +1 -1
- package/dist-react/cjs/utils/StylesRegistry/StylesRegistry.cjs +1 -1
- package/dist-react/cjs/utils/version.cjs +1 -1
- package/dist-react/esm/components/ds-banner/styles/common.styles.js +21 -0
- package/dist-react/esm/components/ds-map-pin/ds-map-pin.js +37 -24
- package/dist-react/esm/components/ds-theme-provider/ds-theme-provider.js +1 -1
- package/dist-react/esm/decorators/customUiKitElement.js +1 -1
- package/dist-react/esm/utils/IconsManager.js +1 -1
- package/dist-react/esm/utils/PubSub.js +1 -1
- package/dist-react/esm/utils/StylesRegistry/StylesRegistry.js +1 -1
- package/dist-react/esm/utils/version.js +1 -1
- package/dist-react/types/components/ds-map-pin/ds-map-pin.d.ts +5 -1
- package/dist-react/types/components/ds-map-pin/ds-map-pin.types.d.ts +1 -0
- package/package.json +2 -2
|
@@ -7,6 +7,7 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
7
7
|
display: flex;
|
|
8
8
|
align-items: flex-start;
|
|
9
9
|
position: var(--ui-kit-banner-position, static);
|
|
10
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
10
11
|
}
|
|
11
12
|
|
|
12
13
|
.container.horizontal {
|
|
@@ -24,6 +25,15 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
24
25
|
box-sizing: border-box;
|
|
25
26
|
flex: 1 1 auto;
|
|
26
27
|
min-width: 0;
|
|
28
|
+
background-color: var(--ui-kit-banner-background-color, var(--ds-color-surface-elevated, #15181e));
|
|
29
|
+
border-radius: var(--ui-kit-banner-border-radius, var(--ds-border-radius-m, 12px));
|
|
30
|
+
box-shadow: var(
|
|
31
|
+
--ui-kit-banner-box-shadow,
|
|
32
|
+
0 var(--ds-shadow-vertical-level-02, 8px) var(--ds-shadow-blur-level-04, 32px)
|
|
33
|
+
var(--ds-shadow-spread-none, 0) var(--ds-color-shadow-level-02, #09090b99)
|
|
34
|
+
);
|
|
35
|
+
padding: var(--ds-spacing-layout-s, 16px);
|
|
36
|
+
gap: var(--ds-spacing-layout-s, 16px);
|
|
27
37
|
}
|
|
28
38
|
|
|
29
39
|
.container.horizontal .banner {
|
|
@@ -39,22 +49,33 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
39
49
|
flex: 1 1 auto;
|
|
40
50
|
min-width: 0;
|
|
41
51
|
flex-direction: column;
|
|
52
|
+
gap: var(--ds-spacing-m-2, 16px);
|
|
42
53
|
}
|
|
43
54
|
|
|
44
55
|
slot[name='image']::slotted(*) {
|
|
45
56
|
display: block;
|
|
57
|
+
border-radius: var(--ds-border-radius-s, 8px);
|
|
58
|
+
object-fit: cover;
|
|
46
59
|
}
|
|
47
60
|
|
|
48
61
|
slot:not([name]) {
|
|
49
62
|
display: block;
|
|
50
63
|
flex: 0 0 auto;
|
|
51
64
|
min-width: 0;
|
|
65
|
+
color: var(--ds-color-text-default, #fafafa);
|
|
66
|
+
font-family: var(--ds-typography-family-primary);
|
|
67
|
+
font-size: var(--ds-typography-size-body-l, 16px);
|
|
68
|
+
font-style: normal;
|
|
69
|
+
font-weight: var(--ds-typography-weight-body-primary, 400);
|
|
70
|
+
line-height: var(--ds-typography-height-body-l, 24px);
|
|
71
|
+
letter-spacing: var(--ds-typography-letter-spacing-m, 0.5px);
|
|
52
72
|
}
|
|
53
73
|
|
|
54
74
|
slot[name='actions'] {
|
|
55
75
|
display: flex;
|
|
56
76
|
flex-wrap: wrap;
|
|
57
77
|
flex-shrink: 0;
|
|
78
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
58
79
|
}
|
|
59
80
|
|
|
60
81
|
.container.horizontal slot[name='actions'] {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const t=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const
|
|
1
|
+
const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const t=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs"),n=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const r=require("../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.cjs"),i=require("../base/UiKitElement.cjs"),a=require("../../decorators/customUiKitElement.cjs");require("../ds-icon/ds-icon.cjs");const o=require("../../utils/booleanConverter.cjs"),s=require("../../utils/uiKitHtml.cjs"),c=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/class-map.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/class-map.cjs");const l=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/if-defined.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/if-defined.cjs");const u=require("./styles/common.styles.cjs");var d,f=(d=class extends i.UiKitElement{constructor(...e){super(...e),this.width=48,this.height=48,this._checked=void 0,this.initialChecked=!1,this.iconSize=24,this.iconTop=8}get checked(){return this._checked??this._checkedState??this.initialChecked}set checked(e){this._checked=e}get iconTemplate(){return this.iconName?s.uiKitHtml`<ds-icon class="icon" icon-name=${l.o(this.iconName)} size=${l.o(this.iconSize)}></ds-icon>`:e.E}get clusterNumberTemplate(){return this.clusterCount?e.x`
|
|
2
2
|
<div class='cluster-count'>
|
|
3
3
|
${this.clusterCount}
|
|
4
4
|
</div>
|
|
5
|
-
`:e.E}handleClick(){this.checked
|
|
5
|
+
`:e.E}handleClick(){let e=!this.checked;this._checked===void 0&&(this._checkedState=e),this.dispatchEvent(new CustomEvent(`change`,{bubbles:!0,composed:!0,detail:{checked:e}}))}get styleTokens(){return e.x`
|
|
6
6
|
<style>
|
|
7
7
|
.icon {
|
|
8
8
|
top: ${this.iconTop}px;
|
|
@@ -10,7 +10,7 @@ const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/l
|
|
|
10
10
|
</style>
|
|
11
11
|
`}get classes(){return{container:!0,checked:this.checked,cluster:!!this.clusterCount}}render(){return e.x`
|
|
12
12
|
${this.styleTokens}
|
|
13
|
-
<span data-testid="ds-map-pin-container" class=${
|
|
13
|
+
<span data-testid="ds-map-pin-container" class=${c.e(this.classes)} @click=${this.handleClick}>
|
|
14
14
|
<svg
|
|
15
15
|
class="marker"
|
|
16
16
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -28,4 +28,4 @@ const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/l
|
|
|
28
28
|
${this.iconTemplate}
|
|
29
29
|
${this.clusterNumberTemplate}
|
|
30
30
|
</span>
|
|
31
|
-
`}},
|
|
31
|
+
`}},d.styles=[u.mapPinStyles],d);r.__decorate([t.n({type:Number,attribute:`width`})],f.prototype,`width`,void 0),r.__decorate([t.n({type:Number,attribute:`height`})],f.prototype,`height`,void 0),r.__decorate([t.n({type:Boolean,attribute:`checked`,converter:o.booleanConverter,reflect:!0})],f.prototype,`_checked`,void 0),r.__decorate([t.n({type:Boolean,converter:o.booleanConverter,attribute:`initial-checked`})],f.prototype,`initialChecked`,void 0),r.__decorate([n.r()],f.prototype,`_checkedState`,void 0),r.__decorate([t.n({type:String,attribute:`icon-name`})],f.prototype,`iconName`,void 0),r.__decorate([t.n({type:Number,attribute:`icon-size`})],f.prototype,`iconSize`,void 0),r.__decorate([t.n({type:Number,attribute:`icon-top`})],f.prototype,`iconTop`,void 0),r.__decorate([t.n({type:Number,attribute:`cluster-count`})],f.prototype,`clusterCount`,void 0),f=r.__decorate([a.customUiKitElement(`ds-map-pin`)],f);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
const e=require("../../node_modules/.pnpm/@lit_context@1.1.6/node_modules/@lit/context/lib/decorators/provide.cjs"),t=require("./themeContext.cjs");require("../../core/theme.constants.cjs");const n=require("../../utils/PubSub.cjs"),r=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs"),i=require("../../node_modules/.pnpm/lit-element@4.2.1/node_modules/lit-element/lit-element.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const a=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs"),o=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const s=require("../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.cjs"),c=require("../../decorators/customUiKitElement.cjs"),l=require("../../utils/booleanConverter.cjs"),u=require("../../styles/source/shared/fonts-config.cjs");var d=class extends i.i{constructor(...e){super(...e),this.loadFonts=!0,this.loadStyles=!0,this.loadUnusedStyles=!0,this.cssLoaded=!1,this.loadedFonts=new Set}updated(e){if(super.updated(e),e.has(`theme`)){var t,r;n.pubSub.publish(`theme`,this.theme),(t=sessionStorage)==null||t.setItem(`@cupra/ui-kit/theme`,this.theme),typeof FontFace<`u`&&(r=document)!=null&&r.fonts&&this.loadThemeFonts(),this.loadThemeStyles().then(()=>{this.cssLoaded=!0,this.dispatchEvent(new CustomEvent(`ui-kit:ready`,{bubbles:!0,composed:!0}))})}}loadThemeFonts(){var e;(e=u.fontsConfig[this.theme])==null||e.fonts.forEach(e=>{this.loadThemeFont(e)})}async loadThemeFont({weight:e,name:t,file:n}){if(!this.loadFonts)return Promise.resolve();let r=`${t}-${e}`;if(this.loadedFonts.has(r))return;let i=new FontFace(t,`url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.woff2') format('woff2'),
|
|
2
2
|
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.woff') format('woff'),
|
|
3
3
|
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.ttf') format('truetype'),
|
|
4
|
-
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.otf') format('opentype')`,{style:`normal`,weight:e,display:`optional`});try{await i.load(),document.fonts.add(i),this.loadedFonts.add(r)}catch(n){console.error(`Error loading "${t}" font with "${e}" weight:`,n)}}loadThemeStyles(){let e=`/2.0.0-canary.
|
|
4
|
+
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.otf') format('opentype')`,{style:`normal`,weight:e,display:`optional`});try{await i.load(),document.fonts.add(i),this.loadedFonts.add(r)}catch(n){console.error(`Error loading "${t}" font with "${e}" weight:`,n)}}loadThemeStyles(){let e=`/2.0.0-canary.209`;return this.loadUnusedStyles&&this.applyUnusedStyles(e),this.loadStyles?new Promise((t,n)=>{let r=`https://ds-assets.cupra.com${e}/styles/${this.theme}/theme.css`;if(document.head.querySelector(`link[href="${r}"]`))t();else{let i=`ui-kit-theme-${e}`,a=document.getElementById(i),o=document.createElement(`link`);o.id=i,o.rel=`stylesheet`,o.href=r,o.onload=()=>t(),o.onerror=()=>n(Error(`Failed to load theme CSS: ${r}`)),document.head.appendChild(o),a==null||a.remove()}}):Promise.resolve()}applyUnusedStyles(e){let t=`https://ds-assets.cupra.com${e}/styles/${this.theme}/unused-styles.css`;if(document.head.querySelector(`link[href="${t}"]`))return;let n=`ui-kit-unused-styles-${e}`,r=document.getElementById(n),i=document.createElement(`link`);i.id=n,i.rel=`preload`,i.as=`style`,i.href=t,i.onload=()=>{i.rel=`stylesheet`},document.head.appendChild(i),r==null||r.remove()}render(){return this.cssLoaded?r.x`<slot></slot>`:r.E}};s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-fonts`})],d.prototype,`loadFonts`,void 0),s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-styles`})],d.prototype,`loadStyles`,void 0),s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-unused-styles`})],d.prototype,`loadUnusedStyles`,void 0),s.__decorate([e.e({context:t.themeContext}),a.n({type:String})],d.prototype,`theme`,void 0),s.__decorate([o.r()],d.prototype,`cssLoaded`,void 0),s.__decorate([o.r()],d.prototype,`loadedFonts`,void 0),d=s.__decorate([c.customUiKitElement(`ds-theme-provider`)],d);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
require("../utils/version.cjs");function e(e,t){return function(n){var r,i,a,o;if(!(n!=null&&n.prototype))throw TypeError(`@customUiKitElement requires a class that extends HTMLElement.`);let s=e;if(!((r=globalThis)==null||(r=r.customElements)==null)&&r.get(s))return;let c=t!=null&&t.skipTagAsComponentName?[]:[e];Array.isArray(t==null?void 0:t.extendComponentNames)&&(c=[...t.extendComponentNames,...c]),(i=globalThis)==null||(i=i.customElements)==null||(a=i.define)==null||a.call(i,s,(o=class extends n{connectedCallback(){var t;(t=n.prototype.connectedCallback)==null||t.call(this),this.setAttribute(`data-ui-kit-version`,`2.0.0-canary.
|
|
1
|
+
require("../utils/version.cjs");function e(e,t){return function(n){var r,i,a,o;if(!(n!=null&&n.prototype))throw TypeError(`@customUiKitElement requires a class that extends HTMLElement.`);let s=e;if(!((r=globalThis)==null||(r=r.customElements)==null)&&r.get(s))return;let c=t!=null&&t.skipTagAsComponentName?[]:[e];Array.isArray(t==null?void 0:t.extendComponentNames)&&(c=[...t.extendComponentNames,...c]),(i=globalThis)==null||(i=i.customElements)==null||(a=i.define)==null||a.call(i,s,(o=class extends n{connectedCallback(){var t;(t=n.prototype.connectedCallback)==null||t.call(this),this.setAttribute(`data-ui-kit-version`,`2.0.0-canary.209`),this.setAttribute(`data-ui-kit-component-name`,e)}},o.componentName=c,o))}}exports.customUiKitElement=e;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require("../core/theme.constants.cjs"),t=require("./PubSub.cjs");var n=class{constructor(){this.icons={},this.handleChangeTheme=e=>{if(this.theme===e)return;this.theme=e;let t=Object.keys(this.icons);this.icons={},t.forEach(e=>this.fetchIcon(e))},this.fetchIcon=async(t,n={})=>{var r;let i=typeof sessionStorage<`u`?(r=sessionStorage)==null?void 0:r.getItem(e.THEME_STORAGE_KEY):null;!this.theme&&i&&(this.theme=i);let a=this.icons[t];if(a)return await a;let o=this.loadIcon(t,n).catch(e=>{throw delete this.icons[t],e});return this.icons[t]=o,o},this.loadIcon=(e,{cache:t=`force-cache`,...n})=>!this.theme||typeof fetch>`u`?Promise.resolve(`<svg class="ds-icon"></svg>`):fetch(`https://ds-assets.cupra.com/icons/${this.theme}/${e}.svg`,{cache:t,...n}).then(e=>e.text()).catch(t=>{if((t==null?void 0:t.name)===`AbortError`)throw t;return console.error(`Failed to fetch icon "${e}":`,t),``}),t.pubSub.subscribe(`theme`,this.handleChangeTheme)}},r=Symbol.for(`@cupra/ui-kit/icons-manager/2.0.0-canary.
|
|
1
|
+
const e=require("../core/theme.constants.cjs"),t=require("./PubSub.cjs");var n=class{constructor(){this.icons={},this.handleChangeTheme=e=>{if(this.theme===e)return;this.theme=e;let t=Object.keys(this.icons);this.icons={},t.forEach(e=>this.fetchIcon(e))},this.fetchIcon=async(t,n={})=>{var r;let i=typeof sessionStorage<`u`?(r=sessionStorage)==null?void 0:r.getItem(e.THEME_STORAGE_KEY):null;!this.theme&&i&&(this.theme=i);let a=this.icons[t];if(a)return await a;let o=this.loadIcon(t,n).catch(e=>{throw delete this.icons[t],e});return this.icons[t]=o,o},this.loadIcon=(e,{cache:t=`force-cache`,...n})=>!this.theme||typeof fetch>`u`?Promise.resolve(`<svg class="ds-icon"></svg>`):fetch(`https://ds-assets.cupra.com/icons/${this.theme}/${e}.svg`,{cache:t,...n}).then(e=>e.text()).catch(t=>{if((t==null?void 0:t.name)===`AbortError`)throw t;return console.error(`Failed to fetch icon "${e}":`,t),``}),t.pubSub.subscribe(`theme`,this.handleChangeTheme)}},r=Symbol.for(`@cupra/ui-kit/icons-manager/2.0.0-canary.209`),i=globalThis,a=i[r];a||(a=new n,Object.defineProperty(i,r,{value:a,writable:!1,configurable:!1,enumerable:!1}));var o=a;exports.iconsManager=o;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=class{constructor(){this.subscribers={},this.lastPublishedData={}}subscribe(e,t){return this.subscribers[e]||(this.subscribers[e]=[]),this.subscribers[e].push(t),this.lastPublishedData[e]}unsubscribe(e,t){this.subscribers[e]&&(this.subscribers[e]=this.subscribers[e].filter(e=>e!==t))}publish(e,t){this.lastPublishedData[e]=t,this.subscribers[e]&&this.subscribers[e].forEach(n=>{try{n(t)}catch(t){console.error(`Error in subscriber for event "${e}":`,t)}})}},t=Symbol.for(`@cupra/ui-kit/pubsub/2.0.0-canary.
|
|
1
|
+
var e=class{constructor(){this.subscribers={},this.lastPublishedData={}}subscribe(e,t){return this.subscribers[e]||(this.subscribers[e]=[]),this.subscribers[e].push(t),this.lastPublishedData[e]}unsubscribe(e,t){this.subscribers[e]&&(this.subscribers[e]=this.subscribers[e].filter(e=>e!==t))}publish(e,t){this.lastPublishedData[e]=t,this.subscribers[e]&&this.subscribers[e].forEach(n=>{try{n(t)}catch(t){console.error(`Error in subscriber for event "${e}":`,t)}})}},t=Symbol.for(`@cupra/ui-kit/pubsub/2.0.0-canary.209`),n=globalThis,r=n[t];r||(r=new e,Object.defineProperty(n,t,{value:r,writable:!1,configurable:!1,enumerable:!1}));var i=r;exports.pubSub=i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=require("../concurrencyLimit.cjs").concurrencyLimit(20),t=class t{constructor(){this.stylePromises=new Map,this.getStyles=async({componentName:t,theme:n})=>{if(!n||!t)return;let r=`https://ds-assets.cupra.com/2.0.0-canary.
|
|
1
|
+
var e=require("../concurrencyLimit.cjs").concurrencyLimit(20),t=class t{constructor(){this.stylePromises=new Map,this.getStyles=async({componentName:t,theme:n})=>{if(!n||!t)return;let r=`https://ds-assets.cupra.com/2.0.0-canary.209/styles/${n}/components/${t}.css`,i=this.getCachedStyleSheetPromise({url:r});if(i)return i;let a=e(()=>this.fetchStyle({url:r})).then(e=>(e||this.stylePromises.delete(r),e));return this.stylePromises.set(r,a),this.stylePromises.get(r)}}async fetchStyle({url:e}){try{if(typeof fetch>`u`)return;let t=await fetch(e,{cache:`force-cache`});if(t.ok)return t.text()}catch(t){console.error(`Failed to fetch Style Sheet "${e}":`,t)}}getCachedStyleSheetPromise({url:e}){return this.stylePromises.get(e)}static getInstance(){return t.instance||(t.instance=new t),t.instance}}.getInstance();exports.stylesRegistry=t;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`2.0.0-canary.
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`2.0.0-canary.209`,t=`--v${e.replaceAll(`.`,`-`)}`;exports.VERSION=e,exports.VERSION_TAG_SUFFIX=t;
|
|
@@ -10,6 +10,7 @@ var t = e`
|
|
|
10
10
|
display: flex;
|
|
11
11
|
align-items: flex-start;
|
|
12
12
|
position: var(--ui-kit-banner-position, static);
|
|
13
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
.container.horizontal {
|
|
@@ -27,6 +28,15 @@ var t = e`
|
|
|
27
28
|
box-sizing: border-box;
|
|
28
29
|
flex: 1 1 auto;
|
|
29
30
|
min-width: 0;
|
|
31
|
+
background-color: var(--ui-kit-banner-background-color, var(--ds-color-surface-elevated, #15181e));
|
|
32
|
+
border-radius: var(--ui-kit-banner-border-radius, var(--ds-border-radius-m, 12px));
|
|
33
|
+
box-shadow: var(
|
|
34
|
+
--ui-kit-banner-box-shadow,
|
|
35
|
+
0 var(--ds-shadow-vertical-level-02, 8px) var(--ds-shadow-blur-level-04, 32px)
|
|
36
|
+
var(--ds-shadow-spread-none, 0) var(--ds-color-shadow-level-02, #09090b99)
|
|
37
|
+
);
|
|
38
|
+
padding: var(--ds-spacing-layout-s, 16px);
|
|
39
|
+
gap: var(--ds-spacing-layout-s, 16px);
|
|
30
40
|
}
|
|
31
41
|
|
|
32
42
|
.container.horizontal .banner {
|
|
@@ -42,22 +52,33 @@ var t = e`
|
|
|
42
52
|
flex: 1 1 auto;
|
|
43
53
|
min-width: 0;
|
|
44
54
|
flex-direction: column;
|
|
55
|
+
gap: var(--ds-spacing-m-2, 16px);
|
|
45
56
|
}
|
|
46
57
|
|
|
47
58
|
slot[name='image']::slotted(*) {
|
|
48
59
|
display: block;
|
|
60
|
+
border-radius: var(--ds-border-radius-s, 8px);
|
|
61
|
+
object-fit: cover;
|
|
49
62
|
}
|
|
50
63
|
|
|
51
64
|
slot:not([name]) {
|
|
52
65
|
display: block;
|
|
53
66
|
flex: 0 0 auto;
|
|
54
67
|
min-width: 0;
|
|
68
|
+
color: var(--ds-color-text-default, #fafafa);
|
|
69
|
+
font-family: var(--ds-typography-family-primary);
|
|
70
|
+
font-size: var(--ds-typography-size-body-l, 16px);
|
|
71
|
+
font-style: normal;
|
|
72
|
+
font-weight: var(--ds-typography-weight-body-primary, 400);
|
|
73
|
+
line-height: var(--ds-typography-height-body-l, 24px);
|
|
74
|
+
letter-spacing: var(--ds-typography-letter-spacing-m, 0.5px);
|
|
55
75
|
}
|
|
56
76
|
|
|
57
77
|
slot[name='actions'] {
|
|
58
78
|
display: flex;
|
|
59
79
|
flex-wrap: wrap;
|
|
60
80
|
flex-shrink: 0;
|
|
81
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
61
82
|
}
|
|
62
83
|
|
|
63
84
|
.container.horizontal slot[name='actions'] {
|
|
@@ -1,25 +1,32 @@
|
|
|
1
1
|
import { E as e, x as t } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.js";
|
|
2
2
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.js";
|
|
3
3
|
import { n } from "../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.js";
|
|
4
|
+
import { r } from "../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.js";
|
|
4
5
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.js";
|
|
5
|
-
import { __decorate as
|
|
6
|
-
import { UiKitElement as
|
|
7
|
-
import { customUiKitElement as
|
|
6
|
+
import { __decorate as i } from "../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.js";
|
|
7
|
+
import { UiKitElement as a } from "../base/UiKitElement.js";
|
|
8
|
+
import { customUiKitElement as o } from "../../decorators/customUiKitElement.js";
|
|
8
9
|
import "../ds-icon/ds-icon.js";
|
|
9
|
-
import { booleanConverter as
|
|
10
|
-
import { uiKitHtml as
|
|
11
|
-
import { e as
|
|
10
|
+
import { booleanConverter as s } from "../../utils/booleanConverter.js";
|
|
11
|
+
import { uiKitHtml as c } from "../../utils/uiKitHtml.js";
|
|
12
|
+
import { e as l } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/class-map.js";
|
|
12
13
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/class-map.js";
|
|
13
|
-
import { o as
|
|
14
|
+
import { o as u } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/if-defined.js";
|
|
14
15
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/if-defined.js";
|
|
15
|
-
import { mapPinStyles as
|
|
16
|
+
import { mapPinStyles as d } from "./styles/common.styles.js";
|
|
16
17
|
//#region src/components/ds-map-pin/ds-map-pin.ts
|
|
17
|
-
var
|
|
18
|
+
var f, p = (f = class extends a {
|
|
18
19
|
constructor(...e) {
|
|
19
|
-
super(...e), this.width = 48, this.height = 48, this.
|
|
20
|
+
super(...e), this.width = 48, this.height = 48, this._checked = void 0, this.initialChecked = !1, this.iconSize = 24, this.iconTop = 8;
|
|
21
|
+
}
|
|
22
|
+
get checked() {
|
|
23
|
+
return this._checked ?? this._checkedState ?? this.initialChecked;
|
|
24
|
+
}
|
|
25
|
+
set checked(e) {
|
|
26
|
+
this._checked = e;
|
|
20
27
|
}
|
|
21
28
|
get iconTemplate() {
|
|
22
|
-
return this.iconName ?
|
|
29
|
+
return this.iconName ? c`<ds-icon class="icon" icon-name=${u(this.iconName)} size=${u(this.iconSize)}></ds-icon>` : e;
|
|
23
30
|
}
|
|
24
31
|
get clusterNumberTemplate() {
|
|
25
32
|
return this.clusterCount ? t`
|
|
@@ -29,10 +36,11 @@ var d, f = (d = class extends i {
|
|
|
29
36
|
` : e;
|
|
30
37
|
}
|
|
31
38
|
handleClick() {
|
|
32
|
-
|
|
39
|
+
let e = !this.checked;
|
|
40
|
+
this._checked === void 0 && (this._checkedState = e), this.dispatchEvent(new CustomEvent("change", {
|
|
33
41
|
bubbles: !0,
|
|
34
42
|
composed: !0,
|
|
35
|
-
detail: { checked:
|
|
43
|
+
detail: { checked: e }
|
|
36
44
|
}));
|
|
37
45
|
}
|
|
38
46
|
get styleTokens() {
|
|
@@ -54,7 +62,7 @@ var d, f = (d = class extends i {
|
|
|
54
62
|
render() {
|
|
55
63
|
return t`
|
|
56
64
|
${this.styleTokens}
|
|
57
|
-
<span data-testid="ds-map-pin-container" class=${
|
|
65
|
+
<span data-testid="ds-map-pin-container" class=${l(this.classes)} @click=${this.handleClick}>
|
|
58
66
|
<svg
|
|
59
67
|
class="marker"
|
|
60
68
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -74,28 +82,33 @@ var d, f = (d = class extends i {
|
|
|
74
82
|
</span>
|
|
75
83
|
`;
|
|
76
84
|
}
|
|
77
|
-
},
|
|
78
|
-
|
|
85
|
+
}, f.styles = [d], f);
|
|
86
|
+
i([n({
|
|
79
87
|
type: Number,
|
|
80
88
|
attribute: "width"
|
|
81
|
-
})],
|
|
89
|
+
})], p.prototype, "width", void 0), i([n({
|
|
82
90
|
type: Number,
|
|
83
91
|
attribute: "height"
|
|
84
|
-
})],
|
|
92
|
+
})], p.prototype, "height", void 0), i([n({
|
|
85
93
|
type: Boolean,
|
|
86
|
-
|
|
94
|
+
attribute: "checked",
|
|
95
|
+
converter: s,
|
|
87
96
|
reflect: !0
|
|
88
|
-
})],
|
|
97
|
+
})], p.prototype, "_checked", void 0), i([n({
|
|
98
|
+
type: Boolean,
|
|
99
|
+
converter: s,
|
|
100
|
+
attribute: "initial-checked"
|
|
101
|
+
})], p.prototype, "initialChecked", void 0), i([r()], p.prototype, "_checkedState", void 0), i([n({
|
|
89
102
|
type: String,
|
|
90
103
|
attribute: "icon-name"
|
|
91
|
-
})],
|
|
104
|
+
})], p.prototype, "iconName", void 0), i([n({
|
|
92
105
|
type: Number,
|
|
93
106
|
attribute: "icon-size"
|
|
94
|
-
})],
|
|
107
|
+
})], p.prototype, "iconSize", void 0), i([n({
|
|
95
108
|
type: Number,
|
|
96
109
|
attribute: "icon-top"
|
|
97
|
-
})],
|
|
110
|
+
})], p.prototype, "iconTop", void 0), i([n({
|
|
98
111
|
type: Number,
|
|
99
112
|
attribute: "cluster-count"
|
|
100
|
-
})],
|
|
113
|
+
})], p.prototype, "clusterCount", void 0), p = i([o("ds-map-pin")], p);
|
|
101
114
|
//#endregion
|
|
@@ -53,7 +53,7 @@ var f = class extends a {
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
loadThemeStyles() {
|
|
56
|
-
let e = "/2.0.0-canary.
|
|
56
|
+
let e = "/2.0.0-canary.209";
|
|
57
57
|
return this.loadUnusedStyles && this.applyUnusedStyles(e), this.loadStyles ? new Promise((t, n) => {
|
|
58
58
|
let r = `https://ds-assets.cupra.com${e}/styles/${this.theme}/theme.css`;
|
|
59
59
|
if (document.head.querySelector(`link[href="${r}"]`)) t();
|
|
@@ -10,7 +10,7 @@ function e(e, t) {
|
|
|
10
10
|
Array.isArray(t == null ? void 0 : t.extendComponentNames) && (c = [...t.extendComponentNames, ...c]), (i = globalThis) == null || (i = i.customElements) == null || (a = i.define) == null || a.call(i, s, (o = class extends n {
|
|
11
11
|
connectedCallback() {
|
|
12
12
|
var t;
|
|
13
|
-
(t = n.prototype.connectedCallback) == null || t.call(this), this.setAttribute("data-ui-kit-version", "2.0.0-canary.
|
|
13
|
+
(t = n.prototype.connectedCallback) == null || t.call(this), this.setAttribute("data-ui-kit-version", "2.0.0-canary.209"), this.setAttribute("data-ui-kit-component-name", e);
|
|
14
14
|
}
|
|
15
15
|
}, o.componentName = c, o));
|
|
16
16
|
};
|
|
@@ -26,7 +26,7 @@ var n = class {
|
|
|
26
26
|
return console.error(`Failed to fetch icon "${e}":`, t), "";
|
|
27
27
|
}), t.subscribe("theme", this.handleChangeTheme);
|
|
28
28
|
}
|
|
29
|
-
}, r = Symbol.for("@cupra/ui-kit/icons-manager/2.0.0-canary.
|
|
29
|
+
}, r = Symbol.for("@cupra/ui-kit/icons-manager/2.0.0-canary.209"), i = globalThis, a = i[r];
|
|
30
30
|
a || (a = new n(), Object.defineProperty(i, r, {
|
|
31
31
|
value: a,
|
|
32
32
|
writable: !1,
|
package/dist/esm/utils/PubSub.js
CHANGED
|
@@ -18,7 +18,7 @@ var e = class {
|
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
|
-
}, t = Symbol.for("@cupra/ui-kit/pubsub/2.0.0-canary.
|
|
21
|
+
}, t = Symbol.for("@cupra/ui-kit/pubsub/2.0.0-canary.209"), n = globalThis, r = n[t];
|
|
22
22
|
r || (r = new e(), Object.defineProperty(n, t, {
|
|
23
23
|
value: r,
|
|
24
24
|
writable: !1,
|
|
@@ -4,7 +4,7 @@ var t = e(20), n = class e {
|
|
|
4
4
|
constructor() {
|
|
5
5
|
this.stylePromises = /* @__PURE__ */ new Map(), this.getStyles = async ({ componentName: e, theme: n }) => {
|
|
6
6
|
if (!n || !e) return;
|
|
7
|
-
let r = `https://ds-assets.cupra.com/2.0.0-canary.
|
|
7
|
+
let r = `https://ds-assets.cupra.com/2.0.0-canary.209/styles/${n}/components/${e}.css`, i = this.getCachedStyleSheetPromise({ url: r });
|
|
8
8
|
if (i) return i;
|
|
9
9
|
let a = t(() => this.fetchStyle({ url: r })).then((e) => (e || this.stylePromises.delete(r), e));
|
|
10
10
|
return this.stylePromises.set(r, a), this.stylePromises.get(r);
|
|
@@ -6,7 +6,11 @@ export declare class DsMapPin extends UiKitElement {
|
|
|
6
6
|
static styles: import("lit").CSSResult[];
|
|
7
7
|
width: DsMapPinAttrs['width'];
|
|
8
8
|
height: DsMapPinAttrs['height'];
|
|
9
|
-
|
|
9
|
+
_checked: DsMapPinAttrs['checked'];
|
|
10
|
+
initialChecked: DsMapPinAttrs['initial-checked'];
|
|
11
|
+
private _checkedState?;
|
|
12
|
+
get checked(): boolean;
|
|
13
|
+
set checked(value: boolean | undefined);
|
|
10
14
|
iconName: DsMapPinAttrs['icon-name'];
|
|
11
15
|
iconSize: DsMapPinAttrs['icon-size'];
|
|
12
16
|
iconTop: DsMapPinAttrs['icon-top'];
|
|
@@ -7,6 +7,7 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
7
7
|
display: flex;
|
|
8
8
|
align-items: flex-start;
|
|
9
9
|
position: var(--ui-kit-banner-position, static);
|
|
10
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
10
11
|
}
|
|
11
12
|
|
|
12
13
|
.container.horizontal {
|
|
@@ -24,6 +25,15 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
24
25
|
box-sizing: border-box;
|
|
25
26
|
flex: 1 1 auto;
|
|
26
27
|
min-width: 0;
|
|
28
|
+
background-color: var(--ui-kit-banner-background-color, var(--ds-color-surface-elevated, #15181e));
|
|
29
|
+
border-radius: var(--ui-kit-banner-border-radius, var(--ds-border-radius-m, 12px));
|
|
30
|
+
box-shadow: var(
|
|
31
|
+
--ui-kit-banner-box-shadow,
|
|
32
|
+
0 var(--ds-shadow-vertical-level-02, 8px) var(--ds-shadow-blur-level-04, 32px)
|
|
33
|
+
var(--ds-shadow-spread-none, 0) var(--ds-color-shadow-level-02, #09090b99)
|
|
34
|
+
);
|
|
35
|
+
padding: var(--ds-spacing-layout-s, 16px);
|
|
36
|
+
gap: var(--ds-spacing-layout-s, 16px);
|
|
27
37
|
}
|
|
28
38
|
|
|
29
39
|
.container.horizontal .banner {
|
|
@@ -39,22 +49,33 @@ const e=require("../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_mo
|
|
|
39
49
|
flex: 1 1 auto;
|
|
40
50
|
min-width: 0;
|
|
41
51
|
flex-direction: column;
|
|
52
|
+
gap: var(--ds-spacing-m-2, 16px);
|
|
42
53
|
}
|
|
43
54
|
|
|
44
55
|
slot[name='image']::slotted(*) {
|
|
45
56
|
display: block;
|
|
57
|
+
border-radius: var(--ds-border-radius-s, 8px);
|
|
58
|
+
object-fit: cover;
|
|
46
59
|
}
|
|
47
60
|
|
|
48
61
|
slot:not([name]) {
|
|
49
62
|
display: block;
|
|
50
63
|
flex: 0 0 auto;
|
|
51
64
|
min-width: 0;
|
|
65
|
+
color: var(--ds-color-text-default, #fafafa);
|
|
66
|
+
font-family: var(--ds-typography-family-primary);
|
|
67
|
+
font-size: var(--ds-typography-size-body-l, 16px);
|
|
68
|
+
font-style: normal;
|
|
69
|
+
font-weight: var(--ds-typography-weight-body-primary, 400);
|
|
70
|
+
line-height: var(--ds-typography-height-body-l, 24px);
|
|
71
|
+
letter-spacing: var(--ds-typography-letter-spacing-m, 0.5px);
|
|
52
72
|
}
|
|
53
73
|
|
|
54
74
|
slot[name='actions'] {
|
|
55
75
|
display: flex;
|
|
56
76
|
flex-wrap: wrap;
|
|
57
77
|
flex-shrink: 0;
|
|
78
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
58
79
|
}
|
|
59
80
|
|
|
60
81
|
.container.horizontal slot[name='actions'] {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const t=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const
|
|
1
|
+
const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const t=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs"),n=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const r=require("../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.cjs"),i=require("../base/UiKitElement.cjs"),a=require("../../decorators/customUiKitElement.cjs");require("../ds-icon/ds-icon.cjs");const o=require("../../utils/booleanConverter.cjs"),s=require("../../utils/uiKitHtml.cjs"),c=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/class-map.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/class-map.cjs");const l=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/if-defined.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/if-defined.cjs");const u=require("./styles/common.styles.cjs");var d,f=(d=class extends i.UiKitElement{constructor(...e){super(...e),this.width=48,this.height=48,this._checked=void 0,this.initialChecked=!1,this.iconSize=24,this.iconTop=8}get checked(){return this._checked??this._checkedState??this.initialChecked}set checked(e){this._checked=e}get iconTemplate(){return this.iconName?s.uiKitHtml`<ds-icon class="icon" icon-name=${l.o(this.iconName)} size=${l.o(this.iconSize)}></ds-icon>`:e.E}get clusterNumberTemplate(){return this.clusterCount?e.x`
|
|
2
2
|
<div class='cluster-count'>
|
|
3
3
|
${this.clusterCount}
|
|
4
4
|
</div>
|
|
5
|
-
`:e.E}handleClick(){this.checked
|
|
5
|
+
`:e.E}handleClick(){let e=!this.checked;this._checked===void 0&&(this._checkedState=e),this.dispatchEvent(new CustomEvent(`change`,{bubbles:!0,composed:!0,detail:{checked:e}}))}get styleTokens(){return e.x`
|
|
6
6
|
<style>
|
|
7
7
|
.icon {
|
|
8
8
|
top: ${this.iconTop}px;
|
|
@@ -10,7 +10,7 @@ const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/l
|
|
|
10
10
|
</style>
|
|
11
11
|
`}get classes(){return{container:!0,checked:this.checked,cluster:!!this.clusterCount}}render(){return e.x`
|
|
12
12
|
${this.styleTokens}
|
|
13
|
-
<span data-testid="ds-map-pin-container" class=${
|
|
13
|
+
<span data-testid="ds-map-pin-container" class=${c.e(this.classes)} @click=${this.handleClick}>
|
|
14
14
|
<svg
|
|
15
15
|
class="marker"
|
|
16
16
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -28,4 +28,4 @@ const e=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/l
|
|
|
28
28
|
${this.iconTemplate}
|
|
29
29
|
${this.clusterNumberTemplate}
|
|
30
30
|
</span>
|
|
31
|
-
`}},
|
|
31
|
+
`}},d.styles=[u.mapPinStyles],d);r.__decorate([t.n({type:Number,attribute:`width`})],f.prototype,`width`,void 0),r.__decorate([t.n({type:Number,attribute:`height`})],f.prototype,`height`,void 0),r.__decorate([t.n({type:Boolean,attribute:`checked`,converter:o.booleanConverter,reflect:!0})],f.prototype,`_checked`,void 0),r.__decorate([t.n({type:Boolean,converter:o.booleanConverter,attribute:`initial-checked`})],f.prototype,`initialChecked`,void 0),r.__decorate([n.r()],f.prototype,`_checkedState`,void 0),r.__decorate([t.n({type:String,attribute:`icon-name`})],f.prototype,`iconName`,void 0),r.__decorate([t.n({type:Number,attribute:`icon-size`})],f.prototype,`iconSize`,void 0),r.__decorate([t.n({type:Number,attribute:`icon-top`})],f.prototype,`iconTop`,void 0),r.__decorate([t.n({type:Number,attribute:`cluster-count`})],f.prototype,`clusterCount`,void 0),f=r.__decorate([a.customUiKitElement(`ds-map-pin`)],f);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
const e=require("../../node_modules/.pnpm/@lit_context@1.1.6/node_modules/@lit/context/lib/decorators/provide.cjs"),t=require("./themeContext.cjs");require("../../core/theme.constants.cjs");const n=require("../../utils/PubSub.cjs"),r=require("../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.cjs"),i=require("../../node_modules/.pnpm/lit-element@4.2.1/node_modules/lit-element/lit-element.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.cjs");const a=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.cjs"),o=require("../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.cjs");require("../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.cjs");const s=require("../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.cjs"),c=require("../../decorators/customUiKitElement.cjs"),l=require("../../utils/booleanConverter.cjs"),u=require("../../styles/source/shared/fonts-config.cjs");var d=class extends i.i{constructor(...e){super(...e),this.loadFonts=!0,this.loadStyles=!0,this.loadUnusedStyles=!0,this.cssLoaded=!1,this.loadedFonts=new Set}updated(e){if(super.updated(e),e.has(`theme`)){var t,r;n.pubSub.publish(`theme`,this.theme),(t=sessionStorage)==null||t.setItem(`@cupra/ui-kit/theme`,this.theme),typeof FontFace<`u`&&(r=document)!=null&&r.fonts&&this.loadThemeFonts(),this.loadThemeStyles().then(()=>{this.cssLoaded=!0,this.dispatchEvent(new CustomEvent(`ui-kit:ready`,{bubbles:!0,composed:!0}))})}}loadThemeFonts(){var e;(e=u.fontsConfig[this.theme])==null||e.fonts.forEach(e=>{this.loadThemeFont(e)})}async loadThemeFont({weight:e,name:t,file:n}){if(!this.loadFonts)return Promise.resolve();let r=`${t}-${e}`;if(this.loadedFonts.has(r))return;let i=new FontFace(t,`url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.woff2') format('woff2'),
|
|
2
2
|
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.woff') format('woff'),
|
|
3
3
|
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.ttf') format('truetype'),
|
|
4
|
-
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.otf') format('opentype')`,{style:`normal`,weight:e,display:`optional`});try{await i.load(),document.fonts.add(i),this.loadedFonts.add(r)}catch(n){console.error(`Error loading "${t}" font with "${e}" weight:`,n)}}loadThemeStyles(){let e=`/2.0.0-canary.
|
|
4
|
+
url('https://ds-assets.cupra.com/fonts/${this.theme}/${n}.otf') format('opentype')`,{style:`normal`,weight:e,display:`optional`});try{await i.load(),document.fonts.add(i),this.loadedFonts.add(r)}catch(n){console.error(`Error loading "${t}" font with "${e}" weight:`,n)}}loadThemeStyles(){let e=`/2.0.0-canary.209`;return this.loadUnusedStyles&&this.applyUnusedStyles(e),this.loadStyles?new Promise((t,n)=>{let r=`https://ds-assets.cupra.com${e}/styles/${this.theme}/theme.css`;if(document.head.querySelector(`link[href="${r}"]`))t();else{let i=`ui-kit-theme-${e}`,a=document.getElementById(i),o=document.createElement(`link`);o.id=i,o.rel=`stylesheet`,o.href=r,o.onload=()=>t(),o.onerror=()=>n(Error(`Failed to load theme CSS: ${r}`)),document.head.appendChild(o),a==null||a.remove()}}):Promise.resolve()}applyUnusedStyles(e){let t=`https://ds-assets.cupra.com${e}/styles/${this.theme}/unused-styles.css`;if(document.head.querySelector(`link[href="${t}"]`))return;let n=`ui-kit-unused-styles-${e}`,r=document.getElementById(n),i=document.createElement(`link`);i.id=n,i.rel=`preload`,i.as=`style`,i.href=t,i.onload=()=>{i.rel=`stylesheet`},document.head.appendChild(i),r==null||r.remove()}render(){return this.cssLoaded?r.x`<slot></slot>`:r.E}};s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-fonts`})],d.prototype,`loadFonts`,void 0),s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-styles`})],d.prototype,`loadStyles`,void 0),s.__decorate([a.n({type:Boolean,converter:l.booleanConverter,attribute:`load-unused-styles`})],d.prototype,`loadUnusedStyles`,void 0),s.__decorate([e.e({context:t.themeContext}),a.n({type:String})],d.prototype,`theme`,void 0),s.__decorate([o.r()],d.prototype,`cssLoaded`,void 0),s.__decorate([o.r()],d.prototype,`loadedFonts`,void 0),d=s.__decorate([c.customUiKitElement(`ds-theme-provider`)],d);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require("../utils/version.cjs");function t(t,n){return function(r){var i,a,o,s;if(!(r!=null&&r.prototype))throw TypeError(`@customUiKitElement requires a class that extends HTMLElement.`);let c=`${t}${e.VERSION_TAG_SUFFIX}`;if(!((i=globalThis)==null||(i=i.customElements)==null)&&i.get(c))return;let l=n!=null&&n.skipTagAsComponentName?[]:[t];Array.isArray(n==null?void 0:n.extendComponentNames)&&(l=[...n.extendComponentNames,...l]),(a=globalThis)==null||(a=a.customElements)==null||(o=a.define)==null||o.call(a,c,(s=class extends r{connectedCallback(){var e;(e=r.prototype.connectedCallback)==null||e.call(this),this.setAttribute(`data-ui-kit-version`,`2.0.0-canary.
|
|
1
|
+
const e=require("../utils/version.cjs");function t(t,n){return function(r){var i,a,o,s;if(!(r!=null&&r.prototype))throw TypeError(`@customUiKitElement requires a class that extends HTMLElement.`);let c=`${t}${e.VERSION_TAG_SUFFIX}`;if(!((i=globalThis)==null||(i=i.customElements)==null)&&i.get(c))return;let l=n!=null&&n.skipTagAsComponentName?[]:[t];Array.isArray(n==null?void 0:n.extendComponentNames)&&(l=[...n.extendComponentNames,...l]),(a=globalThis)==null||(a=a.customElements)==null||(o=a.define)==null||o.call(a,c,(s=class extends r{connectedCallback(){var e;(e=r.prototype.connectedCallback)==null||e.call(this),this.setAttribute(`data-ui-kit-version`,`2.0.0-canary.209`),this.setAttribute(`data-ui-kit-component-name`,t)}},s.componentName=l,s))}}exports.customUiKitElement=t;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require("../core/theme.constants.cjs"),t=require("./PubSub.cjs");var n=class{constructor(){this.icons={},this.handleChangeTheme=e=>{if(this.theme===e)return;this.theme=e;let t=Object.keys(this.icons);this.icons={},t.forEach(e=>this.fetchIcon(e))},this.fetchIcon=async(t,n={})=>{var r;let i=typeof sessionStorage<`u`?(r=sessionStorage)==null?void 0:r.getItem(e.THEME_STORAGE_KEY):null;!this.theme&&i&&(this.theme=i);let a=this.icons[t];if(a)return await a;let o=this.loadIcon(t,n).catch(e=>{throw delete this.icons[t],e});return this.icons[t]=o,o},this.loadIcon=(e,{cache:t=`force-cache`,...n})=>!this.theme||typeof fetch>`u`?Promise.resolve(`<svg class="ds-icon"></svg>`):fetch(`https://ds-assets.cupra.com/icons/${this.theme}/${e}.svg`,{cache:t,...n}).then(e=>e.text()).catch(t=>{if((t==null?void 0:t.name)===`AbortError`)throw t;return console.error(`Failed to fetch icon "${e}":`,t),``}),t.pubSub.subscribe(`theme`,this.handleChangeTheme)}},r=Symbol.for(`@cupra/ui-kit/icons-manager/2.0.0-canary.
|
|
1
|
+
const e=require("../core/theme.constants.cjs"),t=require("./PubSub.cjs");var n=class{constructor(){this.icons={},this.handleChangeTheme=e=>{if(this.theme===e)return;this.theme=e;let t=Object.keys(this.icons);this.icons={},t.forEach(e=>this.fetchIcon(e))},this.fetchIcon=async(t,n={})=>{var r;let i=typeof sessionStorage<`u`?(r=sessionStorage)==null?void 0:r.getItem(e.THEME_STORAGE_KEY):null;!this.theme&&i&&(this.theme=i);let a=this.icons[t];if(a)return await a;let o=this.loadIcon(t,n).catch(e=>{throw delete this.icons[t],e});return this.icons[t]=o,o},this.loadIcon=(e,{cache:t=`force-cache`,...n})=>!this.theme||typeof fetch>`u`?Promise.resolve(`<svg class="ds-icon"></svg>`):fetch(`https://ds-assets.cupra.com/icons/${this.theme}/${e}.svg`,{cache:t,...n}).then(e=>e.text()).catch(t=>{if((t==null?void 0:t.name)===`AbortError`)throw t;return console.error(`Failed to fetch icon "${e}":`,t),``}),t.pubSub.subscribe(`theme`,this.handleChangeTheme)}},r=Symbol.for(`@cupra/ui-kit/icons-manager/2.0.0-canary.209`),i=globalThis,a=i[r];a||(a=new n,Object.defineProperty(i,r,{value:a,writable:!1,configurable:!1,enumerable:!1}));var o=a;exports.iconsManager=o;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=class{constructor(){this.subscribers={},this.lastPublishedData={}}subscribe(e,t){return this.subscribers[e]||(this.subscribers[e]=[]),this.subscribers[e].push(t),this.lastPublishedData[e]}unsubscribe(e,t){this.subscribers[e]&&(this.subscribers[e]=this.subscribers[e].filter(e=>e!==t))}publish(e,t){this.lastPublishedData[e]=t,this.subscribers[e]&&this.subscribers[e].forEach(n=>{try{n(t)}catch(t){console.error(`Error in subscriber for event "${e}":`,t)}})}},t=Symbol.for(`@cupra/ui-kit/pubsub/2.0.0-canary.
|
|
1
|
+
var e=class{constructor(){this.subscribers={},this.lastPublishedData={}}subscribe(e,t){return this.subscribers[e]||(this.subscribers[e]=[]),this.subscribers[e].push(t),this.lastPublishedData[e]}unsubscribe(e,t){this.subscribers[e]&&(this.subscribers[e]=this.subscribers[e].filter(e=>e!==t))}publish(e,t){this.lastPublishedData[e]=t,this.subscribers[e]&&this.subscribers[e].forEach(n=>{try{n(t)}catch(t){console.error(`Error in subscriber for event "${e}":`,t)}})}},t=Symbol.for(`@cupra/ui-kit/pubsub/2.0.0-canary.209`),n=globalThis,r=n[t];r||(r=new e,Object.defineProperty(n,t,{value:r,writable:!1,configurable:!1,enumerable:!1}));var i=r;exports.pubSub=i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=require("../concurrencyLimit.cjs").concurrencyLimit(20),t=class t{constructor(){this.stylePromises=new Map,this.getStyles=async({componentName:t,theme:n})=>{if(!n||!t)return;let r=`https://ds-assets.cupra.com/2.0.0-canary.
|
|
1
|
+
var e=require("../concurrencyLimit.cjs").concurrencyLimit(20),t=class t{constructor(){this.stylePromises=new Map,this.getStyles=async({componentName:t,theme:n})=>{if(!n||!t)return;let r=`https://ds-assets.cupra.com/2.0.0-canary.209/styles/${n}/components/${t}.css`,i=this.getCachedStyleSheetPromise({url:r});if(i)return i;let a=e(()=>this.fetchStyle({url:r})).then(e=>(e||this.stylePromises.delete(r),e));return this.stylePromises.set(r,a),this.stylePromises.get(r)}}async fetchStyle({url:e}){try{if(typeof fetch>`u`)return;let t=await fetch(e,{cache:`force-cache`});if(t.ok)return t.text()}catch(t){console.error(`Failed to fetch Style Sheet "${e}":`,t)}}getCachedStyleSheetPromise({url:e}){return this.stylePromises.get(e)}static getInstance(){return t.instance||(t.instance=new t),t.instance}}.getInstance();exports.stylesRegistry=t;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`2.0.0-canary.
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`2.0.0-canary.209`,t=`--v${e.replaceAll(`.`,`-`)}`;exports.VERSION=e,exports.VERSION_TAG_SUFFIX=t;
|
|
@@ -10,6 +10,7 @@ var t = e`
|
|
|
10
10
|
display: flex;
|
|
11
11
|
align-items: flex-start;
|
|
12
12
|
position: var(--ui-kit-banner-position, static);
|
|
13
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
.container.horizontal {
|
|
@@ -27,6 +28,15 @@ var t = e`
|
|
|
27
28
|
box-sizing: border-box;
|
|
28
29
|
flex: 1 1 auto;
|
|
29
30
|
min-width: 0;
|
|
31
|
+
background-color: var(--ui-kit-banner-background-color, var(--ds-color-surface-elevated, #15181e));
|
|
32
|
+
border-radius: var(--ui-kit-banner-border-radius, var(--ds-border-radius-m, 12px));
|
|
33
|
+
box-shadow: var(
|
|
34
|
+
--ui-kit-banner-box-shadow,
|
|
35
|
+
0 var(--ds-shadow-vertical-level-02, 8px) var(--ds-shadow-blur-level-04, 32px)
|
|
36
|
+
var(--ds-shadow-spread-none, 0) var(--ds-color-shadow-level-02, #09090b99)
|
|
37
|
+
);
|
|
38
|
+
padding: var(--ds-spacing-layout-s, 16px);
|
|
39
|
+
gap: var(--ds-spacing-layout-s, 16px);
|
|
30
40
|
}
|
|
31
41
|
|
|
32
42
|
.container.horizontal .banner {
|
|
@@ -42,22 +52,33 @@ var t = e`
|
|
|
42
52
|
flex: 1 1 auto;
|
|
43
53
|
min-width: 0;
|
|
44
54
|
flex-direction: column;
|
|
55
|
+
gap: var(--ds-spacing-m-2, 16px);
|
|
45
56
|
}
|
|
46
57
|
|
|
47
58
|
slot[name='image']::slotted(*) {
|
|
48
59
|
display: block;
|
|
60
|
+
border-radius: var(--ds-border-radius-s, 8px);
|
|
61
|
+
object-fit: cover;
|
|
49
62
|
}
|
|
50
63
|
|
|
51
64
|
slot:not([name]) {
|
|
52
65
|
display: block;
|
|
53
66
|
flex: 0 0 auto;
|
|
54
67
|
min-width: 0;
|
|
68
|
+
color: var(--ds-color-text-default, #fafafa);
|
|
69
|
+
font-family: var(--ds-typography-family-primary);
|
|
70
|
+
font-size: var(--ds-typography-size-body-l, 16px);
|
|
71
|
+
font-style: normal;
|
|
72
|
+
font-weight: var(--ds-typography-weight-body-primary, 400);
|
|
73
|
+
line-height: var(--ds-typography-height-body-l, 24px);
|
|
74
|
+
letter-spacing: var(--ds-typography-letter-spacing-m, 0.5px);
|
|
55
75
|
}
|
|
56
76
|
|
|
57
77
|
slot[name='actions'] {
|
|
58
78
|
display: flex;
|
|
59
79
|
flex-wrap: wrap;
|
|
60
80
|
flex-shrink: 0;
|
|
81
|
+
gap: var(--ds-spacing-s-5, 8px);
|
|
61
82
|
}
|
|
62
83
|
|
|
63
84
|
.container.horizontal slot[name='actions'] {
|
|
@@ -1,25 +1,32 @@
|
|
|
1
1
|
import { E as e, x as t } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.js";
|
|
2
2
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/index.js";
|
|
3
3
|
import { n } from "../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.js";
|
|
4
|
+
import { r } from "../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.js";
|
|
4
5
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/decorators.js";
|
|
5
|
-
import { __decorate as
|
|
6
|
-
import { UiKitElement as
|
|
7
|
-
import { customUiKitElement as
|
|
6
|
+
import { __decorate as i } from "../../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/decorate.js";
|
|
7
|
+
import { UiKitElement as a } from "../base/UiKitElement.js";
|
|
8
|
+
import { customUiKitElement as o } from "../../decorators/customUiKitElement.js";
|
|
8
9
|
import "../ds-icon/ds-icon.js";
|
|
9
|
-
import { booleanConverter as
|
|
10
|
-
import { uiKitHtml as
|
|
11
|
-
import { e as
|
|
10
|
+
import { booleanConverter as s } from "../../utils/booleanConverter.js";
|
|
11
|
+
import { uiKitHtml as c } from "../../utils/uiKitHtml.js";
|
|
12
|
+
import { e as l } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/class-map.js";
|
|
12
13
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/class-map.js";
|
|
13
|
-
import { o as
|
|
14
|
+
import { o as u } from "../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/directives/if-defined.js";
|
|
14
15
|
import "../../node_modules/.pnpm/lit@3.3.1/node_modules/lit/directives/if-defined.js";
|
|
15
|
-
import { mapPinStyles as
|
|
16
|
+
import { mapPinStyles as d } from "./styles/common.styles.js";
|
|
16
17
|
//#region src/components/ds-map-pin/ds-map-pin.ts
|
|
17
|
-
var
|
|
18
|
+
var f, p = (f = class extends a {
|
|
18
19
|
constructor(...e) {
|
|
19
|
-
super(...e), this.width = 48, this.height = 48, this.
|
|
20
|
+
super(...e), this.width = 48, this.height = 48, this._checked = void 0, this.initialChecked = !1, this.iconSize = 24, this.iconTop = 8;
|
|
21
|
+
}
|
|
22
|
+
get checked() {
|
|
23
|
+
return this._checked ?? this._checkedState ?? this.initialChecked;
|
|
24
|
+
}
|
|
25
|
+
set checked(e) {
|
|
26
|
+
this._checked = e;
|
|
20
27
|
}
|
|
21
28
|
get iconTemplate() {
|
|
22
|
-
return this.iconName ?
|
|
29
|
+
return this.iconName ? c`<ds-icon class="icon" icon-name=${u(this.iconName)} size=${u(this.iconSize)}></ds-icon>` : e;
|
|
23
30
|
}
|
|
24
31
|
get clusterNumberTemplate() {
|
|
25
32
|
return this.clusterCount ? t`
|
|
@@ -29,10 +36,11 @@ var d, f = (d = class extends i {
|
|
|
29
36
|
` : e;
|
|
30
37
|
}
|
|
31
38
|
handleClick() {
|
|
32
|
-
|
|
39
|
+
let e = !this.checked;
|
|
40
|
+
this._checked === void 0 && (this._checkedState = e), this.dispatchEvent(new CustomEvent("change", {
|
|
33
41
|
bubbles: !0,
|
|
34
42
|
composed: !0,
|
|
35
|
-
detail: { checked:
|
|
43
|
+
detail: { checked: e }
|
|
36
44
|
}));
|
|
37
45
|
}
|
|
38
46
|
get styleTokens() {
|
|
@@ -54,7 +62,7 @@ var d, f = (d = class extends i {
|
|
|
54
62
|
render() {
|
|
55
63
|
return t`
|
|
56
64
|
${this.styleTokens}
|
|
57
|
-
<span data-testid="ds-map-pin-container" class=${
|
|
65
|
+
<span data-testid="ds-map-pin-container" class=${l(this.classes)} @click=${this.handleClick}>
|
|
58
66
|
<svg
|
|
59
67
|
class="marker"
|
|
60
68
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -74,28 +82,33 @@ var d, f = (d = class extends i {
|
|
|
74
82
|
</span>
|
|
75
83
|
`;
|
|
76
84
|
}
|
|
77
|
-
},
|
|
78
|
-
|
|
85
|
+
}, f.styles = [d], f);
|
|
86
|
+
i([n({
|
|
79
87
|
type: Number,
|
|
80
88
|
attribute: "width"
|
|
81
|
-
})],
|
|
89
|
+
})], p.prototype, "width", void 0), i([n({
|
|
82
90
|
type: Number,
|
|
83
91
|
attribute: "height"
|
|
84
|
-
})],
|
|
92
|
+
})], p.prototype, "height", void 0), i([n({
|
|
85
93
|
type: Boolean,
|
|
86
|
-
|
|
94
|
+
attribute: "checked",
|
|
95
|
+
converter: s,
|
|
87
96
|
reflect: !0
|
|
88
|
-
})],
|
|
97
|
+
})], p.prototype, "_checked", void 0), i([n({
|
|
98
|
+
type: Boolean,
|
|
99
|
+
converter: s,
|
|
100
|
+
attribute: "initial-checked"
|
|
101
|
+
})], p.prototype, "initialChecked", void 0), i([r()], p.prototype, "_checkedState", void 0), i([n({
|
|
89
102
|
type: String,
|
|
90
103
|
attribute: "icon-name"
|
|
91
|
-
})],
|
|
104
|
+
})], p.prototype, "iconName", void 0), i([n({
|
|
92
105
|
type: Number,
|
|
93
106
|
attribute: "icon-size"
|
|
94
|
-
})],
|
|
107
|
+
})], p.prototype, "iconSize", void 0), i([n({
|
|
95
108
|
type: Number,
|
|
96
109
|
attribute: "icon-top"
|
|
97
|
-
})],
|
|
110
|
+
})], p.prototype, "iconTop", void 0), i([n({
|
|
98
111
|
type: Number,
|
|
99
112
|
attribute: "cluster-count"
|
|
100
|
-
})],
|
|
113
|
+
})], p.prototype, "clusterCount", void 0), p = i([o("ds-map-pin")], p);
|
|
101
114
|
//#endregion
|
|
@@ -53,7 +53,7 @@ var f = class extends a {
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
loadThemeStyles() {
|
|
56
|
-
let e = "/2.0.0-canary.
|
|
56
|
+
let e = "/2.0.0-canary.209";
|
|
57
57
|
return this.loadUnusedStyles && this.applyUnusedStyles(e), this.loadStyles ? new Promise((t, n) => {
|
|
58
58
|
let r = `https://ds-assets.cupra.com${e}/styles/${this.theme}/theme.css`;
|
|
59
59
|
if (document.head.querySelector(`link[href="${r}"]`)) t();
|
|
@@ -10,7 +10,7 @@ function t(t, n) {
|
|
|
10
10
|
Array.isArray(n == null ? void 0 : n.extendComponentNames) && (l = [...n.extendComponentNames, ...l]), (a = globalThis) == null || (a = a.customElements) == null || (o = a.define) == null || o.call(a, c, (s = class extends r {
|
|
11
11
|
connectedCallback() {
|
|
12
12
|
var e;
|
|
13
|
-
(e = r.prototype.connectedCallback) == null || e.call(this), this.setAttribute("data-ui-kit-version", "2.0.0-canary.
|
|
13
|
+
(e = r.prototype.connectedCallback) == null || e.call(this), this.setAttribute("data-ui-kit-version", "2.0.0-canary.209"), this.setAttribute("data-ui-kit-component-name", t);
|
|
14
14
|
}
|
|
15
15
|
}, s.componentName = l, s));
|
|
16
16
|
};
|
|
@@ -26,7 +26,7 @@ var n = class {
|
|
|
26
26
|
return console.error(`Failed to fetch icon "${e}":`, t), "";
|
|
27
27
|
}), t.subscribe("theme", this.handleChangeTheme);
|
|
28
28
|
}
|
|
29
|
-
}, r = Symbol.for("@cupra/ui-kit/icons-manager/2.0.0-canary.
|
|
29
|
+
}, r = Symbol.for("@cupra/ui-kit/icons-manager/2.0.0-canary.209"), i = globalThis, a = i[r];
|
|
30
30
|
a || (a = new n(), Object.defineProperty(i, r, {
|
|
31
31
|
value: a,
|
|
32
32
|
writable: !1,
|
|
@@ -18,7 +18,7 @@ var e = class {
|
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
|
-
}, t = Symbol.for("@cupra/ui-kit/pubsub/2.0.0-canary.
|
|
21
|
+
}, t = Symbol.for("@cupra/ui-kit/pubsub/2.0.0-canary.209"), n = globalThis, r = n[t];
|
|
22
22
|
r || (r = new e(), Object.defineProperty(n, t, {
|
|
23
23
|
value: r,
|
|
24
24
|
writable: !1,
|
|
@@ -4,7 +4,7 @@ var t = e(20), n = class e {
|
|
|
4
4
|
constructor() {
|
|
5
5
|
this.stylePromises = /* @__PURE__ */ new Map(), this.getStyles = async ({ componentName: e, theme: n }) => {
|
|
6
6
|
if (!n || !e) return;
|
|
7
|
-
let r = `https://ds-assets.cupra.com/2.0.0-canary.
|
|
7
|
+
let r = `https://ds-assets.cupra.com/2.0.0-canary.209/styles/${n}/components/${e}.css`, i = this.getCachedStyleSheetPromise({ url: r });
|
|
8
8
|
if (i) return i;
|
|
9
9
|
let a = t(() => this.fetchStyle({ url: r })).then((e) => (e || this.stylePromises.delete(r), e));
|
|
10
10
|
return this.stylePromises.set(r, a), this.stylePromises.get(r);
|
|
@@ -6,7 +6,11 @@ export declare class DsMapPin extends UiKitElement {
|
|
|
6
6
|
static styles: import("lit").CSSResult[];
|
|
7
7
|
width: DsMapPinAttrs['width'];
|
|
8
8
|
height: DsMapPinAttrs['height'];
|
|
9
|
-
|
|
9
|
+
_checked: DsMapPinAttrs['checked'];
|
|
10
|
+
initialChecked: DsMapPinAttrs['initial-checked'];
|
|
11
|
+
private _checkedState?;
|
|
12
|
+
get checked(): boolean;
|
|
13
|
+
set checked(value: boolean | undefined);
|
|
10
14
|
iconName: DsMapPinAttrs['icon-name'];
|
|
11
15
|
iconSize: DsMapPinAttrs['icon-size'];
|
|
12
16
|
iconTop: DsMapPinAttrs['icon-top'];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cupra/ui-kit",
|
|
3
|
-
"version": "2.0.0-canary.
|
|
3
|
+
"version": "2.0.0-canary.209",
|
|
4
4
|
"description": "Web components library",
|
|
5
5
|
"author": "SEAT S.A.",
|
|
6
6
|
"license": "SEAT S.A. Library EULA 1.0",
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
"lottie-web": "^5.13.0",
|
|
120
120
|
"nodemon": "^3.1.14",
|
|
121
121
|
"playwright": "1.56.1",
|
|
122
|
-
"postcss": "^8.5.
|
|
122
|
+
"postcss": "^8.5.23",
|
|
123
123
|
"postcss-cli": "^11.0.1",
|
|
124
124
|
"postcss-custom-media": "^11.0.6",
|
|
125
125
|
"postcss-import": "^16.1.0",
|