scb-wc-test 0.1.120 → 0.1.121

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,6 @@
1
- import{a as p,n as d,i as c,x as f,t as _}from"../../vendor/vendor.js";(function(){try{var a=typeof globalThis<"u"?globalThis:window;if(!a.__scb_ce_guard_installed__){a.__scb_ce_guard_installed__=!0;var r=customElements.define.bind(customElements);customElements.define=function(e,i,t){try{customElements.get(e)||r(e,i,t)}catch(n){var s=String(n||"");if(s.indexOf("already been used")===-1&&s.indexOf("NotSupportedError")===-1)throw n}}}}catch{}})();var u=Object.defineProperty,h=Object.getOwnPropertyDescriptor,l=(a,r,e,i)=>{for(var t=i>1?void 0:i?h(r,e):r,s=a.length-1,n;s>=0;s--)(n=a[s])&&(t=(i?n(r,e,t):n(t))||t);return i&&t&&u(r,e,t),t};let o=class extends c{constructor(){super(...arguments),this.title="",this.date="",this.description=""}render(){return f`
2
- <div>
3
- <h3>${this.title}</h3>
4
- <p>${this.date}</p>
5
- <p>${this.description}</p>
6
- </div>
7
- `}};o.styles=p`
1
+ import{a as p,n as l,i as u,x as c,t as _}from"../../vendor/vendor.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var i=customElements.define.bind(customElements);customElements.define=function(r,n,e){try{customElements.get(r)||i(r,n,e)}catch(o){var a=String(o||"");if(a.indexOf("already been used")===-1&&a.indexOf("NotSupportedError")===-1)throw o}}}}catch{}})();var f=Object.defineProperty,b=Object.getOwnPropertyDescriptor,d=(t,i,r,n)=>{for(var e=n>1?void 0:n?b(i,r):i,a=t.length-1,o;a>=0;a--)(o=t[a])&&(e=(n?o(i,r,e):o(e))||e);return n&&e&&f(i,r,e),e};let s=class extends u{constructor(){super(...arguments),this.title="",this.description="",this.startDate="",this.endDate=""}updated(t){super.updated?.(t),(t.has("title")||t.has("description")||t.has("startDate")||t.has("endDate"))&&this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))}render(){return c`
2
+ `}};s.styles=p`
8
3
  :host {
9
4
  display: block;
10
- font-family: var(--brand-font, Arial, sans-serif)
11
5
  }
12
- `;l([d({type:String})],o.prototype,"title",2);l([d({type:String})],o.prototype,"date",2);l([d({type:String})],o.prototype,"description",2);o=l([_("scb-calendar-event")],o);
6
+ `;d([l({type:String})],s.prototype,"title",2);d([l({type:String})],s.prototype,"description",2);d([l({type:String,attribute:"start-date"})],s.prototype,"startDate",2);d([l({type:String,attribute:"end-date"})],s.prototype,"endDate",2);s=d([_("scb-calendar-event")],s);
@@ -1,67 +1,70 @@
1
- import{a as x,n as m,i as w,x as d,t as $}from"../../vendor/vendor.js";import"./scb-calendar-event.js";import"../scb-icon-button/scb-icon-button.js";import"../../vendor/preload-helper.js";import"../../vendor/vendor-material.js";(function(){try{var t=typeof globalThis<"u"?globalThis:window;if(!t.__scb_ce_guard_installed__){t.__scb_ce_guard_installed__=!0;var e=customElements.define.bind(customElements);customElements.define=function(n,s,a){try{customElements.get(n)||e(n,s,a)}catch(i){var l=String(i||"");if(l.indexOf("already been used")===-1&&l.indexOf("NotSupportedError")===-1)throw i}}}}catch{}})();var M=Object.defineProperty,D=Object.getOwnPropertyDescriptor,g=(t,e,n,s)=>{for(var a=s>1?void 0:s?D(e,n):e,l=t.length-1,i;l>=0;l--)(i=t[l])&&(a=(s?i(e,n,a):i(a))||a);return s&&a&&M(e,n,a),a};let v=class extends w{constructor(){super(...arguments),this.label="",this.value="",this._today=new Date,this._current=new Date,this._popupEvent=null}_daysInMonth(t,e){return new Date(t,e+1,0).getDate()}_firstDayOfWeek(t,e){return new Date(t,e,1).getDay()}_prevMonth(){this._current=new Date(this._current.getFullYear(),this._current.getMonth()-1,1),this.requestUpdate()}_nextMonth(){this._current=new Date(this._current.getFullYear(),this._current.getMonth()+1,1),this.requestUpdate()}_showEventPopup(t){this._popupEvent=t,this.requestUpdate(),setTimeout(()=>{const e=n=>{n.target?.closest(".event-popup")||this._closePopup()};window.addEventListener("mousedown",e,{once:!0})},0)}_closePopup(){this._popupEvent=null,this.requestUpdate()}render(){const t=this._current.getFullYear(),e=this._current.getMonth(),n=this._daysInMonth(t,e),s=this._firstDayOfWeek(t,e),a=this._today,l=Array.from(this.querySelectorAll("scb-calendar-event")),i=new Map;for(const r of l)if(r.date&&r.title){const p=i.get(r.date)||[];p.push({title:r.title,description:r.description}),i.set(r.date,p)}const f=[];let c=1;for(let r=0;r<6;r++){const p=[];for(let h=0;h<7;h++)if(r===0&&h<s){const b=e===0?11:e-1,y=e===0?t-1:t,u=this._daysInMonth(y,b)-(s-h-1);p.push(d`
1
+ import{a as S,n as k,i as O,x as m,t as C}from"../../vendor/vendor.js";import"./scb-calendar-event.js";import"../scb-icon-button/scb-icon-button.js";import"../scb-dialog/scb-dialog.js";import"../scb-list/scb-list.js";import"../../vendor/vendor-material.js";import"../../vendor/preload-helper.js";import"../scb-button/scb-button.js";import"../scb-textfield/scb-textfield.js";import"../scb-datepicker/scb-datepicker.js";import"../scb-divider/scb-divider.js";import"../scb-checkbox/scb-checkbox.js";import"../scb-checkbox/scb-checkbox-group.js";import"../scb-radio-button/scb-radio-button.js";import"../scb-radio-button/scb-radio-group.js";import"../scb-switch/scb-switch.js";import"../scb-chip/scb-chip.js";import"../scb-list/scb-list-item.js";(function(){try{var i=typeof globalThis<"u"?globalThis:window;if(!i.__scb_ce_guard_installed__){i.__scb_ce_guard_installed__=!0;var a=customElements.define.bind(customElements);customElements.define=function(c,h,u){try{customElements.get(c)||a(c,h,u)}catch(b){var o=String(b||"");if(o.indexOf("already been used")===-1&&o.indexOf("NotSupportedError")===-1)throw b}}}}catch{}})();var A=Object.defineProperty,P=Object.getOwnPropertyDescriptor,x=(i,a,c,h)=>{for(var u=h>1?void 0:h?P(a,c):a,o=i.length-1,b;o>=0;o--)(b=i[o])&&(u=(h?b(a,c,u):b(u))||u);return h&&u&&A(a,c,u),u};let w=class extends O{constructor(){super(...arguments),this.lang="sv",this._mutationObserver=null,this._onEventChanged=()=>{this.requestUpdate()},this._today=new Date,this._current=new Date,this._popupEvent=null}connectedCallback(){super.connectedCallback(),this.addEventListener("change",this._onEventChanged),this._mutationObserver=new MutationObserver(()=>{this.requestUpdate()}),this._mutationObserver.observe(this,{childList:!0})}disconnectedCallback(){this.removeEventListener("change",this._onEventChanged),super.disconnectedCallback(),this._mutationObserver&&(this._mutationObserver.disconnect(),this._mutationObserver=null)}_daysInMonth(i,a){return new Date(i,a+1,0).getDate()}_firstDayOfWeek(i,a){const c=new Date(i,a,1).getDay();return c===0?6:c-1}_prevMonth(){this._current=new Date(this._current.getFullYear(),this._current.getMonth()-1,1),this.requestUpdate()}_nextMonth(){this._current=new Date(this._current.getFullYear(),this._current.getMonth()+1,1),this.requestUpdate()}_showEventPopup(i){this._popupEvent=i,this.requestUpdate(),setTimeout(()=>{const a=this.shadowRoot?.querySelector("scb-dialog");a&&a.setAttribute("open","");const c=h=>{h.target?.closest(".event-popup")||this._closePopup()};window.addEventListener("mousedown",c,{once:!0})},0)}_closePopup(){const i=this.shadowRoot?.querySelector("scb-dialog");i&&i.removeAttribute("open"),this._popupEvent=null,this.requestUpdate()}render(){const i=this._current.getFullYear(),a=this._current.getMonth(),c=this._daysInMonth(i,a),h=this._firstDayOfWeek(i,a),u=this._today,o=this.lang==="en",b=o?["January","February","March","April","May","June","July","August","September","October","November","December"]:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],E=o?["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]:["Mån","Tis","Ons","Tor","Fre","Lör","Sön"],M=Array.from(this.querySelectorAll("scb-calendar-event")),_=new Map;for(const t of M){const r=t.getAttribute("start-date")||"",l=t.getAttribute("end-date")||"";if(r&&l){const d=new Date(r),n=new Date(l);for(let s=new Date(d);s<=n;s.setDate(s.getDate()+1)){const g=s.toISOString().split("T")[0],e=_.get(g)||[];e.push({title:t.title,description:t.description,start:r,end:l}),_.set(g,e)}}else if(r&&t.title){const d=r.split("T")[0],n=_.get(d)||[];n.push({title:t.title,description:t.description,start:r}),_.set(d,n)}}const $=[];let y=1;for(let t=0;t<6;t++){const r=[];for(let l=0;l<7;l++)if(t===0&&l<h){const d=a===0?11:a-1,n=a===0?i-1:i,g=this._daysInMonth(n,d)-(h-l-1);r.push(m`
2
2
  <div class="calendar-day calendar-day--other">
3
- <span class="calendar-day-number">${u}</span>
3
+ <span class="calendar-day-number">${g}</span>
4
4
  </div>
5
- `)}else if(c>n)p.push(d`<div></div>`);else{const b=a.getFullYear()===t&&a.getMonth()===e&&a.getDate()===c,y=`${t}-${String(e+1).padStart(2,"0")}-${String(c).padStart(2,"0")}`,o=i.get(y)||[];p.push(d`
5
+ `)}else if(y>c)r.push(m`<div></div>`);else{const d=u.getFullYear()===i&&u.getMonth()===a&&u.getDate()===y,n=`${i}-${String(a+1).padStart(2,"0")}-${String(y).padStart(2,"0")}`;let s=_.get(n)||[];s=[...s].sort((e,p)=>{const f=e.start&&n===e.start.split("T")[0]?e.start:e.end&&n===e.end.split("T")[0]?e.end:"",v=p.start&&n===p.start.split("T")[0]?p.start:p.end&&n===p.end.split("T")[0]?p.end:"",T=f&&f.includes("T"),D=v&&v.includes("T");return T&&D?f.localeCompare(v):T?-1:D?1:e.title.localeCompare(p.title)});const g=[...s].map(e=>{let p="",f="";if(e.start&&e.end){const v=e.start.split("T")[0],T=e.end.split("T")[0];n===v&&n===T&&e.start.includes("T")&&e.end.includes("T")?p=e.start.split("T")[1].substring(0,5)+"–"+e.end.split("T")[1].substring(0,5):n===v&&e.start.includes("T")?p=e.start.split("T")[1].substring(0,5):n===T&&e.end.includes("T")?(p=e.end.split("T")[1].substring(0,5),f=o?"cont. ":"fort. "):n!==v&&(p="",f=o?"cont. ":"fort. ")}else e.start&&e.start.includes("T")&&(p=e.start.split("T")[1].substring(0,5));return{...e,time:p,prefix:f}});r.push(m`
6
6
  <div
7
- class="calendar-day${b?" today":""}${o.length?" has-event":""}"
8
- @click=${o.length?()=>this._showEventPopup({date:y,events:o}):null}
9
- title=${o.length===1?o[0].title:o.length>1?o.map(u=>u.title).join(", "):""}
7
+ class="calendar-day${d?" today":""}${s.length?" has-event":""}"
8
+ ?tabindex=${s.length?0:void 0}
9
+ @click=${s.length?()=>this._showEventPopup({date:n,events:s}):null}
10
+ tabindex=${s.length?"0":void 0}
11
+ @keydown=${s.length?e=>{(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this._showEventPopup({date:n,events:s}))}:null}
12
+ title=${s.length===1?s[0].title:s.length>1?s.map(e=>e.title).join(", "):""}
13
+ role=${s.length?"button":void 0}
14
+ aria-label=${s.length?s.length===1?s[0].title:s.map(e=>e.title).join(", "):void 0}
10
15
  >
11
- <span class="calendar-day-number">${c}</span>
16
+ <md-focus-ring inward></md-focus-ring>
17
+ <span class="calendar-day-number">${y}</span>
12
18
  <div class="calendar-titles-wrapper">
13
- ${o.map(u=>d`<span class="calendar-day-event-title">${u.title}</span>`)}
19
+ ${g.map(e=>m`<span class="calendar-day-event-title">${e.prefix||""}${e.title}</span>`)}
14
20
  </div>
15
21
  </div>
16
- `),c++}if(f.push(d`<div class="calendar-grid">${p}</div>`),c>n)break}const _=["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"];return d`
22
+ `),y++}if($.push(m`<div class="calendar-grid">${r}</div>`),y>c)break}return m`
17
23
  <div class="calendar-header">
18
- <scb-icon-button @click=${this._prevMonth} icon="chevron_left" aria-label="Föregående månad"></scb-icon-button>
19
- <span>${_[e]} ${t}</span>
20
- <scb-icon-button @click=${this._nextMonth} icon="chevron_right" aria-label="Nästa månad"></scb-icon-button>
24
+ <scb-icon-button @click=${this._prevMonth} icon="chevron_left" aria-label="${o?"Previous month":"Föregående månad"}"></scb-icon-button>
25
+ <span>${b[a]} ${i}</span>
26
+ <scb-icon-button @click=${this._nextMonth} icon="chevron_right" aria-label="${o?"Next month":"Nästa månad"}"></scb-icon-button>
21
27
  </div>
22
28
  <div class="calendar-grid calendar-grid-days">
23
- <div>Mån</div><div>Tis</div><div>Ons</div><div>Tor</div><div>Fre</div><div>Lör</div><div>Sön</div>
29
+ ${E.map(t=>m`<div>${t}</div>`)}
24
30
  </div>
25
31
  <div class="calendar-weeks">
26
- ${f}
27
- <div>
28
- ${this._popupEvent&&Array.isArray(this._popupEvent.events)?d`
29
- <div class="event-popup-backdrop" @click=${this._closePopup}></div>
30
- <div class="event-popup">
31
- <button class="close-btn" @click=${this._closePopup} title="Stäng">×</button>
32
- <div>${this._popupEvent.date}</div>
33
- <ul>
34
- ${this._popupEvent.events.map(r=>d`<li><strong>${r.title}</strong>${r.description?d`<div>${r.description}</div>`:""}</li>`)}
35
- </ul>
36
- </div>
32
+ ${$}
33
+ </div>
34
+ ${this._popupEvent&&Array.isArray(this._popupEvent.events)?m`
35
+ <scb-dialog variant="floating" open label="${o?"Events":"Händelser"} ${this._popupEvent.date}">
36
+ <scb-list>
37
+ ${[...this._popupEvent.events].sort((t,r)=>{const l=t.start&&t.start.includes("T")?t.start:t.end&&t.end.includes("T")?t.end:"",d=r.start&&r.start.includes("T")?r.start:r.end&&r.end.includes("T")?r.end:"",n=l&&l.includes("T"),s=d&&d.includes("T");return n&&s?l.localeCompare(d):n?-1:s?1:t.title.localeCompare(r.title)}).map(t=>{const r=this._popupEvent?.date??"";let l="",d="",n="";if(t.start&&t.end){const s=t.start.split("T")[0],g=t.end.split("T")[0];s===g&&t.start.includes("T")&&t.end.includes("T")?l=t.start.split("T")[1].substring(0,5)+" – "+t.end.split("T")[1].substring(0,5):r===s&&t.start.includes("T")&&(l="Start: "+t.start.split("T")[1].substring(0,5)+(o?" (Extended event) ":" (Flerdagsevenemang) ")),r===g&&t.end.includes("T")&&s!==g&&(n=(o?"End: ":"Slut: ")+t.end.split("T")[1].substring(0,5)),r!==s&&(d=o?"cont. ":"fort. ")}else t.start&&t.start.includes("T")&&(l=t.start.split("T")[1].substring(0,5));return m`
38
+ <scb-list-item label="${d}${t.title}" supporting-text="${t.description?t.description:""}" overline="${l||""}${n||""}">
39
+ </scb-list-item>`})}
40
+ </scb-list>
41
+ </scb-dialog>
37
42
  `:""}
38
- `}};v.styles=x`
43
+ `}};w.styles=S`
39
44
  :host {
40
- display: block;
41
- font-family: var(--brand-font, Arial, sans-serif);
42
- background: var(--md-sys-color-surface, #fff);
43
- color: var(--md-sys-color-on-surface, #222);
44
- border-radius: 12px;
45
- border: var(--scb-elevation-2, 0 2px 8px rgba(0,0,0,0.08));
46
- padding: 16px;
45
+ display: block;
46
+ border: 1px solid var(--md-sys-color-outline-variant);
47
+ padding: var(--spacing-5);
48
+ border-radius: var(--md-sys-shape-corner-large);
49
+ background: var(--md-sys-color-surface);
47
50
  }
48
51
  .calendar-header {
49
- display: flex;
50
- align-items: center;
51
- justify-content: space-between;
52
- margin-bottom: 16px;
52
+ display: flex;
53
+ align-items: center;
54
+ justify-content: space-between;
55
+ margin-bottom: var(--spacing-5);
53
56
  border-bottom: 1px solid rgb(224, 224, 224);
54
- padding-bottom: 8px;
57
+ padding-bottom: var(--spacing-3);
55
58
  }
56
59
  .calendar-grid {
57
- display: grid;
58
- grid-template-columns: repeat(7, 1fr);
59
- gap: 4px;
60
- margin-bottom: 4px;
60
+ display: grid;
61
+ grid-template-columns: repeat(7, 1fr);
62
+ gap: var(--spacing-2);
63
+ margin-bottom: var(--spacing-2);
61
64
  }
62
65
  .calendar-grid-days{
63
66
  font-weight: 600;
64
- margin-bottom: 16px;
67
+ margin-bottom: var(--spacing-5);
65
68
  }
66
69
  .calendar-weeks {
67
70
  display: grid;
@@ -69,55 +72,57 @@ import{a as x,n as m,i as w,x as d,t as $}from"../../vendor/vendor.js";import"./
69
72
  }
70
73
  .calendar-titles-wrapper{
71
74
  display: grid;
72
- gap: 4px;
75
+ gap: var(--spacing-2);
73
76
  }
74
77
  .calendar-day {
75
- border-radius: 6px;
76
- min-height: 3.2em;
77
- display: flex;
78
- padding: 8px;
79
- box-sizing: border-box;
80
- overflow: hidden;
81
- gap: 8px;
82
- border: 1px solid #e0e0e0;
78
+ border-radius: 6px;
79
+ min-height: 50px;
80
+ display: flex;
81
+ padding: var(--spacing-3);
82
+ box-sizing: border-box;
83
+ overflow: hidden;
84
+ gap: var(--spacing-3);
85
+ border: 1px solid var(--md-sys-color-outline-variant, #e0e0e0);
83
86
  flex-direction: column;
84
87
  }
88
+ .calendar-day.has-event:focus {
89
+ outline: none;
90
+ }
91
+ md-focus-ring {
92
+ border-radius: 6px;
93
+ }
85
94
  .calendar-day--other {
86
- opacity: 0.4;
95
+ opacity: 0.4;
87
96
  }
88
97
  .calendar-day-number {
89
- font-size: 1em;
90
- line-height: 1.2;
98
+ font-size: var(--md-sys-typescale-label-small-size);
99
+ line-height: var(--md-sys-typescale-label-small-line-height); /* vissa tabeller i Figma visar 21 */
100
+ font-weight: var(--md-sys-typescale-label-small-weight);
101
+ letter-spacing: var(--md-sys-typescale-label-small-tracking);
91
102
  }
92
103
  .calendar-day-event-title {
93
- font-size: 12px;
94
- color: var(--md-sys-color-primary);
95
- white-space: nowrap;
96
- overflow: hidden;
97
- text-overflow: ellipsis;
98
- display: block;
99
- width: 100%;
104
+ font-size: 12px;
105
+ color: var(--md-sys-color-primary);
106
+ white-space: nowrap;
107
+ overflow: hidden;
108
+ text-overflow: ellipsis;
109
+ display: block;
110
+ width: 100%;
100
111
  }
101
112
  .calendar-day.today {
102
- border: 1px solid var(--md-sys-color-primary);
113
+ background: var(--md-sys-color-secondary-container);
114
+
103
115
  }
104
116
  .calendar-day.has-event {
105
117
  cursor: pointer;
106
- border: 2px solid var(--md-sys-color-primary);
107
- position: relative;
118
+ position: relative;
119
+ border: 1px solid var(--md-sys-color-primary);
108
120
  }
109
- .event-popup {
110
- position: fixed;
111
- z-index: 1000;
112
- background: #fff;
113
- color: #222;
114
- border-radius: 10px;
115
- box-shadow: 0 4px 24px rgba(0,0,0,0.18);
116
- min-width: 220px;
117
- max-width: 320px;
118
- padding: 16px 20px 16px 20px;
119
- top: 30%;
120
- left: 50%;
121
+
122
+ .event-popup-list{
123
+ display: flex;
124
+ flex-direction: column;
125
+ gap: var(--spacing-4);
121
126
  }
122
127
 
123
- `;g([m({type:String})],v.prototype,"label",2);g([m({type:String})],v.prototype,"value",2);v=g([$("scb-calendar")],v);
128
+ `;x([k({type:String})],w.prototype,"lang",2);w=x([C("scb-calendar")],w);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scb-wc-test",
3
- "version": "0.1.120",
3
+ "version": "0.1.121",
4
4
  "type": "module",
5
5
  "main": "index.js",
6
6
  "module": "index.js",
@@ -353,5 +353,5 @@
353
353
  },
354
354
  "./mvc/*": "./mvc/*"
355
355
  },
356
- "buildHash": "0897A21AC399DEBBBDCA38AD987E4E012CB498B06670BDFBE404ECBFDEDDA489"
356
+ "buildHash": "62D50E7AEB04DF26D21CAC5D5823CD9D286A1A8D4834CDF212EA8705A577DB49"
357
357
  }
@@ -1,8 +1,10 @@
1
1
  import { LitElement } from 'lit';
2
2
  export declare class ScbCalendarEvent extends LitElement {
3
3
  title: string;
4
- date: string;
5
4
  description: string;
5
+ startDate: string;
6
+ endDate: string;
6
7
  static styles: import('lit').CSSResult;
8
+ updated(changedProps: Map<string, any>): void;
7
9
  render(): import('lit-html').TemplateResult<1>;
8
10
  }
@@ -1,42 +1,43 @@
1
- import { css as c, LitElement as d, html as f } from "lit";
2
- import { property as l, customElement as h } from "lit/decorators.js";
3
- var v = Object.defineProperty, m = Object.getOwnPropertyDescriptor, p = (a, r, i, s) => {
4
- for (var t = s > 1 ? void 0 : s ? m(r, i) : r, o = a.length - 1, n; o >= 0; o--)
5
- (n = a[o]) && (t = (s ? n(r, i, t) : n(t)) || t);
6
- return s && t && v(r, i, t), t;
1
+ import { css as u, LitElement as d, html as c } from "lit";
2
+ import { property as i, customElement as y } from "lit/decorators.js";
3
+ var b = Object.defineProperty, h = Object.getOwnPropertyDescriptor, p = (t, e, n, a) => {
4
+ for (var r = a > 1 ? void 0 : a ? h(e, n) : e, o = t.length - 1, l; o >= 0; o--)
5
+ (l = t[o]) && (r = (a ? l(e, n, r) : l(r)) || r);
6
+ return a && r && b(e, n, r), r;
7
7
  };
8
- let e = class extends d {
8
+ let s = class extends d {
9
9
  constructor() {
10
- super(...arguments), this.title = "", this.date = "", this.description = "";
10
+ super(...arguments), this.title = "", this.description = "", this.startDate = "", this.endDate = "";
11
+ }
12
+ updated(t) {
13
+ var e;
14
+ (e = super.updated) == null || e.call(this, t), (t.has("title") || t.has("description") || t.has("startDate") || t.has("endDate")) && this.dispatchEvent(new Event("change", { bubbles: !0, composed: !0 }));
11
15
  }
12
16
  render() {
13
- return f`
14
- <div>
15
- <h3>${this.title}</h3>
16
- <p>${this.date}</p>
17
- <p>${this.description}</p>
18
- </div>
17
+ return c`
19
18
  `;
20
19
  }
21
20
  };
22
- e.styles = c`
21
+ s.styles = u`
23
22
  :host {
24
23
  display: block;
25
- font-family: var(--brand-font, Arial, sans-serif)
26
24
  }
27
25
  `;
28
26
  p([
29
- l({ type: String })
30
- ], e.prototype, "title", 2);
27
+ i({ type: String })
28
+ ], s.prototype, "title", 2);
29
+ p([
30
+ i({ type: String })
31
+ ], s.prototype, "description", 2);
31
32
  p([
32
- l({ type: String })
33
- ], e.prototype, "date", 2);
33
+ i({ type: String, attribute: "start-date" })
34
+ ], s.prototype, "startDate", 2);
34
35
  p([
35
- l({ type: String })
36
- ], e.prototype, "description", 2);
37
- e = p([
38
- h("scb-calendar-event")
39
- ], e);
36
+ i({ type: String, attribute: "end-date" })
37
+ ], s.prototype, "endDate", 2);
38
+ s = p([
39
+ y("scb-calendar-event")
40
+ ], s);
40
41
  export {
41
- e as ScbCalendarEvent
42
+ s as ScbCalendarEvent
42
43
  };
@@ -1,8 +1,11 @@
1
1
  import { LitElement } from 'lit';
2
2
  export declare class ScbCalendar extends LitElement {
3
- label: string;
4
- value: string;
3
+ lang: string;
5
4
  static styles: import('lit').CSSResult;
5
+ private _mutationObserver;
6
+ connectedCallback(): void;
7
+ disconnectedCallback(): void;
8
+ private _onEventChanged;
6
9
  private _today;
7
10
  private _current;
8
11
  private _popupEvent;