@ukic/web-components 2.26.0 → 2.28.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/ic-alert.cjs.entry.js +9 -4
- package/dist/cjs/ic-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-badge.cjs.entry.js +2 -2
- package/dist/cjs/ic-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-button_3.cjs.entry.js +5 -2
- package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-dialog.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-pagination.cjs.entry.js +2 -2
- package/dist/cjs/ic-pagination.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-group.cjs.entry.js +7 -0
- package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-text-field.cjs.entry.js +2 -1
- package/dist/cjs/ic-text-field.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toast.cjs.entry.js +1 -1
- package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ic-alert/ic-alert.css +9 -1
- package/dist/collection/components/ic-alert/ic-alert.js +27 -3
- package/dist/collection/components/ic-alert/ic-alert.js.map +1 -1
- package/dist/collection/components/ic-alert/test/basic/ic-alert.spec.js +114 -0
- package/dist/collection/components/ic-alert/test/basic/ic-alert.spec.js.map +1 -1
- package/dist/collection/components/ic-badge/ic-badge.css +5 -0
- package/dist/collection/components/ic-badge/ic-badge.js +1 -1
- package/dist/collection/components/ic-badge/ic-badge.js.map +1 -1
- package/dist/collection/components/ic-button/ic-button.js +5 -2
- package/dist/collection/components/ic-button/ic-button.js.map +1 -1
- package/dist/collection/components/ic-dialog/ic-dialog.js +1 -1
- package/dist/collection/components/ic-dialog/ic-dialog.js.map +1 -1
- package/dist/collection/components/ic-pagination/ic-pagination.css +5 -0
- package/dist/collection/components/ic-pagination/ic-pagination.js +1 -1
- package/dist/collection/components/ic-pagination/ic-pagination.js.map +1 -1
- package/dist/collection/components/ic-radio-group/ic-radio-group.js +9 -0
- package/dist/collection/components/ic-radio-group/ic-radio-group.js.map +1 -1
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.spec.js +10 -1
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.spec.js.map +1 -1
- package/dist/collection/components/ic-text-field/ic-text-field.js +20 -1
- package/dist/collection/components/ic-text-field/ic-text-field.js.map +1 -1
- package/dist/collection/components/ic-text-field/test/basic/ic-text-field.input.spec.js +7 -0
- package/dist/collection/components/ic-text-field/test/basic/ic-text-field.input.spec.js.map +1 -1
- package/dist/collection/components/ic-text-field/test/basic/ic-text-field.textarea.spec.js +47 -17
- package/dist/collection/components/ic-text-field/test/basic/ic-text-field.textarea.spec.js.map +1 -1
- package/dist/collection/components/ic-toast/ic-toast.css +10 -2
- package/dist/components/ic-alert2.js +11 -5
- package/dist/components/ic-alert2.js.map +1 -1
- package/dist/components/ic-badge.js +2 -2
- package/dist/components/ic-badge.js.map +1 -1
- package/dist/components/ic-button2.js +5 -2
- package/dist/components/ic-button2.js.map +1 -1
- package/dist/components/ic-dialog.js.map +1 -1
- package/dist/components/ic-pagination.js +2 -2
- package/dist/components/ic-pagination.js.map +1 -1
- package/dist/components/ic-radio-group.js +8 -0
- package/dist/components/ic-radio-group.js.map +1 -1
- package/dist/components/ic-text-field2.js +3 -1
- package/dist/components/ic-text-field2.js.map +1 -1
- package/dist/components/ic-toast.js +1 -1
- package/dist/components/ic-toast.js.map +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/p-1d648b98.entry.js +2 -0
- package/dist/core/p-1d648b98.entry.js.map +1 -0
- package/dist/core/{p-9146a7f9.entry.js → p-4562904d.entry.js} +2 -2
- package/dist/core/p-4562904d.entry.js.map +1 -0
- package/dist/core/p-457a4c63.entry.js +2 -0
- package/dist/core/p-457a4c63.entry.js.map +1 -0
- package/dist/core/{p-d21f0d15.entry.js → p-4b89890b.entry.js} +2 -2
- package/dist/core/p-4b89890b.entry.js.map +1 -0
- package/dist/core/p-55b11f6f.entry.js.map +1 -1
- package/dist/core/p-604e72ac.entry.js +2 -0
- package/dist/core/p-604e72ac.entry.js.map +1 -0
- package/dist/core/p-78605899.entry.js +2 -0
- package/dist/core/p-78605899.entry.js.map +1 -0
- package/dist/core/p-9e15d0e1.entry.js +2 -0
- package/dist/core/p-9e15d0e1.entry.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/ic-alert.entry.js +10 -5
- package/dist/esm/ic-alert.entry.js.map +1 -1
- package/dist/esm/ic-badge.entry.js +2 -2
- package/dist/esm/ic-badge.entry.js.map +1 -1
- package/dist/esm/ic-button_3.entry.js +5 -2
- package/dist/esm/ic-button_3.entry.js.map +1 -1
- package/dist/esm/ic-dialog.entry.js.map +1 -1
- package/dist/esm/ic-pagination.entry.js +2 -2
- package/dist/esm/ic-pagination.entry.js.map +1 -1
- package/dist/esm/ic-radio-group.entry.js +7 -0
- package/dist/esm/ic-radio-group.entry.js.map +1 -1
- package/dist/esm/ic-text-field.entry.js +2 -1
- package/dist/esm/ic-text-field.entry.js.map +1 -1
- package/dist/esm/ic-toast.entry.js +1 -1
- package/dist/esm/ic-toast.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-alert/ic-alert.d.ts +5 -0
- package/dist/types/components/ic-button/ic-button.d.ts +1 -0
- package/dist/types/components/ic-dialog/ic-dialog.d.ts +1 -1
- package/dist/types/components/ic-radio-group/ic-radio-group.d.ts +1 -0
- package/dist/types/components/ic-text-field/ic-text-field.d.ts +4 -0
- package/dist/types/components.d.ts +18 -2
- package/hydrate/index.js +31 -12
- package/package.json +2 -2
- package/vscode-data.json +9 -1
- package/dist/core/p-9146a7f9.entry.js.map +0 -1
- package/dist/core/p-ad67c84f.entry.js +0 -2
- package/dist/core/p-ad67c84f.entry.js.map +0 -1
- package/dist/core/p-b2ceb541.entry.js +0 -2
- package/dist/core/p-b2ceb541.entry.js.map +0 -1
- package/dist/core/p-b9be021b.entry.js +0 -2
- package/dist/core/p-b9be021b.entry.js.map +0 -1
- package/dist/core/p-c59474bb.entry.js +0 -2
- package/dist/core/p-c59474bb.entry.js.map +0 -1
- package/dist/core/p-d21f0d15.entry.js.map +0 -1
- package/dist/core/p-f735a277.entry.js +0 -2
- package/dist/core/p-f735a277.entry.js.map +0 -1
@@ -138,6 +138,10 @@ export namespace Components {
|
|
138
138
|
* The main body message of the alert.
|
139
139
|
*/
|
140
140
|
"message"?: string;
|
141
|
+
/**
|
142
|
+
* If `true`, the default icon for the neutral variant will be appear on the left of the alert.
|
143
|
+
*/
|
144
|
+
"showDefaultIcon": boolean;
|
141
145
|
/**
|
142
146
|
* If `true`, the title and message will appear above and below instead of inline.
|
143
147
|
*/
|
@@ -653,7 +657,7 @@ export namespace Components {
|
|
653
657
|
*/
|
654
658
|
"cancelDialog": () => Promise<void>;
|
655
659
|
/**
|
656
|
-
* If set to `
|
660
|
+
* If set to `false`, the dialog will not close when the backdrop is clicked.
|
657
661
|
*/
|
658
662
|
"closeOnBackdropClick"?: boolean;
|
659
663
|
/**
|
@@ -2093,6 +2097,10 @@ export namespace Components {
|
|
2093
2097
|
* The count of characters in the field. Will display a warning if the bound is reached.
|
2094
2098
|
*/
|
2095
2099
|
"maxLength": number;
|
2100
|
+
/**
|
2101
|
+
* The text to display as the validation message when the maximum length is exceeded.
|
2102
|
+
*/
|
2103
|
+
"maxLengthMessage": string;
|
2096
2104
|
/**
|
2097
2105
|
* The minimum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of min value in `helperText` or `label`)
|
2098
2106
|
*/
|
@@ -3460,6 +3468,10 @@ declare namespace LocalJSX {
|
|
3460
3468
|
* Is emitted when the user dismisses the alert.
|
3461
3469
|
*/
|
3462
3470
|
"onIcDismiss"?: (event: IcAlertCustomEvent<void>) => void;
|
3471
|
+
/**
|
3472
|
+
* If `true`, the default icon for the neutral variant will be appear on the left of the alert.
|
3473
|
+
*/
|
3474
|
+
"showDefaultIcon"?: boolean;
|
3463
3475
|
/**
|
3464
3476
|
* If `true`, the title and message will appear above and below instead of inline.
|
3465
3477
|
*/
|
@@ -3971,7 +3983,7 @@ declare namespace LocalJSX {
|
|
3971
3983
|
*/
|
3972
3984
|
"buttons"?: boolean;
|
3973
3985
|
/**
|
3974
|
-
* If set to `
|
3986
|
+
* If set to `false`, the dialog will not close when the backdrop is clicked.
|
3975
3987
|
*/
|
3976
3988
|
"closeOnBackdropClick"?: boolean;
|
3977
3989
|
/**
|
@@ -5454,6 +5466,10 @@ declare namespace LocalJSX {
|
|
5454
5466
|
* The count of characters in the field. Will display a warning if the bound is reached.
|
5455
5467
|
*/
|
5456
5468
|
"maxLength"?: number;
|
5469
|
+
/**
|
5470
|
+
* The text to display as the validation message when the maximum length is exceeded.
|
5471
|
+
*/
|
5472
|
+
"maxLengthMessage"?: string;
|
5457
5473
|
/**
|
5458
5474
|
* The minimum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of min value in `helperText` or `label`)
|
5459
5475
|
*/
|
package/hydrate/index.js
CHANGED
@@ -8344,11 +8344,12 @@ var closeIcon = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fil
|
|
8344
8344
|
</svg>
|
8345
8345
|
`;
|
8346
8346
|
|
8347
|
-
const icAlertCss = "/*!@html*/html.sc-ic-alert{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-alert{margin:0}/*!@main*/main.sc-ic-alert{display:block}/*!@h1*/h1.sc-ic-alert{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-alert{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-alert{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-alert{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-alert{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-alert,strong.sc-ic-alert{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-alert,kbd.sc-ic-alert,samp.sc-ic-alert{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-alert{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-alert,sup.sc-ic-alert{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-alert{bottom:-0.25em}/*!@sup*/sup.sc-ic-alert{top:-0.5em}/*!@img*/img.sc-ic-alert{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-alert,input.sc-ic-alert,optgroup.sc-ic-alert,select.sc-ic-alert,textarea.sc-ic-alert{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-alert,input.sc-ic-alert{overflow:visible}/*!@button,\nselect*/button.sc-ic-alert,select.sc-ic-alert{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-alert,[type=\"button\"].sc-ic-alert,[type=\"reset\"].sc-ic-alert,[type=\"submit\"].sc-ic-alert{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-alert::-moz-focus-inner,[type=\"button\"].sc-ic-alert::-moz-focus-inner,[type=\"reset\"].sc-ic-alert::-moz-focus-inner,[type=\"submit\"].sc-ic-alert::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-alert:-moz-focusring,[type=\"button\"].sc-ic-alert:-moz-focusring,[type=\"reset\"].sc-ic-alert:-moz-focusring,[type=\"submit\"].sc-ic-alert:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-alert{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-alert{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-alert{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-alert{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-alert,[type=\"radio\"].sc-ic-alert{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-alert::-webkit-inner-spin-button,[type=\"number\"].sc-ic-alert::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-alert{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-alert::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-alert::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-alert{display:block}/*!@summary*/summary.sc-ic-alert{display:list-item}/*!@template*/template.sc-ic-alert{display:none}/*!@[hidden]*/[hidden].sc-ic-alert{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-alert,body.sc-ic-alert,div.sc-ic-alert,span.sc-ic-alert,applet.sc-ic-alert,object.sc-ic-alert,iframe.sc-ic-alert,h1.sc-ic-alert,h2.sc-ic-alert,h3.sc-ic-alert,h4.sc-ic-alert,h5.sc-ic-alert,h6.sc-ic-alert,p.sc-ic-alert,blockquote.sc-ic-alert,pre.sc-ic-alert,a.sc-ic-alert,abbr.sc-ic-alert,acronym.sc-ic-alert,address.sc-ic-alert,big.sc-ic-alert,cite.sc-ic-alert,code.sc-ic-alert,del.sc-ic-alert,dfn.sc-ic-alert,em.sc-ic-alert,img.sc-ic-alert,ins.sc-ic-alert,kbd.sc-ic-alert,q.sc-ic-alert,s.sc-ic-alert,samp.sc-ic-alert,small.sc-ic-alert,strike.sc-ic-alert,strong.sc-ic-alert,sub.sc-ic-alert,sup.sc-ic-alert,tt.sc-ic-alert,var.sc-ic-alert,b.sc-ic-alert,u.sc-ic-alert,i.sc-ic-alert,center.sc-ic-alert,dl.sc-ic-alert,dt.sc-ic-alert,dd.sc-ic-alert,ol.sc-ic-alert,ul.sc-ic-alert,li.sc-ic-alert,fieldset.sc-ic-alert,form.sc-ic-alert,label.sc-ic-alert,legend.sc-ic-alert,table.sc-ic-alert,caption.sc-ic-alert,tbody.sc-ic-alert,tfoot.sc-ic-alert,thead.sc-ic-alert,tr.sc-ic-alert,th.sc-ic-alert,td.sc-ic-alert,article.sc-ic-alert,aside.sc-ic-alert,canvas.sc-ic-alert,details.sc-ic-alert,embed.sc-ic-alert,figure.sc-ic-alert,figcaption.sc-ic-alert,footer.sc-ic-alert,header.sc-ic-alert,hgroup.sc-ic-alert,menu.sc-ic-alert,nav.sc-ic-alert,output.sc-ic-alert,ruby.sc-ic-alert,section.sc-ic-alert,summary.sc-ic-alert,time.sc-ic-alert,mark.sc-ic-alert,audio.sc-ic-alert,video.sc-ic-alert{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}/*!@:host*/.sc-ic-alert-h{display:block}/*!@.container*/.container.sc-ic-alert{min-height:3.5rem;border-radius:var(--ic-border-radius);position:relative;display:flex;align-items:center}/*!@.container-neutral*/.container-neutral.sc-ic-alert{background-color:var(--ic-status-unknown-light)}/*!@.container-info*/.container-info.sc-ic-alert{background-color:var(--ic-status-info-light)}/*!@.container-warning*/.container-warning.sc-ic-alert{background-color:var(--ic-status-warning-light)}/*!@.container-error*/.container-error.sc-ic-alert{background-color:var(--ic-status-error-light)}/*!@.container-success*/.container-success.sc-ic-alert{background-color:var(--ic-status-success-light)}/*!@.alert-icon-container*/.alert-icon-container.sc-ic-alert{height:100%;display:flex;align-items:center}/*!@.divider*/.divider.sc-ic-alert{height:100%;width:var(--ic-space-xs);border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);position:absolute}/*!@.divider-neutral*/.divider-neutral.sc-ic-alert{background-color:var(--ic-status-unknown)}/*!@.divider-info*/.divider-info.sc-ic-alert{background-color:var(--ic-status-info)}/*!@.divider-warning*/.divider-warning.sc-ic-alert{background-color:var(--ic-status-warning)}/*!@.divider-error*/.divider-error.sc-ic-alert{background-color:var(--ic-status-error)}/*!@.divider-success*/.divider-success.sc-ic-alert{background-color:var(--ic-status-success)}/*!@.alert-icon*/.alert-icon.sc-ic-alert{height:var(--ic-space-lg);width:1.375rem;margin-left:1.125rem}/*!@.alert-icon > svg*/.alert-icon.sc-ic-alert>svg.sc-ic-alert{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block}/*!@.icon-neutral > svg*/.icon-neutral.sc-ic-alert>svg.sc-ic-alert{fill:var(--ic-status-unknown)}/*!@:host([variant=\"info\"]) .alert-icon svg*/[variant=\"info\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-info)}/*!@:host([variant=\"warning\"]) .alert-icon svg*/[variant=\"warning\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-warning)}/*!@:host([variant=\"error\"]) .alert-icon svg*/[variant=\"error\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-error)}/*!@:host([variant=\"success\"]) .alert-icon svg*/[variant=\"success\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-success)}/*!@.alert-content*/.alert-content.sc-ic-alert{display:flex;align-items:center;margin-left:0.625rem;width:100%}/*!@.alert-message*/.alert-message.sc-ic-alert{display:flex;align-items:center;padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;flex:1}/*!@.alert-message-title-above*/.alert-message-title-above.sc-ic-alert{display:inline}/*!@.alert-title*/.alert-title.sc-ic-alert{margin-right:var(--ic-space-xs)}/*!@.alert-title-above*/.alert-title-above.sc-ic-alert{white-space:normal}/*!@.alert-action-container*/.alert-action-container.sc-ic-alert{margin-right:var(--ic-space-xs);display:flex;align-items:center}/*!@.dismiss-icon*/.dismiss-icon.sc-ic-alert{margin-right:var(--ic-space-xxxs);margin-left:-0.375rem;padding:0.375rem;border:none;border-radius:50%;background-color:inherit;display:flex;align-items:center;justify-content:center}/*!@.dismiss-icon:hover*/.dismiss-icon.sc-ic-alert:hover{cursor:pointer}@media (max-width: 628px){/*!@.alert-content*/.alert-content.sc-ic-alert{display:flex;flex-direction:column;align-items:flex-start}/*!@.alert-message*/.alert-message.sc-ic-alert{display:flex;flex-direction:column;align-items:flex-start}/*!@.alert-title*/.alert-title.sc-ic-alert{white-space:normal}/*!@.alert-action-container*/.alert-action-container.sc-ic-alert{margin-bottom:var(--ic-space-xs)}}@media (forced-colors: active){/*!@.container*/.container.sc-ic-alert{border:var(--ic-hc-border)}}";
|
8347
|
+
const icAlertCss = "/*!@html*/html.sc-ic-alert{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-alert{margin:0}/*!@main*/main.sc-ic-alert{display:block}/*!@h1*/h1.sc-ic-alert{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-alert{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-alert{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-alert{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-alert{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-alert,strong.sc-ic-alert{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-alert,kbd.sc-ic-alert,samp.sc-ic-alert{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-alert{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-alert,sup.sc-ic-alert{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-alert{bottom:-0.25em}/*!@sup*/sup.sc-ic-alert{top:-0.5em}/*!@img*/img.sc-ic-alert{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-alert,input.sc-ic-alert,optgroup.sc-ic-alert,select.sc-ic-alert,textarea.sc-ic-alert{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-alert,input.sc-ic-alert{overflow:visible}/*!@button,\nselect*/button.sc-ic-alert,select.sc-ic-alert{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-alert,[type=\"button\"].sc-ic-alert,[type=\"reset\"].sc-ic-alert,[type=\"submit\"].sc-ic-alert{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-alert::-moz-focus-inner,[type=\"button\"].sc-ic-alert::-moz-focus-inner,[type=\"reset\"].sc-ic-alert::-moz-focus-inner,[type=\"submit\"].sc-ic-alert::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-alert:-moz-focusring,[type=\"button\"].sc-ic-alert:-moz-focusring,[type=\"reset\"].sc-ic-alert:-moz-focusring,[type=\"submit\"].sc-ic-alert:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-alert{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-alert{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-alert{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-alert{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-alert,[type=\"radio\"].sc-ic-alert{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-alert::-webkit-inner-spin-button,[type=\"number\"].sc-ic-alert::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-alert{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-alert::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-alert::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-alert{display:block}/*!@summary*/summary.sc-ic-alert{display:list-item}/*!@template*/template.sc-ic-alert{display:none}/*!@[hidden]*/[hidden].sc-ic-alert{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-alert,body.sc-ic-alert,div.sc-ic-alert,span.sc-ic-alert,applet.sc-ic-alert,object.sc-ic-alert,iframe.sc-ic-alert,h1.sc-ic-alert,h2.sc-ic-alert,h3.sc-ic-alert,h4.sc-ic-alert,h5.sc-ic-alert,h6.sc-ic-alert,p.sc-ic-alert,blockquote.sc-ic-alert,pre.sc-ic-alert,a.sc-ic-alert,abbr.sc-ic-alert,acronym.sc-ic-alert,address.sc-ic-alert,big.sc-ic-alert,cite.sc-ic-alert,code.sc-ic-alert,del.sc-ic-alert,dfn.sc-ic-alert,em.sc-ic-alert,img.sc-ic-alert,ins.sc-ic-alert,kbd.sc-ic-alert,q.sc-ic-alert,s.sc-ic-alert,samp.sc-ic-alert,small.sc-ic-alert,strike.sc-ic-alert,strong.sc-ic-alert,sub.sc-ic-alert,sup.sc-ic-alert,tt.sc-ic-alert,var.sc-ic-alert,b.sc-ic-alert,u.sc-ic-alert,i.sc-ic-alert,center.sc-ic-alert,dl.sc-ic-alert,dt.sc-ic-alert,dd.sc-ic-alert,ol.sc-ic-alert,ul.sc-ic-alert,li.sc-ic-alert,fieldset.sc-ic-alert,form.sc-ic-alert,label.sc-ic-alert,legend.sc-ic-alert,table.sc-ic-alert,caption.sc-ic-alert,tbody.sc-ic-alert,tfoot.sc-ic-alert,thead.sc-ic-alert,tr.sc-ic-alert,th.sc-ic-alert,td.sc-ic-alert,article.sc-ic-alert,aside.sc-ic-alert,canvas.sc-ic-alert,details.sc-ic-alert,embed.sc-ic-alert,figure.sc-ic-alert,figcaption.sc-ic-alert,footer.sc-ic-alert,header.sc-ic-alert,hgroup.sc-ic-alert,menu.sc-ic-alert,nav.sc-ic-alert,output.sc-ic-alert,ruby.sc-ic-alert,section.sc-ic-alert,summary.sc-ic-alert,time.sc-ic-alert,mark.sc-ic-alert,audio.sc-ic-alert,video.sc-ic-alert{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}/*!@:host*/.sc-ic-alert-h{display:block}/*!@.container*/.container.sc-ic-alert{min-height:3.5rem;border-radius:var(--ic-border-radius);position:relative;display:flex;align-items:center}/*!@.container-neutral*/.container-neutral.sc-ic-alert{background-color:var(--ic-status-unknown-light)}/*!@.container-info*/.container-info.sc-ic-alert{background-color:var(--ic-status-info-light)}/*!@.container-warning*/.container-warning.sc-ic-alert{background-color:var(--ic-status-warning-light)}/*!@.container-error*/.container-error.sc-ic-alert{background-color:var(--ic-status-error-light)}/*!@.container-success*/.container-success.sc-ic-alert{background-color:var(--ic-status-success-light)}/*!@.alert-icon-container*/.alert-icon-container.sc-ic-alert{height:100%;display:flex;align-items:center}/*!@.divider*/.divider.sc-ic-alert{height:100%;width:var(--ic-space-xs);border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);position:absolute}/*!@.divider-neutral*/.divider-neutral.sc-ic-alert{background-color:var(--ic-status-unknown)}/*!@.divider-info*/.divider-info.sc-ic-alert{background-color:var(--ic-status-info)}/*!@.divider-warning*/.divider-warning.sc-ic-alert{background-color:var(--ic-status-warning)}/*!@.divider-error*/.divider-error.sc-ic-alert{background-color:var(--ic-status-error)}/*!@.divider-success*/.divider-success.sc-ic-alert{background-color:var(--ic-status-success)}/*!@.alert-icon*/.alert-icon.sc-ic-alert{height:var(--ic-space-lg);width:1.375rem;margin-left:1.125rem}/*!@.icon-placeholder*/.icon-placeholder.sc-ic-alert{margin-left:var(--ic-space-xs)}/*!@.alert-icon > svg*/.alert-icon.sc-ic-alert>svg.sc-ic-alert{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block}/*!@.icon-neutral > svg,\n::slotted(svg)*/.icon-neutral.sc-ic-alert>svg.sc-ic-alert,.sc-ic-alert-s>svg{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block;fill:var(--ic-status-unknown)}/*!@:host([variant=\"info\"]) .alert-icon svg*/[variant=\"info\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-info)}/*!@:host([variant=\"warning\"]) .alert-icon svg*/[variant=\"warning\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-warning)}/*!@:host([variant=\"error\"]) .alert-icon svg*/[variant=\"error\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-error)}/*!@:host([variant=\"success\"]) .alert-icon svg*/[variant=\"success\"].sc-ic-alert-h .alert-icon.sc-ic-alert svg.sc-ic-alert{fill:var(--ic-status-success)}/*!@.alert-content*/.alert-content.sc-ic-alert{display:flex;align-items:center;margin-left:0.625rem;width:100%}/*!@.alert-message*/.alert-message.sc-ic-alert{display:flex;align-items:center;padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;flex:1}/*!@.alert-message-title-above*/.alert-message-title-above.sc-ic-alert{display:inline}/*!@.alert-title*/.alert-title.sc-ic-alert{margin-right:var(--ic-space-xs)}/*!@.alert-title-above*/.alert-title-above.sc-ic-alert{white-space:normal}/*!@.alert-action-container*/.alert-action-container.sc-ic-alert{margin-right:var(--ic-space-xs);display:flex;align-items:center}/*!@.dismiss-icon*/.dismiss-icon.sc-ic-alert{margin-right:var(--ic-space-xxxs);margin-left:-0.375rem;padding:0.375rem;border:none;border-radius:50%;background-color:inherit;display:flex;align-items:center;justify-content:center}/*!@.dismiss-icon:hover*/.dismiss-icon.sc-ic-alert:hover{cursor:pointer}@media (max-width: 628px){/*!@.alert-content*/.alert-content.sc-ic-alert{display:flex;flex-direction:column;align-items:flex-start}/*!@.alert-message*/.alert-message.sc-ic-alert{display:flex;flex-direction:column;align-items:flex-start}/*!@.alert-title*/.alert-title.sc-ic-alert{white-space:normal}/*!@.alert-action-container*/.alert-action-container.sc-ic-alert{margin-bottom:var(--ic-space-xs)}}@media (forced-colors: active){/*!@.container*/.container.sc-ic-alert{border:var(--ic-hc-border)}}";
|
8348
8348
|
|
8349
8349
|
/**
|
8350
8350
|
* @slot message - Content is placed to the right of the title.
|
8351
8351
|
* @slot action - Content is placed to the right of the message.
|
8352
|
+
* @slot neutral-icon - A custom neutral icon is placed to the left of the title. This will override the default icon if used.
|
8352
8353
|
*/
|
8353
8354
|
class Alert {
|
8354
8355
|
constructor(hostRef) {
|
@@ -8373,6 +8374,7 @@ class Alert {
|
|
8373
8374
|
this.message = undefined;
|
8374
8375
|
this.titleAbove = false;
|
8375
8376
|
this.variant = "neutral";
|
8377
|
+
this.showDefaultIcon = true;
|
8376
8378
|
}
|
8377
8379
|
disconnectedCallback() {
|
8378
8380
|
var _a;
|
@@ -8395,7 +8397,7 @@ class Alert {
|
|
8395
8397
|
this.alertTitleWrap = true;
|
8396
8398
|
}
|
8397
8399
|
render() {
|
8398
|
-
const { variant, heading, message, titleAbove, dismissible, announced, visible, } = this;
|
8400
|
+
const { variant, heading, message, titleAbove, dismissible, announced, visible, showDefaultIcon, } = this;
|
8399
8401
|
return (visible && (hAsync(Host, { role: announced ? "alert" : null, class: {
|
8400
8402
|
[IcThemeForegroundEnum.Dark]: true,
|
8401
8403
|
} }, hAsync("div", { class: {
|
@@ -8404,11 +8406,15 @@ class Alert {
|
|
8404
8406
|
} }, hAsync("div", { class: "alert-icon-container" }, hAsync("div", { class: {
|
8405
8407
|
["divider"]: true,
|
8406
8408
|
[`divider-${variant}`]: true,
|
8407
|
-
} }), hAsync("span", { class: {
|
8409
|
+
} }), variant === "neutral" ? (isSlotUsed(this.el, "neutral-icon") ? (hAsync("div", { class: "alert-icon svg-container icon-neutral" }, hAsync("slot", { name: "neutral-icon" }))) : showDefaultIcon ? (hAsync("span", { class: {
|
8408
8410
|
["alert-icon"]: true,
|
8409
8411
|
["svg-container"]: true,
|
8410
8412
|
[`icon-${variant}`]: true,
|
8411
|
-
}, innerHTML: VARIANT_ICONS[variant].icon }))
|
8413
|
+
}, innerHTML: VARIANT_ICONS[variant].icon })) : (hAsync("div", { class: "icon-placeholder" }))) : (hAsync("span", { class: {
|
8414
|
+
["alert-icon"]: true,
|
8415
|
+
["svg-container"]: true,
|
8416
|
+
[`icon-${variant}`]: true,
|
8417
|
+
}, innerHTML: VARIANT_ICONS[variant].icon }))), hAsync("div", { class: "alert-content" }, hAsync("div", { class: {
|
8412
8418
|
["alert-message"]: true,
|
8413
8419
|
["alert-message-title-above"]: titleAbove || this.alertTitleWrap,
|
8414
8420
|
} }, heading && (hAsync("ic-typography", { class: {
|
@@ -8431,6 +8437,7 @@ class Alert {
|
|
8431
8437
|
"message": [1],
|
8432
8438
|
"titleAbove": [4, "title-above"],
|
8433
8439
|
"variant": [1],
|
8440
|
+
"showDefaultIcon": [4, "show-default-icon"],
|
8434
8441
|
"alertTitleWrap": [32],
|
8435
8442
|
"visible": [32]
|
8436
8443
|
},
|
@@ -8597,7 +8604,7 @@ class BackToTop {
|
|
8597
8604
|
}; }
|
8598
8605
|
}
|
8599
8606
|
|
8600
|
-
const icBadgeCss = "@media (prefers-reduced-motion: no-preference){/*!@:host(.show)*/.show.sc-ic-badge-h{animation:expand var(--ic-transition-duration-slow)}/*!@:host(.hide)*/.hide.sc-ic-badge-h{animation:shrink var(--ic-transition-duration-slow)}}/*!@:host*/.sc-ic-badge-h{display:flex;height:var(--ic-space-md);min-width:var(--ic-space-md);width:-moz-fit-content;width:fit-content;border-radius:calc(2 * var(--ic-space-xxl));position:absolute}/*!@:host(.neutral)*/.neutral.sc-ic-badge-h{background-color:var(--ic-architectural-500)}/*!@:host(.light)*/.light.sc-ic-badge-h{background-color:var(--ic-architectural-40)}/*!@:host(.info)*/.info.sc-ic-badge-h{background-color:var(--ic-status-info)}/*!@:host(.warning)*/.warning.sc-ic-badge-h{background-color:var(--ic-status-warning-mid)}/*!@:host(.error)*/.error.sc-ic-badge-h{background-color:var(--ic-status-error)}/*!@:host(.success)*/.success.sc-ic-badge-h{background-color:var(--ic-status-success)}/*!@:host(.small)*/.small.sc-ic-badge-h{height:var(--ic-space-sm);min-width:var(--ic-space-sm)}/*!@:host(.large)*/.large.sc-ic-badge-h{height:calc(var(--ic-space-md) + var(--ic-space-xxs));min-width:calc(var(--ic-space-md) + var(--ic-space-xxs))}/*!@:host(.dot.default)*/.dot.default.sc-ic-badge-h{height:var(--ic-space-xs);width:var(--ic-space-xs);min-width:var(--ic-space-xs)}/*!@:host(.dot.small)*/.dot.small.sc-ic-badge-h{height:calc(var(--ic-space-xxs) + var(--ic-space-xxxs));width:calc(var(--ic-space-xxs) + var(--ic-space-xxxs));min-width:calc(var(--ic-space-xxs) + var(--ic-space-xxxs))}/*!@:host(.dot.large)*/.dot.large.sc-ic-badge-h{height:var(--ic-space-sm);width:var(--ic-space-sm);min-width:var(--ic-space-sm)}/*!@:host(.foreground-dark) ::slotted(*)*/.sc-ic-badge-h.foreground-dark .sc-ic-badge-s>*{fill:var(--ic-color-primary-text)}/*!@:host(.foreground-light) ::slotted(*)*/.sc-ic-badge-h.foreground-light .sc-ic-badge-s>*{fill:white}/*!@:host(.foreground-dark) ic-typography*/.foreground-dark.sc-ic-badge-h ic-typography.sc-ic-badge{color:var(--ic-color-primary-text)}/*!@:host(.foreground-light) ic-typography*/.foreground-light.sc-ic-badge-h ic-typography.sc-ic-badge{color:white}/*!@:host(.text) ic-typography*/.text.sc-ic-badge-h ic-typography.sc-ic-badge{align-self:center;padding:0 calc((var(--ic-space-xs) + var(--ic-space-1px)) / 2)\n var(--ic-space-1px)}/*!@:host(.text.small) ic-typography*/.text.small.sc-ic-badge-h ic-typography.sc-ic-badge{padding:0 0.2132rem}/*!@:host(.text.large) ic-typography*/.text.large.sc-ic-badge-h ic-typography.sc-ic-badge{padding:0 calc((var(--ic-space-sm) + var(--ic-space-1px)) / 2)\n var(--ic-space-1px)}/*!@:host(.icon) ::slotted(svg)*/.sc-ic-badge-h.icon .sc-ic-badge-s>svg{width:var(--ic-space-sm);height:var(--ic-space-sm);padding:var(--ic-space-xxxs)}/*!@:host(.icon.small) ::slotted(svg)*/.sc-ic-badge-h.icon.small .sc-ic-badge-s>svg{width:var(--ic-space-xs);height:var(--ic-space-xs)}/*!@:host(.icon.large) ::slotted(svg)*/.sc-ic-badge-h.icon.large .sc-ic-badge-s>svg{width:calc(var(--ic-space-sm) + var(--ic-space-xxxs));height:calc(var(--ic-space-sm) + var(--ic-space-xxxs));padding:calc(var(--ic-space-xxxs) + var(--ic-space-1px))}/*!@:host(.far)*/.far.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xs));right:calc(-1 * var(--ic-space-xs))}/*!@:host(.far.small),\n:host(.dot.far.large)*/.far.small.sc-ic-badge-h,.dot.far.large.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xxs));right:calc(-1 * var(--ic-space-xxs))}/*!@:host(.dot.far),\n:host(.dot.far.small)*/.dot.far.sc-ic-badge-h,.dot.far.small.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xxxs));right:calc(-1 * var(--ic-space-xxxs))}/*!@:host(.near)*/.near.sc-ic-badge-h{top:calc(-1 * calc(var(--ic-space-xxs) + var(--ic-space-1px)));right:calc(-1 * calc(var(--ic-space-xxs) + var(--ic-space-1px)))}/*!@:host(.dot.near)*/.dot.near.sc-ic-badge-h{top:calc(-1 * var(--ic-space-1px));right:calc(-1 * var(--ic-space-1px))}/*!@:host(.inline)*/.inline.sc-ic-badge-h{position:static}/*!@:host(.hide)*/.hide.sc-ic-badge-h{visibility:hidden !important;transition:visibility var(--ic-transition-duration-slow)}@keyframes expand{from{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}@keyframes shrink{from{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(0)}}";
|
8607
|
+
const icBadgeCss = "@media (prefers-reduced-motion: no-preference){/*!@:host(.show)*/.show.sc-ic-badge-h{animation:expand var(--ic-transition-duration-slow)}/*!@:host(.hide)*/.hide.sc-ic-badge-h{animation:shrink var(--ic-transition-duration-slow)}}/*!@:host*/.sc-ic-badge-h{display:flex;height:var(--ic-space-md);min-width:var(--ic-space-md);width:-moz-fit-content;width:fit-content;border-radius:calc(2 * var(--ic-space-xxl));position:absolute}/*!@:host(.neutral)*/.neutral.sc-ic-badge-h{background-color:var(--ic-architectural-500)}/*!@:host(.light)*/.light.sc-ic-badge-h{background-color:var(--ic-architectural-40)}/*!@:host(.info)*/.info.sc-ic-badge-h{background-color:var(--ic-status-info)}/*!@:host(.warning)*/.warning.sc-ic-badge-h{background-color:var(--ic-status-warning-mid)}/*!@:host(.error)*/.error.sc-ic-badge-h{background-color:var(--ic-status-error)}/*!@:host(.success)*/.success.sc-ic-badge-h{background-color:var(--ic-status-success)}/*!@:host(.small)*/.small.sc-ic-badge-h{height:var(--ic-space-sm);min-width:var(--ic-space-sm)}/*!@:host(.large)*/.large.sc-ic-badge-h{height:calc(var(--ic-space-md) + var(--ic-space-xxs));min-width:calc(var(--ic-space-md) + var(--ic-space-xxs))}/*!@:host(.dot.default)*/.dot.default.sc-ic-badge-h{height:var(--ic-space-xs);width:var(--ic-space-xs);min-width:var(--ic-space-xs)}/*!@:host(.dot.small)*/.dot.small.sc-ic-badge-h{height:calc(var(--ic-space-xxs) + var(--ic-space-xxxs));width:calc(var(--ic-space-xxs) + var(--ic-space-xxxs));min-width:calc(var(--ic-space-xxs) + var(--ic-space-xxxs))}/*!@:host(.dot.large)*/.dot.large.sc-ic-badge-h{height:var(--ic-space-sm);width:var(--ic-space-sm);min-width:var(--ic-space-sm)}/*!@:host(.foreground-dark) ::slotted(*)*/.sc-ic-badge-h.foreground-dark .sc-ic-badge-s>*{fill:var(--ic-color-primary-text)}/*!@:host(.foreground-light) ::slotted(*)*/.sc-ic-badge-h.foreground-light .sc-ic-badge-s>*{fill:white}/*!@:host(.foreground-dark) ic-typography*/.foreground-dark.sc-ic-badge-h ic-typography.sc-ic-badge{color:var(--ic-color-primary-text)}/*!@:host(.foreground-light) ic-typography*/.foreground-light.sc-ic-badge-h ic-typography.sc-ic-badge{color:white}/*!@:host(.text) ic-typography*/.text.sc-ic-badge-h ic-typography.sc-ic-badge{align-self:center;padding:0 calc((var(--ic-space-xs) + var(--ic-space-1px)) / 2)\n var(--ic-space-1px)}/*!@:host(.text.small) ic-typography*/.text.small.sc-ic-badge-h ic-typography.sc-ic-badge{padding:0 0.2132rem}/*!@:host(.text.large) ic-typography*/.text.large.sc-ic-badge-h ic-typography.sc-ic-badge{padding:0 calc((var(--ic-space-sm) + var(--ic-space-1px)) / 2)\n var(--ic-space-1px)}/*!@:host(.icon) ::slotted(svg)*/.sc-ic-badge-h.icon .sc-ic-badge-s>svg{width:var(--ic-space-sm);height:var(--ic-space-sm);padding:var(--ic-space-xxxs)}/*!@:host(.icon.small) ::slotted(svg)*/.sc-ic-badge-h.icon.small .sc-ic-badge-s>svg{width:var(--ic-space-xs);height:var(--ic-space-xs)}/*!@:host(.icon.large) ::slotted(svg)*/.sc-ic-badge-h.icon.large .sc-ic-badge-s>svg{width:calc(var(--ic-space-sm) + var(--ic-space-xxxs));height:calc(var(--ic-space-sm) + var(--ic-space-xxxs));padding:calc(var(--ic-space-xxxs) + var(--ic-space-1px))}/*!@:host(.far)*/.far.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xs));right:calc(-1 * var(--ic-space-xs))}/*!@:host(.far.small),\n:host(.dot.far.large)*/.far.small.sc-ic-badge-h,.dot.far.large.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xxs));right:calc(-1 * var(--ic-space-xxs))}/*!@:host(.dot.far),\n:host(.dot.far.small)*/.dot.far.sc-ic-badge-h,.dot.far.small.sc-ic-badge-h{top:calc(-1 * var(--ic-space-xxxs));right:calc(-1 * var(--ic-space-xxxs))}/*!@:host(.near)*/.near.sc-ic-badge-h{top:calc(-1 * calc(var(--ic-space-xxs) + var(--ic-space-1px)));right:calc(-1 * calc(var(--ic-space-xxs) + var(--ic-space-1px)))}/*!@:host(.dot.near)*/.dot.near.sc-ic-badge-h{top:calc(-1 * var(--ic-space-1px));right:calc(-1 * var(--ic-space-1px))}/*!@:host(.inline)*/.inline.sc-ic-badge-h{position:static}/*!@:host(.hide)*/.hide.sc-ic-badge-h{visibility:hidden !important;transition:visibility var(--ic-transition-duration-slow)}/*!@.sr-only*/.sr-only.sc-ic-badge{position:absolute;left:-9999px}@keyframes expand{from{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}@keyframes shrink{from{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(0)}}";
|
8601
8608
|
|
8602
8609
|
/**
|
8603
8610
|
* @slot badge-icon - Icon will be rendered inside the badge if type is set to icon.
|
@@ -8716,7 +8723,7 @@ class Badge {
|
|
8716
8723
|
[`${type}`]: true,
|
8717
8724
|
[`foreground-${foregroundColour}`]: foregroundColour !== null,
|
8718
8725
|
[`${visible ? "show" : "hide"}`]: true,
|
8719
|
-
}, id: el.id || null, "aria-label": ariaLabel, role: "status" }, type === "icon" && hAsync("slot", { name: "badge-icon" }), type === "text" && textLabel && (hAsync("ic-typography", { variant: size === "small" ? "badge-small" : "badge" }, getTextLabel()))));
|
8726
|
+
}, id: el.id || null, "aria-label": ariaLabel, role: "status" }, type === "icon" && hAsync("slot", { name: "badge-icon" }), type === "text" && textLabel && (hAsync("ic-typography", { variant: size === "small" ? "badge-small" : "badge" }, getTextLabel())), type === "dot" && hAsync("span", { class: "sr-only" }, "badge")));
|
8720
8727
|
}
|
8721
8728
|
static get delegatesFocus() { return true; }
|
8722
8729
|
get el() { return getElement(this); }
|
@@ -9127,7 +9134,10 @@ class Button {
|
|
9127
9134
|
};
|
9128
9135
|
this.setHasTooltip = () => {
|
9129
9136
|
this.hasTooltip =
|
9130
|
-
!this.disableTooltip && (!!this.title || this.
|
9137
|
+
!this.disableTooltip && (!!this.title || this.isIconVariant());
|
9138
|
+
};
|
9139
|
+
this.isIconVariant = () => {
|
9140
|
+
return this.variant.startsWith("icon");
|
9131
9141
|
};
|
9132
9142
|
this.ariaLabel = null;
|
9133
9143
|
this.describedByContent = null;
|
@@ -9346,7 +9356,7 @@ class Button {
|
|
9346
9356
|
["white-background"]: this.variant === "secondary" &&
|
9347
9357
|
!this.transparentBackground &&
|
9348
9358
|
this.appearance !== "light",
|
9349
|
-
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown, "aria-owns": this.ariaOwnsId, "aria-controls": this.ariaControlsId, "aria-expanded": this.dropdown && `${this.dropdownExpanded}` }, this.hasTooltip && (hAsync("ic-tooltip", { id: describedby, label: title || ariaLabel, target: buttonId, placement: this.tooltipPlacement, silent: this.
|
9359
|
+
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown, "aria-owns": this.ariaOwnsId, "aria-controls": this.ariaControlsId, "aria-expanded": this.dropdown && `${this.dropdownExpanded}` }, this.hasTooltip && (hAsync("ic-tooltip", { id: describedby, label: title || ariaLabel, target: buttonId, placement: this.tooltipPlacement, silent: this.isIconVariant() && !!ariaLabel }, this.hasRouterSlot() ? (hAsync("slot", { name: "router-item" })) : (hAsync(ButtonContent, null)))), isSlotUsed(this.el, "badge") && hAsync("slot", { name: "badge" }), !this.hasTooltip &&
|
9350
9360
|
(this.hasRouterSlot() ? (hAsync("slot", { name: "router-item" })) : (hAsync(ButtonContent, null))), this.describedByContent && (hAsync("span", { id: describedby, class: "ic-button-describedby" }, this.describedByContent))));
|
9351
9361
|
}
|
9352
9362
|
static get delegatesFocus() { return true; }
|
@@ -15221,7 +15231,7 @@ var paginationFirstLast = `<svg width="12" height="10" viewBox="0 0 12 10" fill=
|
|
15221
15231
|
<path d="M11.1709 8.825L7.34589 5L11.1709 1.175L9.99589 0L4.99589 5L9.99589 10L11.1709 8.825ZM0.829224 0H2.49589V10H0.829224V0Z" fill="currentColour"/>
|
15222
15232
|
</svg>`;
|
15223
15233
|
|
15224
|
-
const icPaginationCss = "/*!@html*/html.sc-ic-pagination{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-pagination{margin:0}/*!@main*/main.sc-ic-pagination{display:block}/*!@h1*/h1.sc-ic-pagination{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-pagination{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-pagination{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-pagination{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-pagination{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-pagination,strong.sc-ic-pagination{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-pagination,kbd.sc-ic-pagination,samp.sc-ic-pagination{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-pagination{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-pagination,sup.sc-ic-pagination{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-pagination{bottom:-0.25em}/*!@sup*/sup.sc-ic-pagination{top:-0.5em}/*!@img*/img.sc-ic-pagination{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-pagination,input.sc-ic-pagination,optgroup.sc-ic-pagination,select.sc-ic-pagination,textarea.sc-ic-pagination{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-pagination,input.sc-ic-pagination{overflow:visible}/*!@button,\nselect*/button.sc-ic-pagination,select.sc-ic-pagination{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-pagination,[type=\"button\"].sc-ic-pagination,[type=\"reset\"].sc-ic-pagination,[type=\"submit\"].sc-ic-pagination{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-pagination::-moz-focus-inner,[type=\"button\"].sc-ic-pagination::-moz-focus-inner,[type=\"reset\"].sc-ic-pagination::-moz-focus-inner,[type=\"submit\"].sc-ic-pagination::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-pagination:-moz-focusring,[type=\"button\"].sc-ic-pagination:-moz-focusring,[type=\"reset\"].sc-ic-pagination:-moz-focusring,[type=\"submit\"].sc-ic-pagination:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-pagination{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-pagination{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-pagination{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-pagination{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-pagination,[type=\"radio\"].sc-ic-pagination{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-pagination::-webkit-inner-spin-button,[type=\"number\"].sc-ic-pagination::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-pagination{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-pagination::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-pagination::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-pagination{display:block}/*!@summary*/summary.sc-ic-pagination{display:list-item}/*!@template*/template.sc-ic-pagination{display:none}/*!@[hidden]*/[hidden].sc-ic-pagination{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-pagination,body.sc-ic-pagination,div.sc-ic-pagination,span.sc-ic-pagination,applet.sc-ic-pagination,object.sc-ic-pagination,iframe.sc-ic-pagination,h1.sc-ic-pagination,h2.sc-ic-pagination,h3.sc-ic-pagination,h4.sc-ic-pagination,h5.sc-ic-pagination,h6.sc-ic-pagination,p.sc-ic-pagination,blockquote.sc-ic-pagination,pre.sc-ic-pagination,a.sc-ic-pagination,abbr.sc-ic-pagination,acronym.sc-ic-pagination,address.sc-ic-pagination,big.sc-ic-pagination,cite.sc-ic-pagination,code.sc-ic-pagination,del.sc-ic-pagination,dfn.sc-ic-pagination,em.sc-ic-pagination,img.sc-ic-pagination,ins.sc-ic-pagination,kbd.sc-ic-pagination,q.sc-ic-pagination,s.sc-ic-pagination,samp.sc-ic-pagination,small.sc-ic-pagination,strike.sc-ic-pagination,strong.sc-ic-pagination,sub.sc-ic-pagination,sup.sc-ic-pagination,tt.sc-ic-pagination,var.sc-ic-pagination,b.sc-ic-pagination,u.sc-ic-pagination,i.sc-ic-pagination,center.sc-ic-pagination,dl.sc-ic-pagination,dt.sc-ic-pagination,dd.sc-ic-pagination,ol.sc-ic-pagination,ul.sc-ic-pagination,li.sc-ic-pagination,fieldset.sc-ic-pagination,form.sc-ic-pagination,label.sc-ic-pagination,legend.sc-ic-pagination,table.sc-ic-pagination,caption.sc-ic-pagination,tbody.sc-ic-pagination,tfoot.sc-ic-pagination,thead.sc-ic-pagination,tr.sc-ic-pagination,th.sc-ic-pagination,td.sc-ic-pagination,article.sc-ic-pagination,aside.sc-ic-pagination,canvas.sc-ic-pagination,details.sc-ic-pagination,embed.sc-ic-pagination,figure.sc-ic-pagination,figcaption.sc-ic-pagination,footer.sc-ic-pagination,header.sc-ic-pagination,hgroup.sc-ic-pagination,menu.sc-ic-pagination,nav.sc-ic-pagination,output.sc-ic-pagination,ruby.sc-ic-pagination,section.sc-ic-pagination,summary.sc-ic-pagination,time.sc-ic-pagination,mark.sc-ic-pagination,audio.sc-ic-pagination,video.sc-ic-pagination{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}/*!@:host*/.sc-ic-pagination-h{box-sizing:border-box;width:100%;display:flex;justify-content:center}/*!@nav*/nav.sc-ic-pagination{width:100%;display:flex;flex-flow:row wrap;justify-content:flex-start;align-items:center}/*!@ic-button*/ic-button.sc-ic-pagination{cursor:pointer}/*!@ic-button.next-previous*/ic-button.next-previous.sc-ic-pagination{--icon-width:var(--ic-space-xs);--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs));padding:0 var(--ic-space-xxs) 0 var(--ic-space-xxxs)}/*!@ic-button.first-last*/ic-button.first-last.sc-ic-pagination{--icon-width:calc(var(--ic-space-sm) + var(--ic-space-xxxs));--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs))}/*!@.disabled*/.disabled.sc-ic-pagination{color:var(--ic-architectural-200);pointer-events:none;cursor:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}/*!@.hide-current-page*/.hide-current-page.sc-ic-pagination{display:none}";
|
15234
|
+
const icPaginationCss = "/*!@html*/html.sc-ic-pagination{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-pagination{margin:0}/*!@main*/main.sc-ic-pagination{display:block}/*!@h1*/h1.sc-ic-pagination{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-pagination{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-pagination{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-pagination{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-pagination{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-pagination,strong.sc-ic-pagination{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-pagination,kbd.sc-ic-pagination,samp.sc-ic-pagination{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-pagination{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-pagination,sup.sc-ic-pagination{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-pagination{bottom:-0.25em}/*!@sup*/sup.sc-ic-pagination{top:-0.5em}/*!@img*/img.sc-ic-pagination{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-pagination,input.sc-ic-pagination,optgroup.sc-ic-pagination,select.sc-ic-pagination,textarea.sc-ic-pagination{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-pagination,input.sc-ic-pagination{overflow:visible}/*!@button,\nselect*/button.sc-ic-pagination,select.sc-ic-pagination{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-pagination,[type=\"button\"].sc-ic-pagination,[type=\"reset\"].sc-ic-pagination,[type=\"submit\"].sc-ic-pagination{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-pagination::-moz-focus-inner,[type=\"button\"].sc-ic-pagination::-moz-focus-inner,[type=\"reset\"].sc-ic-pagination::-moz-focus-inner,[type=\"submit\"].sc-ic-pagination::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-pagination:-moz-focusring,[type=\"button\"].sc-ic-pagination:-moz-focusring,[type=\"reset\"].sc-ic-pagination:-moz-focusring,[type=\"submit\"].sc-ic-pagination:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-pagination{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-pagination{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-pagination{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-pagination{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-pagination,[type=\"radio\"].sc-ic-pagination{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-pagination::-webkit-inner-spin-button,[type=\"number\"].sc-ic-pagination::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-pagination{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-pagination::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-pagination::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-pagination{display:block}/*!@summary*/summary.sc-ic-pagination{display:list-item}/*!@template*/template.sc-ic-pagination{display:none}/*!@[hidden]*/[hidden].sc-ic-pagination{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-pagination,body.sc-ic-pagination,div.sc-ic-pagination,span.sc-ic-pagination,applet.sc-ic-pagination,object.sc-ic-pagination,iframe.sc-ic-pagination,h1.sc-ic-pagination,h2.sc-ic-pagination,h3.sc-ic-pagination,h4.sc-ic-pagination,h5.sc-ic-pagination,h6.sc-ic-pagination,p.sc-ic-pagination,blockquote.sc-ic-pagination,pre.sc-ic-pagination,a.sc-ic-pagination,abbr.sc-ic-pagination,acronym.sc-ic-pagination,address.sc-ic-pagination,big.sc-ic-pagination,cite.sc-ic-pagination,code.sc-ic-pagination,del.sc-ic-pagination,dfn.sc-ic-pagination,em.sc-ic-pagination,img.sc-ic-pagination,ins.sc-ic-pagination,kbd.sc-ic-pagination,q.sc-ic-pagination,s.sc-ic-pagination,samp.sc-ic-pagination,small.sc-ic-pagination,strike.sc-ic-pagination,strong.sc-ic-pagination,sub.sc-ic-pagination,sup.sc-ic-pagination,tt.sc-ic-pagination,var.sc-ic-pagination,b.sc-ic-pagination,u.sc-ic-pagination,i.sc-ic-pagination,center.sc-ic-pagination,dl.sc-ic-pagination,dt.sc-ic-pagination,dd.sc-ic-pagination,ol.sc-ic-pagination,ul.sc-ic-pagination,li.sc-ic-pagination,fieldset.sc-ic-pagination,form.sc-ic-pagination,label.sc-ic-pagination,legend.sc-ic-pagination,table.sc-ic-pagination,caption.sc-ic-pagination,tbody.sc-ic-pagination,tfoot.sc-ic-pagination,thead.sc-ic-pagination,tr.sc-ic-pagination,th.sc-ic-pagination,td.sc-ic-pagination,article.sc-ic-pagination,aside.sc-ic-pagination,canvas.sc-ic-pagination,details.sc-ic-pagination,embed.sc-ic-pagination,figure.sc-ic-pagination,figcaption.sc-ic-pagination,footer.sc-ic-pagination,header.sc-ic-pagination,hgroup.sc-ic-pagination,menu.sc-ic-pagination,nav.sc-ic-pagination,output.sc-ic-pagination,ruby.sc-ic-pagination,section.sc-ic-pagination,summary.sc-ic-pagination,time.sc-ic-pagination,mark.sc-ic-pagination,audio.sc-ic-pagination,video.sc-ic-pagination{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}/*!@:host*/.sc-ic-pagination-h{box-sizing:border-box;width:100%;display:flex;justify-content:center}/*!@nav*/nav.sc-ic-pagination{width:100%;display:flex;flex-flow:row wrap;justify-content:flex-start;align-items:center}/*!@ic-button*/ic-button.sc-ic-pagination{cursor:pointer}/*!@ic-button.next-previous*/ic-button.next-previous.sc-ic-pagination{--icon-width:var(--ic-space-xs);--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs));padding:0 var(--ic-space-xxs) 0 var(--ic-space-xxxs)}/*!@ic-button.first-last*/ic-button.first-last.sc-ic-pagination{--icon-width:calc(var(--ic-space-sm) + var(--ic-space-xxxs));--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs))}/*!@.disabled*/.disabled.sc-ic-pagination{color:var(--ic-architectural-200);pointer-events:none;cursor:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}/*!@.hide-current-page*/.hide-current-page.sc-ic-pagination{display:none}/*!@.sr-only*/.sr-only.sc-ic-pagination{position:absolute;left:-9999px}";
|
15225
15235
|
|
15226
15236
|
class Pagination {
|
15227
15237
|
constructor(hostRef) {
|
@@ -15428,7 +15438,7 @@ class Pagination {
|
|
15428
15438
|
["disabled"]: disabled,
|
15429
15439
|
}, role: "navigation", "aria-label": "Pagination Navigation" }, hideFirstAndLastPageButton ? null : this.firstButton(), this.previousButton(), hAsync("ic-pagination-item", { appearance: this.appearance, type: "simple-current", page: currentPage, label: label, class: { ["hide-current-page"]: hideCurrentPage }, disabled: disabled }), this.nextButton(), hideFirstAndLastPageButton ? null : this.lastButton())), type === "complex" && (hAsync("nav", { class: {
|
15430
15440
|
["disabled"]: disabled,
|
15431
|
-
}, role: "navigation", "aria-label": "Pagination Navigation" }, hideFirstAndLastPageButton ? null : this.firstButton(), this.previousButton(), this.renderStartItems(), this.startEllipsis && this.renderStartEllipsis(), this.renderMiddleItems(), this.endEllipsis && this.renderEndEllipsis(), this.renderEndItems(), this.nextButton(), hideFirstAndLastPageButton ? null : this.lastButton()))));
|
15441
|
+
}, role: "navigation", "aria-label": "Pagination Navigation" }, hideFirstAndLastPageButton ? null : this.firstButton(), this.previousButton(), this.renderStartItems(), this.startEllipsis && this.renderStartEllipsis(), this.renderMiddleItems(), this.endEllipsis && this.renderEndEllipsis(), this.renderEndItems(), this.nextButton(), hideFirstAndLastPageButton ? null : this.lastButton())), type === "complex" && (hAsync("span", { class: "sr-only", "aria-live": "polite" }, "Page ", this.currentPage))));
|
15432
15442
|
}
|
15433
15443
|
get el() { return getElement(this); }
|
15434
15444
|
static get watchers() { return {
|
@@ -15874,6 +15884,9 @@ class RadioGroup {
|
|
15874
15884
|
this.selectedChild = index;
|
15875
15885
|
this.checkedValue = radioOption.value;
|
15876
15886
|
}
|
15887
|
+
if (this.disabled) {
|
15888
|
+
radioOption.disabled = true;
|
15889
|
+
}
|
15877
15890
|
});
|
15878
15891
|
this.setFirstRadioOptionTabIndex(this.selectedChild > 0 ? -1 : 0);
|
15879
15892
|
if (this.initialOrientation === this.RADIO_HORIZONTAL &&
|
@@ -15902,6 +15915,9 @@ class RadioGroup {
|
|
15902
15915
|
this.validationStatus = "";
|
15903
15916
|
this.validationText = "";
|
15904
15917
|
}
|
15918
|
+
watchDisabledHandler(newValue) {
|
15919
|
+
this.radioOptions.forEach((radioOption) => (radioOption.disabled = newValue));
|
15920
|
+
}
|
15905
15921
|
orientationChangeHandler() {
|
15906
15922
|
this.initialOrientation = this.orientation;
|
15907
15923
|
this.checkOrientation();
|
@@ -15995,6 +16011,7 @@ class RadioGroup {
|
|
15995
16011
|
}
|
15996
16012
|
get el() { return getElement(this); }
|
15997
16013
|
static get watchers() { return {
|
16014
|
+
"disabled": ["watchDisabledHandler"],
|
15998
16015
|
"orientation": ["orientationChangeHandler"]
|
15999
16016
|
}; }
|
16000
16017
|
static get style() { return icRadioGroupCss; }
|
@@ -19200,6 +19217,7 @@ class TextField {
|
|
19200
19217
|
this.max = undefined;
|
19201
19218
|
this.maxCharacters = 0;
|
19202
19219
|
this.maxLength = 0;
|
19220
|
+
this.maxLengthMessage = "Maximum length exceeded";
|
19203
19221
|
this.min = undefined;
|
19204
19222
|
this.minCharacters = 0;
|
19205
19223
|
this.name = this.inputId;
|
@@ -19291,7 +19309,7 @@ class TextField {
|
|
19291
19309
|
: IcInformationStatus.Error
|
19292
19310
|
: validationStatus;
|
19293
19311
|
const currentValidationText = maxLengthExceeded
|
19294
|
-
?
|
19312
|
+
? this.maxLengthMessage
|
19295
19313
|
: maxCharactersError
|
19296
19314
|
? `Maximum input is ${maxCharacters} characters`
|
19297
19315
|
: maxValueExceeded
|
@@ -19379,6 +19397,7 @@ class TextField {
|
|
19379
19397
|
"max": [8],
|
19380
19398
|
"maxCharacters": [2, "max-characters"],
|
19381
19399
|
"maxLength": [2, "max-length"],
|
19400
|
+
"maxLengthMessage": [1, "max-length-message"],
|
19382
19401
|
"min": [8],
|
19383
19402
|
"minCharacters": [2, "min-characters"],
|
19384
19403
|
"name": [1],
|
@@ -19467,7 +19486,7 @@ class Theme {
|
|
19467
19486
|
}; }
|
19468
19487
|
}
|
19469
19488
|
|
19470
|
-
const icToastCss = "/*!@html*/html.sc-ic-toast{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-toast{margin:0}/*!@main*/main.sc-ic-toast{display:block}/*!@h1*/h1.sc-ic-toast{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-toast{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-toast{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-toast{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-toast{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-toast,strong.sc-ic-toast{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-toast,kbd.sc-ic-toast,samp.sc-ic-toast{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-toast{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-toast,sup.sc-ic-toast{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-toast{bottom:-0.25em}/*!@sup*/sup.sc-ic-toast{top:-0.5em}/*!@img*/img.sc-ic-toast{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-toast,input.sc-ic-toast,optgroup.sc-ic-toast,select.sc-ic-toast,textarea.sc-ic-toast{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-toast,input.sc-ic-toast{overflow:visible}/*!@button,\nselect*/button.sc-ic-toast,select.sc-ic-toast{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-toast,[type=\"button\"].sc-ic-toast,[type=\"reset\"].sc-ic-toast,[type=\"submit\"].sc-ic-toast{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-toast::-moz-focus-inner,[type=\"button\"].sc-ic-toast::-moz-focus-inner,[type=\"reset\"].sc-ic-toast::-moz-focus-inner,[type=\"submit\"].sc-ic-toast::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-toast:-moz-focusring,[type=\"button\"].sc-ic-toast:-moz-focusring,[type=\"reset\"].sc-ic-toast:-moz-focusring,[type=\"submit\"].sc-ic-toast:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-toast{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-toast{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-toast{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-toast{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-toast,[type=\"radio\"].sc-ic-toast{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-toast::-webkit-inner-spin-button,[type=\"number\"].sc-ic-toast::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-toast{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-toast::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-toast::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-toast{display:block}/*!@summary*/summary.sc-ic-toast{display:list-item}/*!@template*/template.sc-ic-toast{display:none}/*!@[hidden]*/[hidden].sc-ic-toast{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-toast,body.sc-ic-toast,div.sc-ic-toast,span.sc-ic-toast,applet.sc-ic-toast,object.sc-ic-toast,iframe.sc-ic-toast,h1.sc-ic-toast,h2.sc-ic-toast,h3.sc-ic-toast,h4.sc-ic-toast,h5.sc-ic-toast,h6.sc-ic-toast,p.sc-ic-toast,blockquote.sc-ic-toast,pre.sc-ic-toast,a.sc-ic-toast,abbr.sc-ic-toast,acronym.sc-ic-toast,address.sc-ic-toast,big.sc-ic-toast,cite.sc-ic-toast,code.sc-ic-toast,del.sc-ic-toast,dfn.sc-ic-toast,em.sc-ic-toast,img.sc-ic-toast,ins.sc-ic-toast,kbd.sc-ic-toast,q.sc-ic-toast,s.sc-ic-toast,samp.sc-ic-toast,small.sc-ic-toast,strike.sc-ic-toast,strong.sc-ic-toast,sub.sc-ic-toast,sup.sc-ic-toast,tt.sc-ic-toast,var.sc-ic-toast,b.sc-ic-toast,u.sc-ic-toast,i.sc-ic-toast,center.sc-ic-toast,dl.sc-ic-toast,dt.sc-ic-toast,dd.sc-ic-toast,ol.sc-ic-toast,ul.sc-ic-toast,li.sc-ic-toast,fieldset.sc-ic-toast,form.sc-ic-toast,label.sc-ic-toast,legend.sc-ic-toast,table.sc-ic-toast,caption.sc-ic-toast,tbody.sc-ic-toast,tfoot.sc-ic-toast,thead.sc-ic-toast,tr.sc-ic-toast,th.sc-ic-toast,td.sc-ic-toast,article.sc-ic-toast,aside.sc-ic-toast,canvas.sc-ic-toast,details.sc-ic-toast,embed.sc-ic-toast,figure.sc-ic-toast,figcaption.sc-ic-toast,footer.sc-ic-toast,header.sc-ic-toast,hgroup.sc-ic-toast,menu.sc-ic-toast,nav.sc-ic-toast,output.sc-ic-toast,ruby.sc-ic-toast,section.sc-ic-toast,summary.sc-ic-toast,time.sc-ic-toast,mark.sc-ic-toast,audio.sc-ic-toast,video.sc-ic-toast{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}/*!@:host*/.sc-ic-toast-h{--bottom-position:var(--ic-space-xl);position:fixed;bottom:var(--bottom-position);left:50%;transform:translate(-50%);
|
19489
|
+
const icToastCss = "/*!@html*/html.sc-ic-toast{line-height:1.15;-webkit-text-size-adjust:100%}/*!@body*/body.sc-ic-toast{margin:0}/*!@main*/main.sc-ic-toast{display:block}/*!@h1*/h1.sc-ic-toast{font-size:2em;margin:0.67em 0}/*!@hr*/hr.sc-ic-toast{box-sizing:content-box;height:0;overflow:visible}/*!@pre*/pre.sc-ic-toast{font-family:monospace, monospace;font-size:1em}/*!@a*/a.sc-ic-toast{background-color:transparent}/*!@abbr[title]*/abbr[title].sc-ic-toast{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}/*!@b,\nstrong*/b.sc-ic-toast,strong.sc-ic-toast{font-weight:bolder}/*!@code,\nkbd,\nsamp*/code.sc-ic-toast,kbd.sc-ic-toast,samp.sc-ic-toast{font-family:monospace, monospace;font-size:1em}/*!@small*/small.sc-ic-toast{font-size:80%}/*!@sub,\nsup*/sub.sc-ic-toast,sup.sc-ic-toast{font-size:75%;line-height:0;position:relative;vertical-align:baseline}/*!@sub*/sub.sc-ic-toast{bottom:-0.25em}/*!@sup*/sup.sc-ic-toast{top:-0.5em}/*!@img*/img.sc-ic-toast{border-style:none}/*!@button,\ninput,\noptgroup,\nselect,\ntextarea*/button.sc-ic-toast,input.sc-ic-toast,optgroup.sc-ic-toast,select.sc-ic-toast,textarea.sc-ic-toast{font-family:inherit;font-size:100%;line-height:1.15;margin:0}/*!@button,\ninput*/button.sc-ic-toast,input.sc-ic-toast{overflow:visible}/*!@button,\nselect*/button.sc-ic-toast,select.sc-ic-toast{text-transform:none}/*!@button,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"]*/button.sc-ic-toast,[type=\"button\"].sc-ic-toast,[type=\"reset\"].sc-ic-toast,[type=\"submit\"].sc-ic-toast{-webkit-appearance:button}/*!@button::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner*/button.sc-ic-toast::-moz-focus-inner,[type=\"button\"].sc-ic-toast::-moz-focus-inner,[type=\"reset\"].sc-ic-toast::-moz-focus-inner,[type=\"submit\"].sc-ic-toast::-moz-focus-inner{border-style:none;padding:0}/*!@button:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring*/button.sc-ic-toast:-moz-focusring,[type=\"button\"].sc-ic-toast:-moz-focusring,[type=\"reset\"].sc-ic-toast:-moz-focusring,[type=\"submit\"].sc-ic-toast:-moz-focusring{outline:1px dotted ButtonText}/*!@fieldset*/fieldset.sc-ic-toast{padding:0.35em 0.75em 0.625em}/*!@legend*/legend.sc-ic-toast{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}/*!@progress*/progress.sc-ic-toast{vertical-align:baseline}/*!@textarea*/textarea.sc-ic-toast{overflow:auto}/*!@[type=\"checkbox\"],\n[type=\"radio\"]*/[type=\"checkbox\"].sc-ic-toast,[type=\"radio\"].sc-ic-toast{box-sizing:border-box;padding:0}/*!@[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button*/[type=\"number\"].sc-ic-toast::-webkit-inner-spin-button,[type=\"number\"].sc-ic-toast::-webkit-outer-spin-button{height:auto}/*!@[type=\"search\"]*/[type=\"search\"].sc-ic-toast{-webkit-appearance:textfield;outline-offset:-2px}/*!@[type=\"search\"]::-webkit-search-decoration*/[type=\"search\"].sc-ic-toast::-webkit-search-decoration{-webkit-appearance:none}/*!@::-webkit-file-upload-button*/.sc-ic-toast::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}/*!@details*/details.sc-ic-toast{display:block}/*!@summary*/summary.sc-ic-toast{display:list-item}/*!@template*/template.sc-ic-toast{display:none}/*!@[hidden]*/[hidden].sc-ic-toast{display:none}/*!@html,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo*/html.sc-ic-toast,body.sc-ic-toast,div.sc-ic-toast,span.sc-ic-toast,applet.sc-ic-toast,object.sc-ic-toast,iframe.sc-ic-toast,h1.sc-ic-toast,h2.sc-ic-toast,h3.sc-ic-toast,h4.sc-ic-toast,h5.sc-ic-toast,h6.sc-ic-toast,p.sc-ic-toast,blockquote.sc-ic-toast,pre.sc-ic-toast,a.sc-ic-toast,abbr.sc-ic-toast,acronym.sc-ic-toast,address.sc-ic-toast,big.sc-ic-toast,cite.sc-ic-toast,code.sc-ic-toast,del.sc-ic-toast,dfn.sc-ic-toast,em.sc-ic-toast,img.sc-ic-toast,ins.sc-ic-toast,kbd.sc-ic-toast,q.sc-ic-toast,s.sc-ic-toast,samp.sc-ic-toast,small.sc-ic-toast,strike.sc-ic-toast,strong.sc-ic-toast,sub.sc-ic-toast,sup.sc-ic-toast,tt.sc-ic-toast,var.sc-ic-toast,b.sc-ic-toast,u.sc-ic-toast,i.sc-ic-toast,center.sc-ic-toast,dl.sc-ic-toast,dt.sc-ic-toast,dd.sc-ic-toast,ol.sc-ic-toast,ul.sc-ic-toast,li.sc-ic-toast,fieldset.sc-ic-toast,form.sc-ic-toast,label.sc-ic-toast,legend.sc-ic-toast,table.sc-ic-toast,caption.sc-ic-toast,tbody.sc-ic-toast,tfoot.sc-ic-toast,thead.sc-ic-toast,tr.sc-ic-toast,th.sc-ic-toast,td.sc-ic-toast,article.sc-ic-toast,aside.sc-ic-toast,canvas.sc-ic-toast,details.sc-ic-toast,embed.sc-ic-toast,figure.sc-ic-toast,figcaption.sc-ic-toast,footer.sc-ic-toast,header.sc-ic-toast,hgroup.sc-ic-toast,menu.sc-ic-toast,nav.sc-ic-toast,output.sc-ic-toast,ruby.sc-ic-toast,section.sc-ic-toast,summary.sc-ic-toast,time.sc-ic-toast,mark.sc-ic-toast,audio.sc-ic-toast,video.sc-ic-toast{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}@media (prefers-reduced-motion: no-preference){/*!@:host*/.sc-ic-toast-h{animation:fadein var(--ic-transition-duration-slow) ease-in-out}/*!@:host(.hidden)*/.hidden.sc-ic-toast-h{animation:fadeout var(--ic-transition-duration-slow) ease-in-out}}/*!@:host*/.sc-ic-toast-h{--bottom-position:var(--ic-space-xl);position:fixed;bottom:var(--bottom-position);left:50%;transform:translate(-50%);z-index:var(--ic-z-index-toast)}/*!@:host(.hidden)*/.hidden.sc-ic-toast-h{display:none}/*!@.container*/.container.sc-ic-toast{max-width:32.5rem;min-width:18rem;box-shadow:var(--ic-elevation-overlay);min-height:3.5rem;background-color:var(--ic-architectural-800);color:var(--ic-color-white-text);display:flex;align-items:center;position:relative;border-radius:var(--ic-border-radius)}/*!@.toast-icon-container*/.toast-icon-container.sc-ic-toast{height:100%;display:flex;align-items:center}/*!@.divider*/.divider.sc-ic-toast{height:100%;width:var(--ic-space-xs);position:absolute;border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs)}/*!@.divider-neutral*/.divider-neutral.sc-ic-toast{background-color:var(--ic-status-unknown)}/*!@.divider-info*/.divider-info.sc-ic-toast{background-color:var(--ic-status-info-contrast)}/*!@.divider-warning*/.divider-warning.sc-ic-toast{background-color:var(--ic-status-warning-contrast)}/*!@.divider-error*/.divider-error.sc-ic-toast{background-color:var(--ic-status-error-contrast)}/*!@.divider-success*/.divider-success.sc-ic-toast{background-color:var(--ic-status-success-contrast)}/*!@.toast-icon,\n::slotted(svg)*/.toast-icon.sc-ic-toast,.sc-ic-toast-s>svg{height:var(--ic-space-lg);width:var(--ic-space-lg);margin-left:var(--ic-space-md)}/*!@:host([variant=\"neutral\"]) .toast-icon svg,\n::slotted(svg)*/[variant=\"neutral\"].sc-ic-toast-h .toast-icon.sc-ic-toast svg.sc-ic-toast,.sc-ic-toast-s>svg{fill:var(--ic-status-unknown)}/*!@:host([variant=\"info\"]) .toast-icon svg*/[variant=\"info\"].sc-ic-toast-h .toast-icon.sc-ic-toast svg.sc-ic-toast{fill:var(--ic-status-info-contrast)}/*!@:host([variant=\"warning\"]) .toast-icon svg*/[variant=\"warning\"].sc-ic-toast-h .toast-icon.sc-ic-toast svg.sc-ic-toast{fill:var(--ic-status-warning-contrast)}/*!@:host([variant=\"error\"]) .toast-icon svg*/[variant=\"error\"].sc-ic-toast-h .toast-icon.sc-ic-toast svg.sc-ic-toast{fill:var(--ic-status-error-contrast)}/*!@:host([variant=\"success\"]) .toast-icon svg*/[variant=\"success\"].sc-ic-toast-h .toast-icon.sc-ic-toast svg.sc-ic-toast{fill:var(--ic-status-success-contrast)}/*!@.toast-content*/.toast-content.sc-ic-toast{margin-left:var(--ic-space-xs);width:100%}/*!@.no-icon*/.no-icon.sc-ic-toast{margin-left:var(--ic-space-md)}/*!@.toast-message*/.toast-message.sc-ic-toast{padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0}/*!@.toast-action-container*/.toast-action-container.sc-ic-toast{padding-bottom:var(--ic-space-md)}/*!@ic-button,\n.toast-dismiss-timer*/ic-button.sc-ic-toast,.toast-dismiss-timer.sc-ic-toast{padding:var(--ic-space-xs)}@media (max-width: 576px){/*!@:host*/.sc-ic-toast-h{--bottom-position:var(--ic-space-lg);width:calc(100% - 2 * var(--ic-space-md))}}@media (min-width: 993px){/*!@:host*/.sc-ic-toast-h{--bottom-position:calc(var(--ic-space-xl) + var(--ic-space-xs))}}@media (forced-colors: active){/*!@.container*/.container.sc-ic-toast{border:var(--ic-hc-border)}}@keyframes fadein{from{bottom:0;opacity:0}to{bottom:var(--bottom-position);opacity:1}}@keyframes fadeout{from{bottom:var(--bottom-position);opacity:1}to{bottom:0;opacity:0}}";
|
19471
19490
|
|
19472
19491
|
const AUTO_DISMISS_TIMER_REFRESH_RATE_MS = 1000;
|
19473
19492
|
const TOAST_HEADING_CHAR_LIMIT = 70;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ukic/web-components",
|
3
|
-
"version": "2.
|
3
|
+
"version": "2.28.0",
|
4
4
|
"description": "A web component UI library compiled with StencilJS",
|
5
5
|
"author": "mi6",
|
6
6
|
"bugs": {
|
@@ -96,5 +96,5 @@
|
|
96
96
|
"webpack": "^5.76.0"
|
97
97
|
},
|
98
98
|
"license": "MIT",
|
99
|
-
"gitHead": "
|
99
|
+
"gitHead": "9c268801ebc8da41901291fe13ff157a6211fbbd"
|
100
100
|
}
|
package/vscode-data.json
CHANGED
@@ -119,6 +119,10 @@
|
|
119
119
|
"name": "message",
|
120
120
|
"description": "The main body message of the alert."
|
121
121
|
},
|
122
|
+
{
|
123
|
+
"name": "show-default-icon",
|
124
|
+
"description": "If `true`, the default icon for the neutral variant will be appear on the left of the alert."
|
125
|
+
},
|
122
126
|
{
|
123
127
|
"name": "title-above",
|
124
128
|
"description": "If `true`, the title and message will appear above and below instead of inline."
|
@@ -1003,7 +1007,7 @@
|
|
1003
1007
|
},
|
1004
1008
|
{
|
1005
1009
|
"name": "close-on-backdrop-click",
|
1006
|
-
"description": "If set to `
|
1010
|
+
"description": "If set to `false`, the dialog will not close when the backdrop is clicked."
|
1007
1011
|
},
|
1008
1012
|
{
|
1009
1013
|
"name": "destructive",
|
@@ -3634,6 +3638,10 @@
|
|
3634
3638
|
"name": "max-length",
|
3635
3639
|
"description": "The count of characters in the field. Will display a warning if the bound is reached."
|
3636
3640
|
},
|
3641
|
+
{
|
3642
|
+
"name": "max-length-message",
|
3643
|
+
"description": "The text to display as the validation message when the maximum length is exceeded."
|
3644
|
+
},
|
3637
3645
|
{
|
3638
3646
|
"name": "min",
|
3639
3647
|
"description": "The minimum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of min value in `helperText` or `label`)"
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"names":["icTextFieldCss","inputIds","MUTABLE_ATTRIBUTES","IC_INHERITED_ARIA","TextField","this","inheritedAttributes","hostMutationObserver","getMaxLengthExceeded","value","numChars","length","type","minValueUnattained","Number","min","maxValueExceeded","max","maxLength","maxLengthExceeded","getMaxCharactersReached","maxCharactersReached","maxCharacters","maxCharactersError","onInput","ev","target","icInput","emit","onBlur","minCharactersUnattained","minCharacters","icBlur","onFocus","icFocus","hasStatus","status","disabled","handleFormReset","initialValue","hostMutationCallback","mutationList","forceComponentUpdate","forEach","attributeName","addedNodes","removedNodes","includes","el","getAttribute","checkSlotInChildMutations","forceUpdate","undefined","inputId","debounceChanged","icChange","debounceEvent","debounce","watchValueHandler","newValue","inputEl","connectedCallback","disconnectedCallback","removeFormResetListener","_a","disconnect","componentWillLoad","inheritAttributes","readonly","addFormResetListener","removeDisabledFalse","componentDidLoad","onComponentRequiredPropUndefined","prop","label","propName","validationInlineInternal","getValidationText","validationText","MutationObserver","observe","attributes","childList","handleKeyDown","icKeydown","event","setFocus","focus","render","name","required","size","small","placeholder","helperText","rows","resize","validationStatus","validationInline","spellcheck","inputmode","fullWidth","truncateValue","hiddenInput","disabledMode","currentStatus","IcInformationStatus","Warning","Error","currentValidationText","maxNumChars","messageAriaLive","showStatusText","Success","multiline","hiddenCharCountDescId","describedBy","getInputDescribedByText","trim","disabledText","showLeftIcon","querySelector","invalid","renderHiddenInput","h","Host","class","hideLabel","for","multiLine","slot","Object","assign","id","ref","ariaActiveDescendant","ariaExpanded","ariaOwns","autocomplete","autocapitalize","autoFocus","role","maxlength","minlength","isSlotUsed","isEmptyString","message","ariaLiveMode","variant","hidden"],"sources":["src/components/ic-text-field/ic-text-field.css?tag=ic-text-field&encapsulation=shadow","src/components/ic-text-field/ic-text-field.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n:host {\n /**\n * @prop --input-width: Width of the input field\n */\n display: block;\n}\n\n:host(.fullwidth) {\n width: 100%;\n}\n\n::placeholder {\n color: var(--ic-color-tertiary-text);\n opacity: 1;\n}\n\ninput,\ntextarea {\n border: 0;\n border-radius: var(--ic-border-radius);\n background-color: var(--ic-architectural-white);\n line-height: 1.5rem;\n letter-spacing: 0.005rem;\n width: 100%;\n padding-right: var(--ic-space-xs);\n padding-left: var(--ic-space-xs);\n}\n\ntextarea {\n min-height: var(--ic-space-lg);\n resize: vertical;\n padding-top: 0.375rem;\n}\n\ninput:focus,\ntextarea:focus {\n border: 0;\n outline: 0;\n}\n\ninput:disabled,\ntextarea:disabled {\n color: var(--ic-architectural-200);\n}\n\ninput.readonly,\ntextarea.readonly {\n color: var(--ic-color-primary-text);\n}\n\n/* Chrome, Safari, Edge */\ninput::-webkit-outer-spin-button,\ninput::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n/* Firefox */\ninput[type=\"number\"] {\n -moz-appearance: textfield;\n}\n\ntextarea.no-resize {\n resize: none;\n}\n\n.maxlengthtext {\n color: var(--ic-color-secondary-text);\n padding-right: var(--ic-space-xxxs);\n}\n\n.no-left-pad {\n padding-left: 0;\n}\n\n::slotted([slot=\"icon\"]) {\n fill: var(--ic-color-tertiary-text);\n}\n\n.has-value ::slotted([slot=\"icon\"]) {\n fill: var(--ic-color-primary-text);\n}\n\n.charcount {\n margin-right: calc(-1 * var(--ic-space-xxxs));\n}\n\ninput[type=\"search\"]::-webkit-search-cancel-button,\ninput[type=\"search\"]::-webkit-search-decoration,\ninput[type=\"search\"]::-webkit-search-results-button,\ninput[type=\"search\"]::-webkit-search-results-decoration {\n display: none;\n}\n\ninput[type=\"search\"].truncate-value {\n width: 100%;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n@media (forced-colors: active) {\n input.readonly,\n textarea.readonly {\n color: canvastext;\n }\n\n .has-value ::slotted([slot=\"icon\"]) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n Method,\n h,\n forceUpdate,\n} from \"@stencil/core\";\nimport {\n IcInformationStatus,\n IcAutocompleteTypes,\n IcAutocorrectStates,\n IcInformationStatusOrEmpty,\n IcValueEventDetail,\n IcSizesNoLarge,\n} from \"../../utils/types\";\nimport {\n inheritAttributes,\n debounceEvent,\n getInputDescribedByText,\n renderHiddenInput,\n isEmptyString,\n onComponentRequiredPropUndefined,\n addFormResetListener,\n removeFormResetListener,\n isSlotUsed,\n removeDisabledFalse,\n checkSlotInChildMutations,\n} from \"../../utils/helpers\";\nimport { IC_INHERITED_ARIA } from \"../../utils/constants\";\nimport {\n IcAriaAutocompleteTypes,\n IcTextFieldInputModes,\n IcTextFieldTypes,\n} from \"./ic-text-field.types\";\n\nlet inputIds = 0;\nconst MUTABLE_ATTRIBUTES = [...IC_INHERITED_ARIA, \"title\"];\n\n/**\n * @slot icon - Content will be placed to the left of the text input.\n */\n@Component({\n tag: \"ic-text-field\",\n styleUrl: \"ic-text-field.css\",\n shadow: true,\n})\nexport class TextField {\n private inheritedAttributes: { [k: string]: string } = {};\n private inputEl: HTMLInputElement | HTMLTextAreaElement;\n private hostMutationObserver: MutationObserver = null;\n\n @Element() el: HTMLIcTextFieldElement;\n\n @State() numChars: number = 0;\n @State() maxCharactersReached: boolean = false;\n @State() maxCharactersError: boolean = false;\n @State() minCharactersUnattained: boolean = false;\n @State() maxLengthExceeded: boolean = false;\n @State() maxValueExceeded: boolean = false;\n @State() minValueUnattained: boolean = false;\n\n /**\n * @slot clear-button - an ic-button clear component will render as an end adornment to the input.\n * @slot search-submit-button - an ic-button search submit component will render as an end adornment to the input.\n * @slot menu - an ic-menu component will appear below the input.\n */\n\n /**\n * @internal The active element when focus is on the ic-menu items.\n */\n @Prop() ariaActiveDescendant?: string;\n\n /**\n * @internal Used to identify whether inputting any text triggers more predictions\n */\n @Prop() ariaAutocomplete: IcAriaAutocompleteTypes = undefined;\n\n /**\n * @internal Used to identify if the slotted menu is rendered\n */\n @Prop() ariaExpanded: string;\n\n /**\n * @internal Used to identify any related child component\n */\n @Prop() ariaOwns: string;\n\n /**\n * The automatic capitalisation of the text value as it is entered/edited by the user.\n * Available options: \"off\", \"none\", \"on\", \"sentences\", \"words\", \"characters\".\n */\n @Prop() autocapitalize = \"off\";\n\n /**\n * The state of autocompletion the browser can apply on the text value.\n */\n @Prop() autocomplete: IcAutocompleteTypes = \"off\";\n\n /**\n * The state of autocorrection the browser can apply when the user is entering/editing the text value.\n */\n @Prop() autocorrect: IcAutocorrectStates = \"off\";\n\n /**\n * If `true`, the form control will have input focus when the page loads.\n */\n @Prop() autoFocus = false;\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop() disabled: boolean = false;\n\n /**\n * Specify whether the text field fills the full width of the container.\n * If `true`, this overrides the --input-width CSS variable.\n */\n @Prop() fullWidth: boolean = false;\n\n /**\n * The helper text that will be displayed for additional field guidance.\n */\n @Prop() helperText: string = \"\";\n\n /**\n * If `true`, the label will be hidden and the required label value will be applied as an aria-label.\n */\n @Prop() hideLabel: boolean = false;\n\n /**\n * @internal If `true`, the hidden form input will stop rendering for form submission.\n */\n @Prop() hiddenInput: boolean = true;\n\n /**\n * The ID for the input.\n */\n @Prop() inputId?: string = `ic-text-field-input-${inputIds++}`;\n\n /**\n * A hint to the browser for which keyboard to display.\n * Possible values: `\"none\"`, `\"text\"`, `\"tel\"`, `\"url\"`,\n * `\"email\"`, `\"numeric\"`, `\"decimal\"`, and `\"search\"`.\n */\n @Prop() inputmode: IcTextFieldInputModes = \"text\";\n\n /**\n * The label for the input.\n */\n @Prop() label!: string;\n\n /**\n * The maximum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of max value in `helperText` or `label`)\n */\n @Prop() max: string | number = undefined;\n\n /**\n * The maximum number of characters that can be entered in the field. Will display an error if too many characters are entered.\n */\n @Prop() maxCharacters: number = 0;\n\n /**\n * The count of characters in the field. Will display a warning if the bound is reached.\n */\n @Prop() maxLength: number = 0;\n\n /**\n * The minimum number that can be accepted as a value, when `type` is `number` and `rows` is `1`. (NOTE: Ensure to include visual indication of min value in `helperText` or `label`)\n */\n @Prop() min: string | number = undefined;\n\n /**\n * The minimum number of characters that can be entered in the field.\n */\n @Prop() minCharacters: number = 0;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n /**\n * The placeholder value to be displayed.\n */\n @Prop() placeholder: string = \"\";\n\n /**\n * If `true`, the read only state will be set.\n */\n @Prop({ reflect: true }) readonly: boolean = false;\n\n /**\n * If `true`, the input will require a value.\n */\n @Prop() required: boolean = false;\n\n /**\n * If `true`, the multiline text area will be resizeable.\n */\n @Prop() resize: boolean = false;\n\n /**\n * @internal Used to set the role if not default textbox;\n */\n @Prop() role: string;\n\n /**\n * The number of rows to transform the text field into a text area with a specific height.\n */\n @Prop() rows: number = 1;\n\n /**\n * The size of the text field component.\n */\n @Prop() size?: IcSizesNoLarge = \"default\";\n\n /**\n * @deprecated This prop should not be used anymore. Set prop `size` to \"small\" instead.\n */\n @Prop() small?: boolean = false;\n\n /**\n * If `true`, the value of the text field will have its spelling and grammar checked.\n */\n @Prop() spellcheck: boolean = false;\n /**\n * @internal If `true`, an ellipsis will be displayed at the end of the value if the value is longer than the container.\n */\n @Prop() truncateValue?: boolean;\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: IcTextFieldTypes = \"text\";\n\n /**\n * If `true`, the icon in input control will be displayed - only applies when validationStatus ='success'.\n */\n @Prop() validationInline: boolean = false;\n\n /**\n * @internal If `true`, the validation will display inline.\n */\n @Prop() validationInlineInternal: boolean = false;\n\n /**\n * The validation state - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationStatus: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The validation state - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationText: string = \"\";\n\n /**\n * The amount of time, in milliseconds, to wait to trigger the `icChange` event after each keystroke.\n */\n @Prop() debounce: number = 0;\n\n @Watch(\"debounce\")\n private debounceChanged() {\n this.icChange = debounceEvent(this.icChange, this.debounce);\n }\n\n /**\n * The value of the text field.\n */\n @Prop({ reflect: true, mutable: true }) value: string = \"\";\n @State() initialValue = this.value;\n\n @Watch(\"value\")\n private watchValueHandler(newValue: string): void {\n if (this.inputEl && this.inputEl.value !== newValue) {\n this.inputEl.value = newValue;\n }\n\n this.getMaxLengthExceeded(newValue);\n\n this.getMaxCharactersReached(newValue);\n\n this.icChange.emit({ value: newValue });\n }\n\n /**\n * @internal Emitted when the validationInlineInternal is `true`\n */\n @Event() getValidationText: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when input loses focus.\n */\n @Event() icBlur: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when the value has changed.\n */\n @Event() icChange: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when input gains focus.\n */\n @Event() icFocus: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when a keyboard input occurred.\n */\n @Event() icInput: EventEmitter<IcValueEventDetail>;\n\n /**\n * Emitted when a keydown event occurred.\n */\n @Event() icKeydown: EventEmitter<{ event: KeyboardEvent }>;\n\n connectedCallback(): void {\n this.debounceChanged();\n }\n\n disconnectedCallback(): void {\n removeFormResetListener(this.el, this.handleFormReset);\n this.hostMutationObserver?.disconnect();\n }\n\n componentWillLoad(): void {\n if (this.value !== this.initialValue) {\n this.watchValueHandler(this.value);\n }\n\n this.getMaxLengthExceeded(this.value);\n\n this.getMaxCharactersReached(this.value);\n\n this.inheritedAttributes = inheritAttributes(this.el, MUTABLE_ATTRIBUTES);\n\n if (this.readonly) {\n this.maxLengthExceeded = false;\n this.maxValueExceeded = false;\n this.minValueUnattained = false;\n }\n\n addFormResetListener(this.el, this.handleFormReset);\n\n removeDisabledFalse(this.disabled, this.el);\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Text Field\"\n );\n if (this.validationInlineInternal) {\n this.getValidationText.emit({ value: this.validationText });\n }\n\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n attributes: true,\n childList: true,\n });\n }\n\n @Listen(\"keydown\", {})\n handleKeyDown(ev: KeyboardEvent): void {\n this.icKeydown.emit({ event: ev });\n this.maxCharactersError = this.maxCharactersReached;\n }\n\n /**\n * Sets focus on the native `input`.\n */\n\n @Method()\n async setFocus(): Promise<void> {\n this.inputEl?.focus();\n }\n\n private getMaxLengthExceeded = (value: string) => {\n this.numChars = value.length;\n\n if (this.type === \"number\") {\n this.minValueUnattained = value && Number(value) < Number(this.min);\n this.maxValueExceeded = Number(value) > Number(this.max);\n }\n\n if (this.maxLength > 0) {\n this.maxLengthExceeded = this.numChars > this.maxLength;\n }\n };\n\n private getMaxCharactersReached = (value: string) => {\n this.numChars = value.length;\n this.maxCharactersReached =\n this.maxCharacters > 0 ? this.numChars >= this.maxCharacters : false;\n\n if (this.maxCharactersError && !this.maxCharactersReached) {\n this.maxCharactersError = false;\n }\n };\n\n private onInput = (ev: Event) => {\n this.value = (ev.target as HTMLInputElement).value;\n this.icInput.emit({ value: this.value });\n };\n\n private onBlur = (ev: Event) => {\n const value = (ev.target as HTMLInputElement).value;\n this.numChars = value.length;\n this.minCharactersUnattained =\n this.minCharacters > 0 ? this.numChars < this.minCharacters : false;\n this.icBlur.emit({ value: value });\n };\n\n private onFocus = (ev: Event) => {\n this.icFocus.emit({ value: (ev.target as HTMLInputElement).value });\n };\n\n private hasStatus = (status: IcInformationStatusOrEmpty) =>\n status !== \"\" && !this.disabled;\n\n private handleFormReset = (): void => {\n this.value = this.initialValue;\n };\n\n // triggered when attributes of host element change\n private hostMutationCallback = (mutationList: MutationRecord[]): void => {\n let forceComponentUpdate = false;\n mutationList.forEach(\n ({ attributeName, type, addedNodes, removedNodes }) => {\n if (MUTABLE_ATTRIBUTES.includes(attributeName)) {\n this.inheritedAttributes[attributeName] =\n this.el.getAttribute(attributeName);\n forceComponentUpdate = true;\n } else if (type === \"childList\") {\n forceComponentUpdate = checkSlotInChildMutations(\n addedNodes,\n removedNodes,\n \"icon\"\n );\n }\n }\n );\n if (forceComponentUpdate) {\n forceUpdate(this);\n }\n };\n\n render() {\n const {\n inputId,\n name,\n label,\n required,\n size,\n small,\n placeholder,\n helperText,\n rows,\n resize,\n disabled,\n value,\n min,\n max,\n maxLength,\n numChars,\n readonly,\n maxLengthExceeded,\n maxCharacters,\n maxCharactersError,\n maxCharactersReached,\n minCharacters,\n minCharactersUnattained,\n minValueUnattained,\n maxValueExceeded,\n validationStatus,\n validationText,\n validationInline,\n validationInlineInternal,\n spellcheck,\n inputmode,\n fullWidth,\n truncateValue,\n hiddenInput,\n } = this;\n\n const disabledMode = readonly ? true : disabled;\n\n const currentStatus =\n maxLengthExceeded ||\n maxValueExceeded ||\n minValueUnattained ||\n minCharactersUnattained ||\n maxCharactersError\n ? maxCharactersError\n ? IcInformationStatus.Warning\n : IcInformationStatus.Error\n : validationStatus;\n\n const currentValidationText = maxLengthExceeded\n ? \"Maximum length exceeded\"\n : maxCharactersError\n ? `Maximum input is ${maxCharacters} characters`\n : maxValueExceeded\n ? `Maximum value of ${max} exceeded`\n : minValueUnattained\n ? `Minimum value of ${min} not met`\n : minCharactersUnattained\n ? `Minimum input is ${minCharacters} characters`\n : validationText;\n\n const maxNumChars = readonly ? 0 : maxLength;\n const messageAriaLive =\n maxLengthExceeded ||\n maxCharactersError ||\n maxValueExceeded ||\n minValueUnattained ||\n (maxLength === 0 && currentStatus === IcInformationStatus.Error)\n ? \"assertive\"\n : \"polite\";\n\n const showStatusText =\n this.hasStatus(currentStatus) &&\n !(currentStatus == IcInformationStatus.Success && validationInline) &&\n !validationInlineInternal;\n\n const multiline = rows > 1;\n const hiddenCharCountDescId =\n maxLength > 0 ? `${inputId}-charcount-desc` : \"\";\n\n const describedBy = `${hiddenCharCountDescId} ${getInputDescribedByText(\n inputId,\n helperText !== \"\",\n showStatusText\n )}`.trim();\n\n const disabledText = disabledMode && !readonly;\n const showLeftIcon =\n !!this.el.querySelector(`[slot=\"icon\"]`) && !disabledText;\n\n const invalid = `${currentStatus === IcInformationStatus.Error}`;\n\n if (hiddenInput) {\n renderHiddenInput(true, this.el, name, value, disabledMode);\n }\n return (\n <Host class={{ [\"fullwidth\"]: fullWidth }}>\n <ic-input-container readonly={readonly} disabled={disabledMode}>\n {!this.hideLabel && (\n <ic-input-label\n for={inputId}\n label={label}\n helperText={helperText}\n required={required}\n disabled={disabledText}\n readonly={readonly}\n ></ic-input-label>\n )}\n\n <ic-input-component-container\n size={small ? \"small\" : size}\n validationStatus={currentStatus}\n multiLine={multiline}\n disabled={disabledMode}\n readonly={readonly}\n validationInline={validationInline}\n fullWidth={fullWidth}\n >\n {showLeftIcon && (\n <span\n class={{\n [\"readonly\"]: readonly,\n [\"has-value\"]: value.length > 0,\n }}\n slot=\"left-icon\"\n >\n <slot name=\"icon\" />\n </span>\n )}\n\n {!multiline ? (\n <input\n id={inputId}\n name={name}\n ref={(el) => (this.inputEl = el as HTMLInputElement)}\n type={this.type}\n min={min}\n max={max}\n value={value}\n class={{\n [\"no-left-pad\"]: !showLeftIcon && readonly,\n [\"readonly\"]: readonly,\n [\"truncate-value\"]: truncateValue,\n }}\n placeholder={placeholder ? placeholder : \"\"}\n required={required}\n disabled={disabledMode}\n readonly={readonly}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n aria-activedescendant={this.ariaActiveDescendant}\n aria-expanded={this.ariaExpanded}\n aria-owns={this.ariaOwns}\n autocomplete={this.autocomplete}\n autocapitalize={this.autocapitalize}\n autoFocus={this.autoFocus}\n spellcheck={spellcheck}\n inputmode={inputmode}\n role={this.role}\n maxlength={maxCharactersReached ? maxCharacters : null}\n minlength={minCharactersUnattained ? minCharacters : null}\n {...this.inheritedAttributes}\n ></input>\n ) : (\n <textarea\n id={inputId}\n class={{\n [\"no-resize\"]: resize === false || readonly,\n [\"no-left-pad\"]: !showLeftIcon && readonly,\n [\"readonly\"]: readonly,\n }}\n name={name}\n ref={(el) => (this.inputEl = el as HTMLTextAreaElement)}\n value={value}\n rows={rows}\n required={required}\n disabled={disabledMode}\n placeholder={placeholder ? placeholder : \"\"}\n readonly={readonly}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n autocapitalize={this.autocapitalize}\n autoFocus={this.autoFocus}\n spellcheck={spellcheck}\n inputmode={inputmode}\n maxlength={maxCharactersReached ? maxCharacters : null}\n minlength={minCharactersUnattained ? minCharacters : null}\n {...this.inheritedAttributes}\n ></textarea>\n )}\n {isSlotUsed(this.el, \"clear-button\") && (\n <slot name=\"clear-button\"></slot>\n )}\n {isSlotUsed(this.el, \"search-submit-button\") && (\n <slot name=\"search-submit-button\"></slot>\n )}\n </ic-input-component-container>\n {isSlotUsed(this.el, \"menu\") && <slot name=\"menu\"></slot>}\n {(!isEmptyString(validationStatus) ||\n !isEmptyString(validationText) ||\n maxNumChars > 0 ||\n maxValueExceeded ||\n maxCharactersError ||\n minCharactersUnattained ||\n minValueUnattained) &&\n !validationInlineInternal && (\n <ic-input-validation\n status={\n this.hasStatus(currentStatus) === false ||\n (currentStatus === IcInformationStatus.Success &&\n validationInline) ||\n validationInlineInternal\n ? \"\"\n : currentStatus\n }\n message={showStatusText ? currentValidationText : \"\"}\n ariaLiveMode={messageAriaLive}\n for={inputId}\n fullWidth={fullWidth}\n >\n {!readonly && maxNumChars > 0 && (\n <div slot=\"validation-message-adornment\">\n <ic-typography\n variant=\"caption\"\n class={{\n [\"maxlengthtext\"]: true,\n [\"error\"]: maxLengthExceeded,\n [\"disabled\"]: disabledText,\n }}\n >\n <span\n aria-live=\"polite\"\n id={`${inputId}-charcount`}\n class=\"charcount\"\n >\n {numChars}/{maxNumChars}\n </span>\n <span hidden={true} id={hiddenCharCountDescId}>\n Field can contain a maximum of {maxNumChars} characters.\n </span>\n </ic-typography>\n </div>\n )}\n </ic-input-validation>\n )}\n </ic-input-container>\n </Host>\n );\n }\n}\n"],"mappings":"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"}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{r as e,c as t,f as i,h as a,H as r,g as s}from"./p-6b5e91e2.js";import{c as n}from"./p-f074ef5b.js";import{j as o,V as l,i as c}from"./p-fef9e8c9.js";import{I as d}from"./p-26b7b18f.js";const u='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block}.container{min-height:3.5rem;border-radius:var(--ic-border-radius);position:relative;display:flex;align-items:center}.container-neutral{background-color:var(--ic-status-unknown-light)}.container-info{background-color:var(--ic-status-info-light)}.container-warning{background-color:var(--ic-status-warning-light)}.container-error{background-color:var(--ic-status-error-light)}.container-success{background-color:var(--ic-status-success-light)}.alert-icon-container{height:100%;display:flex;align-items:center}.divider{height:100%;width:var(--ic-space-xs);border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);position:absolute}.divider-neutral{background-color:var(--ic-status-unknown)}.divider-info{background-color:var(--ic-status-info)}.divider-warning{background-color:var(--ic-status-warning)}.divider-error{background-color:var(--ic-status-error)}.divider-success{background-color:var(--ic-status-success)}.alert-icon{height:var(--ic-space-lg);width:1.375rem;margin-left:1.125rem}.alert-icon>svg{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block}.icon-neutral>svg{fill:var(--ic-status-unknown)}:host([variant="info"]) .alert-icon svg{fill:var(--ic-status-info)}:host([variant="warning"]) .alert-icon svg{fill:var(--ic-status-warning)}:host([variant="error"]) .alert-icon svg{fill:var(--ic-status-error)}:host([variant="success"]) .alert-icon svg{fill:var(--ic-status-success)}.alert-content{display:flex;align-items:center;margin-left:0.625rem;width:100%}.alert-message{display:flex;align-items:center;padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;flex:1}.alert-message-title-above{display:inline}.alert-title{margin-right:var(--ic-space-xs)}.alert-title-above{white-space:normal}.alert-action-container{margin-right:var(--ic-space-xs);display:flex;align-items:center}.dismiss-icon{margin-right:var(--ic-space-xxxs);margin-left:-0.375rem;padding:0.375rem;border:none;border-radius:50%;background-color:inherit;display:flex;align-items:center;justify-content:center}.dismiss-icon:hover{cursor:pointer}@media (max-width: 628px){.alert-content{display:flex;flex-direction:column;align-items:flex-start}.alert-message{display:flex;flex-direction:column;align-items:flex-start}.alert-title{white-space:normal}.alert-action-container{margin-bottom:var(--ic-space-xs)}}@media (forced-colors: active){.container{border:var(--ic-hc-border)}}';const m=class{constructor(a){e(this,a);this.dismiss=t(this,"dismiss",7);this.icDismiss=t(this,"icDismiss",7);this.hostMutationObserver=null;this.dismissAction=()=>{this.dismiss.emit();this.icDismiss.emit()};this.hostMutationCallback=e=>{if(e.some((({type:e,addedNodes:t,removedNodes:i})=>e==="childList"?o(t,i,"action"):false))){i(this)}};this.alertTitleWrap=false;this.visible=true;this.announced=true;this.dismissible=false;this.heading="";this.message=undefined;this.titleAbove=false;this.variant="neutral"}disconnectedCallback(){var e;(e=this.hostMutationObserver)===null||e===void 0?void 0:e.disconnect()}componentDidLoad(){this.alertTitleShouldWrap();this.hostMutationObserver=new MutationObserver(this.hostMutationCallback);this.hostMutationObserver.observe(this.el,{childList:true})}handleClick(){this.visible=!this.visible}alertTitleShouldWrap(){var e;const t=(e=this.el.shadowRoot.querySelector(".alert-title"))===null||e===void 0?void 0:e.clientHeight;if(t>24)this.alertTitleWrap=true}render(){const{variant:e,heading:t,message:i,titleAbove:s,dismissible:o,announced:u,visible:m}=this;return m&&a(r,{role:u?"alert":null,class:{[d.Dark]:true}},a("div",{class:{["container"]:true,[`container-${e}`]:true}},a("div",{class:"alert-icon-container"},a("div",{class:{["divider"]:true,[`divider-${e}`]:true}}),a("span",{class:{["alert-icon"]:true,["svg-container"]:true,[`icon-${e}`]:true},innerHTML:l[e].icon})),a("div",{class:"alert-content"},a("div",{class:{["alert-message"]:true,["alert-message-title-above"]:s||this.alertTitleWrap}},t&&a("ic-typography",{class:{["alert-title"]:true,["alert-title-above"]:s||this.alertTitleWrap},variant:"subtitle-large"},a("p",null,t)),a("slot",{name:"message"},a("ic-typography",{variant:"body"},i))),c(this.el,"action")&&a("div",{class:"alert-action-container"},a("slot",{name:"action"}))),a("div",{class:"dismiss-icon-container"},o&&a("ic-button",{class:{["svg-container"]:true,["dismiss-icon"]:true},innerHTML:n,onClick:this.dismissAction,variant:"icon",appearance:d.Dark,title:"dismiss"}))))}get el(){return s(this)}};m.style=u;export{m as ic_alert};
|
2
|
-
//# sourceMappingURL=p-ad67c84f.entry.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"names":["icAlertCss","Alert","this","hostMutationObserver","dismissAction","dismiss","emit","icDismiss","hostMutationCallback","mutationList","some","type","addedNodes","removedNodes","checkSlotInChildMutations","forceUpdate","disconnectedCallback","_a","disconnect","componentDidLoad","alertTitleShouldWrap","MutationObserver","observe","el","childList","handleClick","visible","titleHeight","shadowRoot","querySelector","clientHeight","alertTitleWrap","render","variant","heading","message","titleAbove","dismissible","announced","h","Host","role","class","IcThemeForegroundEnum","Dark","innerHTML","VARIANT_ICONS","icon","name","isSlotUsed","closeIcon","onClick","appearance","title"],"sources":["src/components/ic-alert/ic-alert.css?tag=ic-alert&encapsulation=shadow","src/components/ic-alert/ic-alert.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n:host {\n display: block;\n}\n\n.container {\n min-height: 3.5rem;\n border-radius: var(--ic-border-radius);\n position: relative;\n display: flex;\n align-items: center;\n}\n\n.container-neutral {\n background-color: var(--ic-status-unknown-light);\n}\n\n.container-info {\n background-color: var(--ic-status-info-light);\n}\n\n.container-warning {\n background-color: var(--ic-status-warning-light);\n}\n\n.container-error {\n background-color: var(--ic-status-error-light);\n}\n\n.container-success {\n background-color: var(--ic-status-success-light);\n}\n\n.alert-icon-container {\n height: 100%;\n display: flex;\n align-items: center;\n}\n\n.divider {\n height: 100%;\n width: var(--ic-space-xs);\n border-radius: var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);\n position: absolute;\n}\n\n.divider-neutral {\n background-color: var(--ic-status-unknown);\n}\n\n.divider-info {\n background-color: var(--ic-status-info);\n}\n\n.divider-warning {\n background-color: var(--ic-status-warning);\n}\n\n.divider-error {\n background-color: var(--ic-status-error);\n}\n\n.divider-success {\n background-color: var(--ic-status-success);\n}\n\n.alert-icon {\n height: var(--ic-space-lg);\n width: 1.375rem;\n margin-left: 1.125rem;\n}\n\n.alert-icon > svg {\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n display: inline-block;\n}\n\n.icon-neutral > svg {\n fill: var(--ic-status-unknown);\n}\n\n:host([variant=\"info\"]) .alert-icon svg {\n fill: var(--ic-status-info);\n}\n\n:host([variant=\"warning\"]) .alert-icon svg {\n fill: var(--ic-status-warning);\n}\n\n:host([variant=\"error\"]) .alert-icon svg {\n fill: var(--ic-status-error);\n}\n\n:host([variant=\"success\"]) .alert-icon svg {\n fill: var(--ic-status-success);\n}\n\n.alert-content {\n display: flex;\n align-items: center;\n margin-left: 0.625rem;\n width: 100%;\n}\n\n.alert-message {\n display: flex;\n align-items: center;\n padding: var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;\n flex: 1;\n}\n\n.alert-message-title-above {\n display: inline;\n}\n\n.alert-title {\n margin-right: var(--ic-space-xs);\n}\n\n.alert-title-above {\n white-space: normal;\n}\n\n.alert-action-container {\n margin-right: var(--ic-space-xs);\n display: flex;\n align-items: center;\n}\n\n.dismiss-icon {\n margin-right: var(--ic-space-xxxs);\n margin-left: -0.375rem;\n padding: 0.375rem;\n border: none;\n border-radius: 50%;\n background-color: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.dismiss-icon:hover {\n cursor: pointer;\n}\n\n@media (max-width: 628px) {\n .alert-content {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n }\n\n .alert-message {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n }\n\n .alert-title {\n white-space: normal;\n }\n\n .alert-action-container {\n margin-bottom: var(--ic-space-xs);\n }\n}\n\n@media (forced-colors: active) {\n .container {\n border: var(--ic-hc-border);\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Host,\n State,\n Listen,\n Prop,\n h,\n forceUpdate,\n} from \"@stencil/core\";\nimport closeIcon from \"../../assets/close-icon.svg\";\nimport { isSlotUsed, checkSlotInChildMutations } from \"../../utils/helpers\";\nimport { IcThemeForegroundEnum, IcStatusVariants } from \"../../utils/types\";\nimport { VARIANT_ICONS } from \"../../utils/constants\";\n\n/**\n * @slot message - Content is placed to the right of the title.\n * @slot action - Content is placed to the right of the message.\n */\n@Component({\n tag: \"ic-alert\",\n styleUrl: \"ic-alert.css\",\n shadow: true,\n})\nexport class Alert {\n private hostMutationObserver: MutationObserver = null;\n\n @Element() el: HTMLIcAlertElement;\n\n @State() alertTitleWrap: boolean = false;\n @State() visible: boolean = true;\n\n /**\n * If `true`, the alert will have the 'alert' ARIA role and will be announced to screen readers.\n */\n @Prop() announced?: boolean = true;\n\n /**\n * If `true`, the alert will have a close icon at the end to dismiss it.\n */\n @Prop() dismissible?: boolean = false;\n\n /**\n * The optional title to display at the start of the alert.\n */\n @Prop() heading?: string = \"\";\n\n /**\n * The main body message of the alert.\n */\n @Prop() message?: string;\n\n /**\n * If `true`, the title and message will appear above and below instead of inline.\n */\n @Prop() titleAbove?: boolean = false;\n\n /**\n * The variant of the alert which will be rendered.\n */\n @Prop() variant?: IcStatusVariants = \"neutral\";\n\n /**\n * @deprecated This event should not be used anymore. Use icDismiss instead.\n */\n @Event() dismiss: EventEmitter<void>;\n\n /**\n * Is emitted when the user dismisses the alert.\n */\n @Event() icDismiss: EventEmitter<void>;\n\n disconnectedCallback(): void {\n this.hostMutationObserver?.disconnect();\n }\n\n componentDidLoad(): void {\n this.alertTitleShouldWrap();\n\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n childList: true,\n });\n }\n\n @Listen(\"icDismiss\", { capture: true })\n handleClick(): void {\n this.visible = !this.visible;\n }\n\n private dismissAction = (): void => {\n this.dismiss.emit();\n this.icDismiss.emit();\n };\n\n private alertTitleShouldWrap() {\n const titleHeight =\n this.el.shadowRoot.querySelector(\".alert-title\")?.clientHeight;\n if (titleHeight > 24) this.alertTitleWrap = true;\n }\n\n private hostMutationCallback = (mutationList: MutationRecord[]): void => {\n if (\n mutationList.some(({ type, addedNodes, removedNodes }) =>\n type === \"childList\"\n ? checkSlotInChildMutations(addedNodes, removedNodes, \"action\")\n : false\n )\n ) {\n forceUpdate(this);\n }\n };\n\n render() {\n const {\n variant,\n heading,\n message,\n titleAbove,\n dismissible,\n announced,\n visible,\n } = this;\n\n return (\n visible && (\n <Host\n role={announced ? \"alert\" : null}\n class={{\n [IcThemeForegroundEnum.Dark]: true,\n }}\n >\n <div\n class={{\n [\"container\"]: true,\n [`container-${variant}`]: true,\n }}\n >\n <div class=\"alert-icon-container\">\n <div\n class={{\n [\"divider\"]: true,\n [`divider-${variant}`]: true,\n }}\n ></div>\n <span\n class={{\n [\"alert-icon\"]: true,\n [\"svg-container\"]: true,\n [`icon-${variant}`]: true,\n }}\n innerHTML={VARIANT_ICONS[variant].icon}\n ></span>\n </div>\n <div class=\"alert-content\">\n <div\n class={{\n [\"alert-message\"]: true,\n [\"alert-message-title-above\"]:\n titleAbove || this.alertTitleWrap,\n }}\n >\n {heading && (\n <ic-typography\n class={{\n [\"alert-title\"]: true,\n [\"alert-title-above\"]: titleAbove || this.alertTitleWrap,\n }}\n variant=\"subtitle-large\"\n >\n <p>{heading}</p>\n </ic-typography>\n )}\n <slot name=\"message\">\n <ic-typography variant=\"body\">{message}</ic-typography>\n </slot>\n </div>\n {isSlotUsed(this.el, \"action\") && (\n <div class=\"alert-action-container\">\n <slot name=\"action\" />\n </div>\n )}\n </div>\n <div class=\"dismiss-icon-container\">\n {dismissible && (\n <ic-button\n class={{\n [\"svg-container\"]: true,\n [\"dismiss-icon\"]: true,\n }}\n innerHTML={closeIcon}\n onClick={this.dismissAction}\n variant=\"icon\"\n appearance={IcThemeForegroundEnum.Dark}\n title=\"dismiss\"\n ></ic-button>\n )}\n </div>\n </div>\n </Host>\n )\n );\n }\n}\n"],"mappings":"iMAAA,MAAMA,EAAa,0sJ,MC0BNC,EAAK,M,+FACRC,KAAAC,qBAAyC,KAiEzCD,KAAAE,cAAgB,KACtBF,KAAKG,QAAQC,OACbJ,KAAKK,UAAUD,MAAM,EASfJ,KAAAM,qBAAwBC,IAC9B,GACEA,EAAaC,MAAK,EAAGC,OAAMC,aAAYC,kBACrCF,IAAS,YACLG,EAA0BF,EAAYC,EAAc,UACpD,QAEN,CACAE,EAAYb,K,uBAhFmB,M,aACP,K,eAKE,K,iBAKE,M,aAKL,G,uCAUI,M,aAKM,S,CAYrC,oBAAAc,G,OACEC,EAAAf,KAAKC,wBAAoB,MAAAc,SAAA,SAAAA,EAAEC,Y,CAG7B,gBAAAC,GACEjB,KAAKkB,uBAELlB,KAAKC,qBAAuB,IAAIkB,iBAAiBnB,KAAKM,sBACtDN,KAAKC,qBAAqBmB,QAAQpB,KAAKqB,GAAI,CACzCC,UAAW,M,CAKf,WAAAC,GACEvB,KAAKwB,SAAWxB,KAAKwB,O,CAQf,oBAAAN,G,MACN,MAAMO,GACJV,EAAAf,KAAKqB,GAAGK,WAAWC,cAAc,mBAAe,MAAAZ,SAAA,SAAAA,EAAEa,aACpD,GAAIH,EAAc,GAAIzB,KAAK6B,eAAiB,I,CAe9C,MAAAC,GACE,MAAMC,QACJA,EAAOC,QACPA,EAAOC,QACPA,EAAOC,WACPA,EAAUC,YACVA,EAAWC,UACXA,EAASZ,QACTA,GACExB,KAEJ,OACEwB,GACEa,EAACC,EAAI,CACHC,KAAMH,EAAY,QAAU,KAC5BI,MAAO,CACL,CAACC,EAAsBC,MAAO,OAGhCL,EAAA,OACEG,MAAO,CACL,CAAC,aAAc,KACf,CAAC,aAAaT,KAAY,OAG5BM,EAAA,OAAKG,MAAM,wBACTH,EAAA,OACEG,MAAO,CACL,CAAC,WAAY,KACb,CAAC,WAAWT,KAAY,QAG5BM,EAAA,QACEG,MAAO,CACL,CAAC,cAAe,KAChB,CAAC,iBAAkB,KACnB,CAAC,QAAQT,KAAY,MAEvBY,UAAWC,EAAcb,GAASc,QAGtCR,EAAA,OAAKG,MAAM,iBACTH,EAAA,OACEG,MAAO,CACL,CAAC,iBAAkB,KACnB,CAAC,6BACCN,GAAclC,KAAK6B,iBAGtBG,GACCK,EAAA,iBACEG,MAAO,CACL,CAAC,eAAgB,KACjB,CAAC,qBAAsBN,GAAclC,KAAK6B,gBAE5CE,QAAQ,kBAERM,EAAA,SAAIL,IAGRK,EAAA,QAAMS,KAAK,WACTT,EAAA,iBAAeN,QAAQ,QAAQE,KAGlCc,EAAW/C,KAAKqB,GAAI,WACnBgB,EAAA,OAAKG,MAAM,0BACTH,EAAA,QAAMS,KAAK,aAIjBT,EAAA,OAAKG,MAAM,0BACRL,GACCE,EAAA,aACEG,MAAO,CACL,CAAC,iBAAkB,KACnB,CAAC,gBAAiB,MAEpBG,UAAWK,EACXC,QAASjD,KAAKE,cACd6B,QAAQ,OACRmB,WAAYT,EAAsBC,KAClCS,MAAM,c"}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{r as t,c as i,h as e,H as s,g as a}from"./p-6b5e91e2.js";import{c as o}from"./p-f074ef5b.js";import{i as n,V as r,a as c,L as d,d as l}from"./p-fef9e8c9.js";import{I as h}from"./p-26b7b18f.js";const m='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{--bottom-position:var(--ic-space-xl);position:fixed;bottom:var(--bottom-position);left:50%;transform:translate(-50%);animation:fadein var(--ic-transition-duration-slow) ease-in-out;z-index:var(--ic-z-index-toast)}:host(.hidden){display:none;animation:fadeout var(--ic-transition-duration-slow) ease-in-out}.container{max-width:32.5rem;min-width:18rem;box-shadow:var(--ic-elevation-overlay);min-height:3.5rem;background-color:var(--ic-architectural-800);color:var(--ic-color-white-text);display:flex;align-items:center;position:relative;border-radius:var(--ic-border-radius)}.toast-icon-container{height:100%;display:flex;align-items:center}.divider{height:100%;width:var(--ic-space-xs);position:absolute;border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs)}.divider-neutral{background-color:var(--ic-status-unknown)}.divider-info{background-color:var(--ic-status-info-contrast)}.divider-warning{background-color:var(--ic-status-warning-contrast)}.divider-error{background-color:var(--ic-status-error-contrast)}.divider-success{background-color:var(--ic-status-success-contrast)}.toast-icon,::slotted(svg){height:var(--ic-space-lg);width:var(--ic-space-lg);margin-left:var(--ic-space-md)}:host([variant="neutral"]) .toast-icon svg,::slotted(svg){fill:var(--ic-status-unknown)}:host([variant="info"]) .toast-icon svg{fill:var(--ic-status-info-contrast)}:host([variant="warning"]) .toast-icon svg{fill:var(--ic-status-warning-contrast)}:host([variant="error"]) .toast-icon svg{fill:var(--ic-status-error-contrast)}:host([variant="success"]) .toast-icon svg{fill:var(--ic-status-success-contrast)}.toast-content{margin-left:var(--ic-space-xs);width:100%}.no-icon{margin-left:var(--ic-space-md)}.toast-message{padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0}.toast-action-container{padding-bottom:var(--ic-space-md)}ic-button,.toast-dismiss-timer{padding:var(--ic-space-xs)}@media (max-width: 576px){:host{--bottom-position:var(--ic-space-lg);width:calc(100% - 2 * var(--ic-space-md))}}@media (min-width: 993px){:host{--bottom-position:calc(var(--ic-space-xl) + var(--ic-space-xs))}}@media (forced-colors: active){.container{border:var(--ic-hc-border)}}@keyframes fadein{from{bottom:0;opacity:0}to{bottom:var(--bottom-position);opacity:1}}@keyframes fadeout{from{bottom:var(--bottom-position);opacity:1}to{bottom:0;opacity:0}}';const u=1e3;const p=70;const b=140;const f=class{constructor(e){t(this,e);this.icDismiss=i(this,"icDismiss",7);this.interactiveElements=[];this.dismissAction=()=>{this.icDismiss.emit()};this.handleProgressChange=()=>{this.timerProgress-=u/this.autoDismissTimeout*100};this.timerProgress=100;this.visible=false;this.autoDismissTimeout=5e3;this.dismissButtonAriaLabel="dismiss";this.dismissMode="manual";this.heading=undefined;this.message=undefined;this.neutralIconAriaLabel=undefined;this.variant=undefined}dismissModeChangeHandler(t){this.isManual=t==="manual"}disconnectedCallback(){window.clearTimeout(this.dismissTimeout);window.clearInterval(this.timerRefreshInterval)}componentWillLoad(){var t,i;this.handleLongText(this.heading.length>p,((t=this.message)===null||t===void 0?void 0:t.length)>b);if(this.autoDismissTimeout<5e3)this.autoDismissTimeout=5e3;if(n(this.el,"action"))this.dismissMode="manual";this.isManual=this.dismissMode==="manual";if(n(this.el,"neutral-icon"))this.variant="neutral";if(this.variant==="neutral"){this.neutralVariantLabel=(i=this.neutralIconAriaLabel)!==null&&i!==void 0?i:r[this.variant].ariaLabel}if(this.isManual){const t=l(this.message)?`. ${this.message}`:"";this.el.setAttribute("aria-label",this.variant?this.neutralVariantLabel||r[this.variant].ariaLabel:this.heading);(this.variant||this.message)&&this.el.setAttribute("aria-description",this.variant?`${this.heading}${t}`:this.message)}}componentDidLoad(){c([{prop:this.heading,propName:"heading"}],"Toast");const t=d(this.el,"action");const i=this.el.shadowRoot.querySelector("ic-button");if(t)this.interactiveElements.push(t);if(i)this.interactiveElements.push(i)}handleDismiss(){this.visible=false;clearInterval(this.timerRefreshInterval);this.timerProgress=100}handleKeyboard(t){if(this.isManual&&this.visible){switch(t.key){case"Tab":t.preventDefault();this.findNextInteractiveElement(t.shiftKey).setFocus();break;case"Escape":!t.repeat&&this.dismissAction();t.stopImmediatePropagation();break}}}handleTimer(t){if(!this.isManual){switch(t.type){case"mouseenter":window.clearTimeout(this.dismissTimeout);window.clearInterval(this.timerRefreshInterval);this.timerProgress=100;break;case"mouseleave":this.dismissTimeout=window.setTimeout(this.dismissAction,this.autoDismissTimeout);this.timerRefreshInterval=window.setInterval(this.handleProgressChange,u);break}}}async setVisible(){if(!this.visible)this.visible=true;if(!this.isManual){this.dismissTimeout=window.setTimeout(this.dismissAction,this.autoDismissTimeout);this.timerRefreshInterval=window.setInterval(this.handleProgressChange,u);return null}else{window.setTimeout((()=>this.interactiveElements[0].setFocus()),200);return document.activeElement}}handleLongText(t,i){if(i||t){console.error(`Too many characters in toast ${t?"heading":""}${t&&i?" and ":""}${i?"message":""}. Refer to character limits specified in the prop description`)}}findNextInteractiveElement(t){const i=this.interactiveElements[0];const e=this.interactiveElements[this.interactiveElements.length-1];if(this.isActive(t?i:e))return t?e:i;let s;return this.interactiveElements.some(((t,i)=>{if(!this.isActive(t))return false;s=i;return true}))?this.interactiveElements[s+(t?-1:1)]:i}isActive(t){return t===this.el?!!this.el.shadowRoot.activeElement:document.activeElement===t}render(){const{variant:t,heading:i,message:a,visible:c,isManual:d,dismissButtonAriaLabel:l}=this;return e(s,{class:{["hidden"]:!c},role:d?"dialog":"status"},e("div",{class:"container"},t&&c&&e("div",{class:"toast-icon-container"},e("div",{class:{["divider"]:true,[`divider-${t}`]:true}}),t==="neutral"?e("slot",{name:"neutral-icon"}):e("span",{class:"toast-icon",innerHTML:r[t].icon})),e("div",{class:{["toast-content"]:true,["no-icon"]:t==="neutral"&&!n(this.el,"neutral-icon")}},e("div",{class:"toast-message"},e("ic-typography",{variant:"subtitle-large"},c&&e("h5",null,i)),a&&e("ic-typography",{variant:"body"},c&&e("p",null,a))),n(this.el,"action")&&e("div",{class:"toast-action-container"},e("slot",{name:"action"}))),!d?e("ic-loading-indicator",{class:"toast-dismiss-timer",appearance:"light",size:"icon",progress:this.timerProgress}):e("ic-button",{id:"dismiss-button",innerHTML:o,onClick:this.dismissAction,variant:"icon",appearance:h.Light,"aria-label":l})))}get el(){return a(this)}static get watchers(){return{dismissMode:["dismissModeChangeHandler"]}}};f.style=m;export{f as ic_toast};
|
2
|
-
//# sourceMappingURL=p-b2ceb541.entry.js.map
|