@spw-ds/spw-stencil-library 1.17.2 → 1.17.3-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/dist/cem.json +167 -0
  2. package/dist/cjs/index-D3lyhQSW.js +4 -0
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/spw-alert.cjs.entry.js +55 -0
  5. package/dist/cjs/spw-date-picker.cjs.entry.js +5 -2
  6. package/dist/cjs/spw-field-label_8.cjs.entry.js +8 -13
  7. package/dist/cjs/spw-header-lang.cjs.entry.js +14 -5
  8. package/dist/cjs/spw-header-navigation-item.cjs.entry.js +127 -2
  9. package/dist/cjs/spw-header-persona.cjs.entry.js +16 -7
  10. package/dist/cjs/spw-search-field.cjs.entry.js +1 -1
  11. package/dist/cjs/spw-stencil-library.cjs.js +1 -1
  12. package/dist/collection/collection-manifest.json +1 -0
  13. package/dist/collection/components/spw-alert/spw-alert.css +446 -0
  14. package/dist/collection/components/spw-alert/spw-alert.js +202 -0
  15. package/dist/collection/components/spw-date-picker/spw-date-picker.js +5 -2
  16. package/dist/collection/components/spw-group/spw-group.js +8 -13
  17. package/dist/collection/components/spw-header/spw-header-lang/spw-header-lang.js +14 -5
  18. package/dist/collection/components/spw-header/spw-header-navigation-item/spw-header-navigation-item.css +8 -8
  19. package/dist/collection/components/spw-header/spw-header-navigation-item/spw-header-navigation-item.js +128 -2
  20. package/dist/collection/components/spw-header/spw-header-persona/spw-header-persona.css +9 -5
  21. package/dist/collection/components/spw-header/spw-header-persona/spw-header-persona.js +15 -6
  22. package/dist/collection/components/spw-search-field/spw-search-field.css +3 -1
  23. package/dist/components/spw-alert.d.ts +11 -0
  24. package/dist/components/spw-alert.js +1 -0
  25. package/dist/components/spw-date-picker.js +1 -1
  26. package/dist/components/spw-group.js +1 -1
  27. package/dist/components/spw-header-lang.js +1 -1
  28. package/dist/components/spw-header-navigation-item.js +1 -1
  29. package/dist/components/spw-header-persona.js +1 -1
  30. package/dist/components/spw-search-field.js +1 -1
  31. package/dist/components_json.json +223 -2
  32. package/dist/components_vscode.json +25 -0
  33. package/dist/esm/index-DkNryMko.js +4 -0
  34. package/dist/esm/loader.js +1 -1
  35. package/dist/esm/spw-alert.entry.js +53 -0
  36. package/dist/esm/spw-date-picker.entry.js +5 -2
  37. package/dist/esm/spw-field-label_8.entry.js +8 -13
  38. package/dist/esm/spw-header-lang.entry.js +14 -5
  39. package/dist/esm/spw-header-navigation-item.entry.js +127 -2
  40. package/dist/esm/spw-header-persona.entry.js +16 -7
  41. package/dist/esm/spw-search-field.entry.js +1 -1
  42. package/dist/esm/spw-stencil-library.js +1 -1
  43. package/dist/spw-stencil-library/p-00c70684.entry.js +1 -0
  44. package/dist/spw-stencil-library/p-0bf3f71f.entry.js +1 -0
  45. package/dist/spw-stencil-library/{p-6cfcab87.entry.js → p-1fdace00.entry.js} +1 -1
  46. package/dist/spw-stencil-library/p-550df37a.entry.js +1 -0
  47. package/dist/spw-stencil-library/p-7807d0c0.entry.js +1 -0
  48. package/dist/spw-stencil-library/p-7ab7181d.entry.js +1 -0
  49. package/dist/spw-stencil-library/{p-d38ec8b1.entry.js → p-d1917f78.entry.js} +1 -1
  50. package/dist/spw-stencil-library/spw-stencil-library.esm.js +1 -1
  51. package/dist/stats.json +639 -55
  52. package/dist/types/components/spw-alert/spw-alert.d.ts +31 -0
  53. package/dist/types/components/spw-group/spw-group.d.ts +2 -0
  54. package/dist/types/components/spw-header/spw-header-lang/spw-header-lang.d.ts +1 -0
  55. package/dist/types/components/spw-header/spw-header-navigation-item/spw-header-navigation-item.d.ts +14 -0
  56. package/dist/types/components/spw-header/spw-header-persona/spw-header-persona.d.ts +1 -0
  57. package/dist/types/components.d.ts +84 -0
  58. package/hydrate/index.js +241 -31
  59. package/hydrate/index.mjs +241 -31
  60. package/package.json +1 -1
  61. package/dist/spw-stencil-library/p-0043c2f4.entry.js +0 -1
  62. package/dist/spw-stencil-library/p-7e2bf8ad.entry.js +0 -1
  63. package/dist/spw-stencil-library/p-8a8faafd.entry.js +0 -1
  64. package/dist/spw-stencil-library/p-feca6945.entry.js +0 -1
@@ -1 +1 @@
1
- import{p as e,H as s,c as t,h as i,t as o}from"./index.js";import{d as r}from"./p-GqBctcHU.js";import{d as a}from"./p-_Np7i1O2.js";import{d as n}from"./p-YvGDRmTV.js";import{d as l}from"./p-BG8eSnGj.js";import{d as h}from"./p-C1V6TSMJ.js";import{d}from"./p-Bi15ObnP.js";import{d as p}from"./p-XOK-JXlE.js";const c=e(class extends s{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.valueChanged=t(this,"valueChanged",7),this.optionSelected=t(this,"optionSelected",7),this.value="",this.placeholder="Recherche...",this.size="medium",this.label="",this.required=!1,this.viewAllResults="Voir plus de résultats",this.viewAllResultsSubmit=!1,this.hasMoreResults=!0,this.noResults="Pas de résultats.",this.loadingText="Recherche en cours...",this.hasSubmitButton=!1,this.minCharacters=3,this.isLoading=!1,this.showDropdown=!0,this.tooltipDirection="top",this.tooltipCursor="help",this.filteredItems=[],this.parsedItems=[],this.searchText="",this.isOpen=!1,this.focusedItemIndex=null,this.dropdownDirection="down",this.showViewAll=!0,this.isSelectingItem=!1,this.handleClickOutside=e=>{if(this.isOpen){const s=e.composedPath()[0];this.hostElement.contains(s)||(this.isOpen=!1)}},this.handleValueChanged=e=>{const s=e.detail+"";this.isSelectingItem||(this.searchText=s,this.value=s,this.updateHiddenInput(),this.filterTimeout&&clearTimeout(this.filterTimeout),!this.searchText||this.searchText.length<this.minCharacters?this.isOpen=!1:(!this.isOpen&&this.showDropdown&&(this.isOpen=!0,this.determineDropdownDirection()),this.filterTimeout=setTimeout((()=>{this.filterItems()}),300)),this.valueChanged.emit(this.value))},this.handleSubmit=e=>{null==e||e.preventDefault();const s=this.el.closest("form");s&&s.requestSubmit()}}componentWillLoad(){this.parseItems(this.items),this.defaultValue=this.value,this.initializeFromValue(this.value),this.showViewAll=this.hasMoreResults}handleHasMoreResultsChange(e){this.showViewAll=e}componentDidLoad(){document.addEventListener("click",this.handleClickOutside),this.createHiddenInput()}createHiddenInput(){this.name&&(this.hiddenInput=document.createElement("input"),this.hiddenInput.type="hidden",this.hiddenInput.name=this.name,this.hiddenInput.value=this.value||"",this.el.appendChild(this.hiddenInput))}updateHiddenInput(){this.hiddenInput&&(this.hiddenInput.value=this.value||"")}initializeFromValue(e){if(!e)return void(this.searchText="");const s=this.parsedItems.find((s=>s.value+""===e));this.searchText=s?s.label:e}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),this.filterTimeout&&clearTimeout(this.filterTimeout)}async resetInput(){this.value=this.defaultValue||"",this.initializeFromValue(this.value),this.updateHiddenInput(),this.isOpen=!1,this.focusedItemIndex=null,this.valueChanged.emit(this.value)}async setValue(e){this.value=e,this.initializeFromValue(e),this.filterItems(),this.valueChanged.emit(this.value)}async getValue(){return this.value}async showViewAllResults(){this.showViewAll=!0}async hideViewAllResults(){this.showViewAll=!1}handleValueChange(e){this.initializeFromValue(null!=e?e:""),this.filterItems()}parseItems(e){if(!e)return this.parsedItems=[],void(this.filteredItems=[]);if(Array.isArray(e))this.parsedItems=e;else try{this.parsedItems=JSON.parse(e)}catch(s){console.error("Invalid JSON format for items:",e),this.parsedItems=[]}this.filteredItems=[...this.parsedItems]}filterItems(){if(!this.parsedItems.length)return void(this.filteredItems=[]);const e=this.normalizeString(this.searchText).split(/\s+/).filter(Boolean);this.filteredItems=this.parsedItems.filter(e.length?s=>{var t,i;if(s.disabled)return!1;const o=this.normalizeString(`${s.label} ${null!==(t=s.searchableText)&&void 0!==t?t:""} ${null!==(i=s.category)&&void 0!==i?i:""}`);return e.every((e=>o.includes(e)))}:e=>!e.disabled)}normalizeString(e){return e.normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase()}selectItem(e){var s;this.isSelectingItem=!0,this.searchText=e.label,this.value=(null!==(s=e.value)&&void 0!==s?s:e.label)+"",this.isOpen=!1,this.focusedItemIndex=null,this.updateHiddenInput(),this.filterItems(),this.optionSelected.emit(e),this.valueChanged.emit(this.value),setTimeout((()=>{this.isSelectingItem=!1}),200),e.url&&(window.location.href=e.url)}determineDropdownDirection(){const e=this.hostElement.getBoundingClientRect(),s=window.innerHeight;this.dropdownDirection=e.bottom+200>s&&e.top>200?"up":"down"}handleKeyDown(e){switch(e.key){case"ArrowDown":e.preventDefault(),this.isOpen&&(this.focusedItemIndex=null===this.focusedItemIndex?0:(this.focusedItemIndex+1)%this.filteredItems.length);break;case"ArrowUp":e.preventDefault(),this.isOpen&&(this.focusedItemIndex=null===this.focusedItemIndex?this.filteredItems.length-1:(this.focusedItemIndex-1+this.filteredItems.length)%this.filteredItems.length);break;case"Enter":this.isOpen&&null!==this.focusedItemIndex?(e.preventDefault(),this.selectItem(this.filteredItems[this.focusedItemIndex])):this.hasSubmitButton&&(e.preventDefault(),this.handleSubmit(e));break;case"Escape":this.isOpen=!1}}highlightMatch(e){var s;const t=this.normalizeString(this.searchText).split(/\s+/).filter(Boolean);if(!t.length)return e;const o=Array.from(e).map((e=>this.normalizeString(e))),r=o.join(""),a=[];o.forEach(((e,s)=>{for(let t=0;t<e.length;t++)a.push(s)}));const n=[];for(const i of t){if(!i)continue;let t=0;for(;t<=r.length-i.length;){const o=r.indexOf(i,t);if(-1===o)break;const l=(null!==(s=a[o+i.length-1])&&void 0!==s?s:e.length-1)+1;n.push([a[o],l]),t=o+i.length}}if(!n.length)return e;n.sort(((e,s)=>e[0]-s[0]));const l=[n[0]];for(let e=1;e<n.length;e++){const s=l[l.length-1];n[e][0]<=s[1]?s[1]=Math.max(s[1],n[e][1]):l.push(n[e])}const h=[];let d=0;for(const[s,t]of l)s>d&&h.push(e.slice(d,s)),h.push(i("strong",null,e.slice(s,t))),d=t;return d<e.length&&h.push(e.slice(d)),i("span",null,h)}get elementClass(){return{"spw-search-field":!0,"spw-search-field--is-rounded":this.isRounded,"spw-search-field--has-submit-button":this.hasSubmitButton,"spw-search-field--is-open":this.isOpen,["spw-search-field--"+this.size]:!0}}render(){return i("div",{key:"060401db34655bb5b3bec93f5b818e6aa7b47102",ref:e=>this.hostElement=e,class:this.elementClass},this.label&&i("spw-field-label",{key:"a1800f04b056f0f79d3974c52a8c6d017ae4655a",label:this.label,name:this.name,required:this.required,tooltipTitle:this.tooltipTitle,tooltipText:this.tooltipText,tooltipMaxWidth:this.tooltipMaxWidth,tooltipDirection:this.tooltipDirection,tooltipCursor:this.tooltipCursor,onClick:()=>{var e;return null===(e=this.textFieldElement)||void 0===e?void 0:e.setFocus()}}),i("div",{key:"d9e2825baf141cb17c840a00a4affd92a23ae0f5",class:"spw-search-field__container"},i("spw-text-field",{key:"c8065e8f6f40a36ffa7787c1f885a2f668f4de4c",ref:e=>this.textFieldElement=e,placeholder:this.placeholder,name:this.name,size:this.size,"is-search":!0,"is-clear":!0,required:this.required,disabled:this.disabled,assistiveText:this.assistiveText,value:this.searchText,onValueChanged:this.handleValueChanged,onKeyDown:e=>this.handleKeyDown(e)}),this.hasSubmitButton&&i("button",{key:"44758a902c4dd685990e9fb91761b2f7cee021f4",type:"button",class:"spw-search-field__submit",onClick:this.handleSubmit,"aria-label":"Rechercher"})),this.showDropdown&&this.isOpen&&!!this.items&&i("div",{key:"1bda0dd7c9d5f8d7a42f58eb94682a6c8365ac1d",class:"spw-search-field__options spw-search-field__options--"+this.dropdownDirection},!!this.filteredItems.length&&i("ul",{key:"65d7585bbebc194c70b04abdb0c37fb8f158c3f6"},this.filteredItems.map(((e,s)=>i("li",{class:{"spw-search-field__option":!0,"spw-search-field__option--focused":s===this.focusedItemIndex},onClick:()=>this.selectItem(e)},this.highlightMatch(e.label)," ",e.category&&i("span",{class:"spw-search-field__category"}," - ",e.category))))),this.isLoading&&i("p",{key:"6487b6e9d9bb2c69038c600d9fc6cb3fbe4e5239",class:"spw-search-field__loading"},i("spw-loading",{key:"0be7c015388bc6ea462021e2bed47edf2ffd1a40",text:this.loadingText})),!this.isLoading&&!this.filteredItems.length&&i("p",{key:"1c39bb50878da6904512663d95333cade5cb3f46",class:"spw-search-field__no-results"},this.noResults),!!this.filteredItems.length&&this.viewAllResults&&this.showViewAll&&i("p",{key:"0cba9739d0e6e208f8bc40b2719ade5d71d864b3",class:"spw-search-field__view-all"},i("a",{key:"61886707d6e20501fc5d90ee2b1053b9a17b8571",href:this.viewAllResultsLink,onClick:this.viewAllResultsSubmit?this.handleSubmit:void 0},this.viewAllResults," ",i("spw-icon",{key:"a3f3bd3d26c593511c045f5976a18e055205c494",icon:"fa-arrow-right"})))))}get el(){return this}static get watchers(){return{hasMoreResults:[{handleHasMoreResultsChange:0}],value:[{handleValueChange:0}],items:[{parseItems:0}]}}static get style(){return"html{line-height:1.3;-webkit-text-size-adjust:100%;}h1,h2,h3,h4,h5,h6,p,ul,li{padding:0;margin:0}ul{list-style:none}:host{box-sizing:border-box;line-height:1.3;-webkit-text-size-adjust:100%;font-size:100%}:host *,:host *::before,:host *::after{box-sizing:inherit;font-family:var(--spw-ds-font-main);letter-spacing:-0.18px}body{margin: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;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}:root{--spw-ds-container-xl:1200px;--spw-ds-container-lg:1024px;--spw-ds-container-md:768px;--spw-ds-container-sm:640px}.spw-ds-container{width:100%;padding-left:16px;padding-right:16px;margin-left:auto;margin-right:auto}@media (min-width: 360px){.spw-ds-container{max-width:var(--spw-ds-container-sm)}}@media (min-width: 768px){.spw-ds-container{max-width:var(--spw-ds-container-md)}}@media (min-width: 1024px){.spw-ds-container{max-width:var(--spw-ds-container-lg)}}@media (min-width: 1200px){.spw-ds-container{max-width:var(--spw-ds-container-xl)}}:host{display:block}.spw-search-field{position:relative}.spw-search-field--large spw-text-field{--spw-input-height:54px;--spw-input-padding:16px 24px;--spw-input-radius:60px;--spw-input-border:transparent;--spw-input-icon-search-color:var(--spw-ds-primary)}.spw-search-field.spw-search-field--large.spw-search-field--is-open spw-text-field{--spw-input-radius:24px 24px 0 0}.spw-search-field--has-submit-button spw-text-field{--spw-input-padding-right:56px}.spw-search-field__container{position:relative}.spw-search-field__category{font-style:italic}.spw-search-field__submit{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:30px;height:30px;border:none;border-radius:50%;background:transparent;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:all 0.2s ease;z-index:10}.spw-search-field__submit:focus,.spw-search-field__submit:focus-visible{outline:1px solid white;outline-offset:0;box-shadow:0 0 0 3px black}.spw-search-field--large .spw-search-field__submit{width:46px;height:46px;right:16px}.spw-search-field__options{position:absolute;width:100%;background-color:#fff;border:1px solid var(--spw-color-themes-grey-grey-800);border-radius:0 0 4px 4px;max-height:200px;overflow-y:auto}.spw-search-field__options::-webkit-scrollbar{width:14px;height:14px}.spw-search-field__options::-webkit-scrollbar-thumb{background:var(--spw-color-themes-grey-grey-400);border-radius:20px;border:4px solid var(--spw-ds-white)}.spw-search-field__options::-webkit-scrollbar-track{background:var(--spw-ds-white)}.spw-search-field__options{scrollbar-face-color:var(--spw-color-themes-grey-grey-400);scrollbar-track-color:var(--spw-ds-white)}.spw-search-field__options{z-index:44;margin-top:-2px;transition:transform 0.3s ease, opacity 0.3s ease}.spw-search-field--is-rounded .spw-search-field__options{border-radius:0 0 24px 24px;border:none}.spw-search-field--is-rounded .spw-search-field__options ul{padding:12px}.spw-search-field__options--down{top:100%;transform:translateY(0)}.spw-search-field__options--up{top:100%;transform:translateY(0)}.spw-search-field__option{padding:12px;color:var(--spw-color-themes-grey-grey-900);text-align:left;border-bottom:1px solid var(--spw-color-themes-grey-grey-900);cursor:pointer;transition:background-color 0.2s ease}.spw-search-field--is-rounded .spw-search-field__option{border-radius:12px;padding:12px;border-bottom:none}.spw-search-field__option:hover{background-color:var(--spw-color-themes-grey-grey-200)}.spw-search-field__option:last-child{border-bottom:none}.spw-search-field__option--focused{background-color:var(--spw-color-themes-grey-grey-300)}.spw-search-field__option--selected{font-weight:700}.spw-search-field__loading,.spw-search-field__no-results{padding:12px;cursor:not-allowed;text-align:left;color:var(--spw-color-themes-grey-grey-600)}.spw-search-field--is-rounded .spw-search-field__loading,.spw-search-field--is-rounded .spw-search-field__no-results{padding:24px}.spw-search-field__view-all{position:sticky;bottom:0;cursor:pointer;font-weight:700}.spw-search-field--is-rounded .spw-search-field__view-all{border-radius:12px;border-top:none}.spw-search-field__view-all a{color:black;background:white;border-top:1px solid var(--spw-color-themes-grey-grey-900)}.spw-search-field--is-rounded .spw-search-field__view-all a{color:var(--spw-ds-primary);padding:12px 24px 24px 24px;border-top:none}.spw-search-field__view-all a{text-decoration:underline;display:block;width:100%;padding:12px;display:inline-flex;justify-content:space-between}.spw-search-field__view-all a:hover{text-decoration:none}"}},[1,"spw-search-field",{value:[1537],items:[1],placeholder:[1],size:[1],label:[1],disabled:[4],isRounded:[4,"is-rounded"],name:[1],required:[4],assistiveText:[1,"assistive-text"],viewAllResults:[1,"view-all-results"],viewAllResultsLink:[1,"view-all-results-link"],viewAllResultsSubmit:[4,"view-all-results-submit"],hasMoreResults:[4,"has-more-results"],noResults:[1,"no-results"],loadingText:[1,"loading-text"],hasSubmitButton:[4,"has-submit-button"],minCharacters:[2,"min-characters"],isLoading:[4,"is-loading"],showDropdown:[4,"show-dropdown"],tooltipTitle:[1,"tooltip-title"],tooltipText:[1,"tooltip-text"],tooltipMaxWidth:[1,"tooltip-max-width"],tooltipDirection:[1,"tooltip-direction"],tooltipCursor:[1,"tooltip-cursor"],filteredItems:[32],parsedItems:[32],searchText:[32],isOpen:[32],focusedItemIndex:[32],dropdownDirection:[32],showViewAll:[32],resetInput:[64],setValue:[64],getValue:[64],showViewAllResults:[64],hideViewAllResults:[64]},void 0,{hasMoreResults:[{handleHasMoreResultsChange:0}],value:[{handleValueChange:0}],items:[{parseItems:0}]}]),u=c,f=function(){"undefined"!=typeof customElements&&["spw-search-field","spw-field-label","spw-field-message","spw-icon","spw-link","spw-loading","spw-text-field","spw-tooltip"].forEach((e=>{switch(e){case"spw-search-field":customElements.get(o(e))||customElements.define(o(e),c);break;case"spw-field-label":customElements.get(o(e))||r();break;case"spw-field-message":customElements.get(o(e))||a();break;case"spw-icon":customElements.get(o(e))||n();break;case"spw-link":customElements.get(o(e))||l();break;case"spw-loading":customElements.get(o(e))||h();break;case"spw-text-field":customElements.get(o(e))||d();break;case"spw-tooltip":customElements.get(o(e))||p()}}))};export{u as SpwSearchField,f as defineCustomElement}
1
+ import{p as e,H as s,c as t,h as i,t as o}from"./index.js";import{d as r}from"./p-GqBctcHU.js";import{d as a}from"./p-_Np7i1O2.js";import{d as n}from"./p-YvGDRmTV.js";import{d as l}from"./p-BG8eSnGj.js";import{d as h}from"./p-C1V6TSMJ.js";import{d}from"./p-Bi15ObnP.js";import{d as p}from"./p-XOK-JXlE.js";const c=e(class extends s{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.valueChanged=t(this,"valueChanged",7),this.optionSelected=t(this,"optionSelected",7),this.value="",this.placeholder="Recherche...",this.size="medium",this.label="",this.required=!1,this.viewAllResults="Voir plus de résultats",this.viewAllResultsSubmit=!1,this.hasMoreResults=!0,this.noResults="Pas de résultats.",this.loadingText="Recherche en cours...",this.hasSubmitButton=!1,this.minCharacters=3,this.isLoading=!1,this.showDropdown=!0,this.tooltipDirection="top",this.tooltipCursor="help",this.filteredItems=[],this.parsedItems=[],this.searchText="",this.isOpen=!1,this.focusedItemIndex=null,this.dropdownDirection="down",this.showViewAll=!0,this.isSelectingItem=!1,this.handleClickOutside=e=>{if(this.isOpen){const s=e.composedPath()[0];this.hostElement.contains(s)||(this.isOpen=!1)}},this.handleValueChanged=e=>{const s=e.detail+"";this.isSelectingItem||(this.searchText=s,this.value=s,this.updateHiddenInput(),this.filterTimeout&&clearTimeout(this.filterTimeout),!this.searchText||this.searchText.length<this.minCharacters?this.isOpen=!1:(!this.isOpen&&this.showDropdown&&(this.isOpen=!0,this.determineDropdownDirection()),this.filterTimeout=setTimeout((()=>{this.filterItems()}),300)),this.valueChanged.emit(this.value))},this.handleSubmit=e=>{null==e||e.preventDefault();const s=this.el.closest("form");s&&s.requestSubmit()}}componentWillLoad(){this.parseItems(this.items),this.defaultValue=this.value,this.initializeFromValue(this.value),this.showViewAll=this.hasMoreResults}handleHasMoreResultsChange(e){this.showViewAll=e}componentDidLoad(){document.addEventListener("click",this.handleClickOutside),this.createHiddenInput()}createHiddenInput(){this.name&&(this.hiddenInput=document.createElement("input"),this.hiddenInput.type="hidden",this.hiddenInput.name=this.name,this.hiddenInput.value=this.value||"",this.el.appendChild(this.hiddenInput))}updateHiddenInput(){this.hiddenInput&&(this.hiddenInput.value=this.value||"")}initializeFromValue(e){if(!e)return void(this.searchText="");const s=this.parsedItems.find((s=>s.value+""===e));this.searchText=s?s.label:e}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),this.filterTimeout&&clearTimeout(this.filterTimeout)}async resetInput(){this.value=this.defaultValue||"",this.initializeFromValue(this.value),this.updateHiddenInput(),this.isOpen=!1,this.focusedItemIndex=null,this.valueChanged.emit(this.value)}async setValue(e){this.value=e,this.initializeFromValue(e),this.filterItems(),this.valueChanged.emit(this.value)}async getValue(){return this.value}async showViewAllResults(){this.showViewAll=!0}async hideViewAllResults(){this.showViewAll=!1}handleValueChange(e){this.initializeFromValue(null!=e?e:""),this.filterItems()}parseItems(e){if(!e)return this.parsedItems=[],void(this.filteredItems=[]);if(Array.isArray(e))this.parsedItems=e;else try{this.parsedItems=JSON.parse(e)}catch(s){console.error("Invalid JSON format for items:",e),this.parsedItems=[]}this.filteredItems=[...this.parsedItems]}filterItems(){if(!this.parsedItems.length)return void(this.filteredItems=[]);const e=this.normalizeString(this.searchText).split(/\s+/).filter(Boolean);this.filteredItems=this.parsedItems.filter(e.length?s=>{var t,i;if(s.disabled)return!1;const o=this.normalizeString(`${s.label} ${null!==(t=s.searchableText)&&void 0!==t?t:""} ${null!==(i=s.category)&&void 0!==i?i:""}`);return e.every((e=>o.includes(e)))}:e=>!e.disabled)}normalizeString(e){return e.normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase()}selectItem(e){var s;this.isSelectingItem=!0,this.searchText=e.label,this.value=(null!==(s=e.value)&&void 0!==s?s:e.label)+"",this.isOpen=!1,this.focusedItemIndex=null,this.updateHiddenInput(),this.filterItems(),this.optionSelected.emit(e),this.valueChanged.emit(this.value),setTimeout((()=>{this.isSelectingItem=!1}),200),e.url&&(window.location.href=e.url)}determineDropdownDirection(){const e=this.hostElement.getBoundingClientRect(),s=window.innerHeight;this.dropdownDirection=e.bottom+200>s&&e.top>200?"up":"down"}handleKeyDown(e){switch(e.key){case"ArrowDown":e.preventDefault(),this.isOpen&&(this.focusedItemIndex=null===this.focusedItemIndex?0:(this.focusedItemIndex+1)%this.filteredItems.length);break;case"ArrowUp":e.preventDefault(),this.isOpen&&(this.focusedItemIndex=null===this.focusedItemIndex?this.filteredItems.length-1:(this.focusedItemIndex-1+this.filteredItems.length)%this.filteredItems.length);break;case"Enter":this.isOpen&&null!==this.focusedItemIndex?(e.preventDefault(),this.selectItem(this.filteredItems[this.focusedItemIndex])):this.hasSubmitButton&&(e.preventDefault(),this.handleSubmit(e));break;case"Escape":this.isOpen=!1}}highlightMatch(e){var s;const t=this.normalizeString(this.searchText).split(/\s+/).filter(Boolean);if(!t.length)return e;const o=Array.from(e).map((e=>this.normalizeString(e))),r=o.join(""),a=[];o.forEach(((e,s)=>{for(let t=0;t<e.length;t++)a.push(s)}));const n=[];for(const i of t){if(!i)continue;let t=0;for(;t<=r.length-i.length;){const o=r.indexOf(i,t);if(-1===o)break;const l=(null!==(s=a[o+i.length-1])&&void 0!==s?s:e.length-1)+1;n.push([a[o],l]),t=o+i.length}}if(!n.length)return e;n.sort(((e,s)=>e[0]-s[0]));const l=[n[0]];for(let e=1;e<n.length;e++){const s=l[l.length-1];n[e][0]<=s[1]?s[1]=Math.max(s[1],n[e][1]):l.push(n[e])}const h=[];let d=0;for(const[s,t]of l)s>d&&h.push(e.slice(d,s)),h.push(i("strong",null,e.slice(s,t))),d=t;return d<e.length&&h.push(e.slice(d)),i("span",null,h)}get elementClass(){return{"spw-search-field":!0,"spw-search-field--is-rounded":this.isRounded,"spw-search-field--has-submit-button":this.hasSubmitButton,"spw-search-field--is-open":this.isOpen,["spw-search-field--"+this.size]:!0}}render(){return i("div",{key:"060401db34655bb5b3bec93f5b818e6aa7b47102",ref:e=>this.hostElement=e,class:this.elementClass},this.label&&i("spw-field-label",{key:"a1800f04b056f0f79d3974c52a8c6d017ae4655a",label:this.label,name:this.name,required:this.required,tooltipTitle:this.tooltipTitle,tooltipText:this.tooltipText,tooltipMaxWidth:this.tooltipMaxWidth,tooltipDirection:this.tooltipDirection,tooltipCursor:this.tooltipCursor,onClick:()=>{var e;return null===(e=this.textFieldElement)||void 0===e?void 0:e.setFocus()}}),i("div",{key:"d9e2825baf141cb17c840a00a4affd92a23ae0f5",class:"spw-search-field__container"},i("spw-text-field",{key:"c8065e8f6f40a36ffa7787c1f885a2f668f4de4c",ref:e=>this.textFieldElement=e,placeholder:this.placeholder,name:this.name,size:this.size,"is-search":!0,"is-clear":!0,required:this.required,disabled:this.disabled,assistiveText:this.assistiveText,value:this.searchText,onValueChanged:this.handleValueChanged,onKeyDown:e=>this.handleKeyDown(e)}),this.hasSubmitButton&&i("button",{key:"44758a902c4dd685990e9fb91761b2f7cee021f4",type:"button",class:"spw-search-field__submit",onClick:this.handleSubmit,"aria-label":"Rechercher"})),this.showDropdown&&this.isOpen&&!!this.items&&i("div",{key:"1bda0dd7c9d5f8d7a42f58eb94682a6c8365ac1d",class:"spw-search-field__options spw-search-field__options--"+this.dropdownDirection},!!this.filteredItems.length&&i("ul",{key:"65d7585bbebc194c70b04abdb0c37fb8f158c3f6"},this.filteredItems.map(((e,s)=>i("li",{class:{"spw-search-field__option":!0,"spw-search-field__option--focused":s===this.focusedItemIndex},onClick:()=>this.selectItem(e)},this.highlightMatch(e.label)," ",e.category&&i("span",{class:"spw-search-field__category"}," - ",e.category))))),this.isLoading&&i("p",{key:"6487b6e9d9bb2c69038c600d9fc6cb3fbe4e5239",class:"spw-search-field__loading"},i("spw-loading",{key:"0be7c015388bc6ea462021e2bed47edf2ffd1a40",text:this.loadingText})),!this.isLoading&&!this.filteredItems.length&&i("p",{key:"1c39bb50878da6904512663d95333cade5cb3f46",class:"spw-search-field__no-results"},this.noResults),!!this.filteredItems.length&&this.viewAllResults&&this.showViewAll&&i("p",{key:"0cba9739d0e6e208f8bc40b2719ade5d71d864b3",class:"spw-search-field__view-all"},i("a",{key:"61886707d6e20501fc5d90ee2b1053b9a17b8571",href:this.viewAllResultsLink,onClick:this.viewAllResultsSubmit?this.handleSubmit:void 0},this.viewAllResults," ",i("spw-icon",{key:"a3f3bd3d26c593511c045f5976a18e055205c494",icon:"fa-arrow-right"})))))}get el(){return this}static get watchers(){return{hasMoreResults:[{handleHasMoreResultsChange:0}],value:[{handleValueChange:0}],items:[{parseItems:0}]}}static get style(){return"html{line-height:1.3;-webkit-text-size-adjust:100%;}h1,h2,h3,h4,h5,h6,p,ul,li{padding:0;margin:0}ul{list-style:none}:host{box-sizing:border-box;line-height:1.3;-webkit-text-size-adjust:100%;font-size:100%}:host *,:host *::before,:host *::after{box-sizing:inherit;font-family:var(--spw-ds-font-main);letter-spacing:-0.18px}body{margin: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;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}:root{--spw-ds-container-xl:1200px;--spw-ds-container-lg:1024px;--spw-ds-container-md:768px;--spw-ds-container-sm:640px}.spw-ds-container{width:100%;padding-left:16px;padding-right:16px;margin-left:auto;margin-right:auto}@media (min-width: 360px){.spw-ds-container{max-width:var(--spw-ds-container-sm)}}@media (min-width: 768px){.spw-ds-container{max-width:var(--spw-ds-container-md)}}@media (min-width: 1024px){.spw-ds-container{max-width:var(--spw-ds-container-lg)}}@media (min-width: 1200px){.spw-ds-container{max-width:var(--spw-ds-container-xl)}}:host{display:block;--spw-search-field-options-max-height:200px}.spw-search-field{position:relative}.spw-search-field--large spw-text-field{--spw-input-height:54px;--spw-input-padding:16px 24px;--spw-input-radius:60px;--spw-input-border:transparent;--spw-input-icon-search-color:var(--spw-ds-primary)}.spw-search-field.spw-search-field--large.spw-search-field--is-open spw-text-field{--spw-input-radius:24px 24px 0 0}.spw-search-field--has-submit-button spw-text-field{--spw-input-padding-right:56px}.spw-search-field__container{position:relative}.spw-search-field__category{font-style:italic}.spw-search-field__submit{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:30px;height:30px;border:none;border-radius:50%;background:transparent;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:all 0.2s ease;z-index:10}.spw-search-field__submit:focus,.spw-search-field__submit:focus-visible{outline:1px solid white;outline-offset:0;box-shadow:0 0 0 3px black}.spw-search-field--large .spw-search-field__submit{width:46px;height:46px;right:16px}.spw-search-field__options{position:absolute;width:100%;background-color:#fff;border:1px solid var(--spw-color-themes-grey-grey-800);border-radius:0 0 4px 4px;max-height:var(--spw-search-field-options-max-height);overflow-y:auto}.spw-search-field__options::-webkit-scrollbar{width:14px;height:14px}.spw-search-field__options::-webkit-scrollbar-thumb{background:var(--spw-color-themes-grey-grey-400);border-radius:20px;border:4px solid var(--spw-ds-white)}.spw-search-field__options::-webkit-scrollbar-track{background:var(--spw-ds-white)}.spw-search-field__options{scrollbar-face-color:var(--spw-color-themes-grey-grey-400);scrollbar-track-color:var(--spw-ds-white)}.spw-search-field__options{z-index:44;margin-top:-2px;transition:transform 0.3s ease, opacity 0.3s ease}.spw-search-field--is-rounded .spw-search-field__options{border-radius:0 0 24px 24px;border:none}.spw-search-field--is-rounded .spw-search-field__options ul{padding:12px}.spw-search-field__options--down{top:100%;transform:translateY(0)}.spw-search-field__options--up{top:100%;transform:translateY(0)}.spw-search-field__option{padding:12px;color:var(--spw-color-themes-grey-grey-900);text-align:left;border-bottom:1px solid var(--spw-color-themes-grey-grey-900);cursor:pointer;transition:background-color 0.2s ease}.spw-search-field--is-rounded .spw-search-field__option{border-radius:12px;padding:12px;border-bottom:none}.spw-search-field__option:hover{background-color:var(--spw-color-themes-grey-grey-200)}.spw-search-field__option:last-child{border-bottom:none}.spw-search-field__option--focused{background-color:var(--spw-color-themes-grey-grey-300)}.spw-search-field__option--selected{font-weight:700}.spw-search-field__loading,.spw-search-field__no-results{padding:12px;cursor:not-allowed;text-align:left;color:var(--spw-color-themes-grey-grey-600)}.spw-search-field--is-rounded .spw-search-field__loading,.spw-search-field--is-rounded .spw-search-field__no-results{padding:24px}.spw-search-field__view-all{position:sticky;bottom:0;cursor:pointer;font-weight:700}.spw-search-field--is-rounded .spw-search-field__view-all{border-radius:12px;border-top:none}.spw-search-field__view-all a{color:black;background:white;border-top:1px solid var(--spw-color-themes-grey-grey-900)}.spw-search-field--is-rounded .spw-search-field__view-all a{color:var(--spw-ds-primary);padding:12px 24px 24px 24px;border-top:none}.spw-search-field__view-all a{text-decoration:underline;display:block;width:100%;padding:12px;display:inline-flex;justify-content:space-between}.spw-search-field__view-all a:hover{text-decoration:none}"}},[1,"spw-search-field",{value:[1537],items:[1],placeholder:[1],size:[1],label:[1],disabled:[4],isRounded:[4,"is-rounded"],name:[1],required:[4],assistiveText:[1,"assistive-text"],viewAllResults:[1,"view-all-results"],viewAllResultsLink:[1,"view-all-results-link"],viewAllResultsSubmit:[4,"view-all-results-submit"],hasMoreResults:[4,"has-more-results"],noResults:[1,"no-results"],loadingText:[1,"loading-text"],hasSubmitButton:[4,"has-submit-button"],minCharacters:[2,"min-characters"],isLoading:[4,"is-loading"],showDropdown:[4,"show-dropdown"],tooltipTitle:[1,"tooltip-title"],tooltipText:[1,"tooltip-text"],tooltipMaxWidth:[1,"tooltip-max-width"],tooltipDirection:[1,"tooltip-direction"],tooltipCursor:[1,"tooltip-cursor"],filteredItems:[32],parsedItems:[32],searchText:[32],isOpen:[32],focusedItemIndex:[32],dropdownDirection:[32],showViewAll:[32],resetInput:[64],setValue:[64],getValue:[64],showViewAllResults:[64],hideViewAllResults:[64]},void 0,{hasMoreResults:[{handleHasMoreResultsChange:0}],value:[{handleValueChange:0}],items:[{parseItems:0}]}]),u=c,f=function(){"undefined"!=typeof customElements&&["spw-search-field","spw-field-label","spw-field-message","spw-icon","spw-link","spw-loading","spw-text-field","spw-tooltip"].forEach((e=>{switch(e){case"spw-search-field":customElements.get(o(e))||customElements.define(o(e),c);break;case"spw-field-label":customElements.get(o(e))||r();break;case"spw-field-message":customElements.get(o(e))||a();break;case"spw-icon":customElements.get(o(e))||n();break;case"spw-link":customElements.get(o(e))||l();break;case"spw-loading":customElements.get(o(e))||h();break;case"spw-text-field":customElements.get(o(e))||d();break;case"spw-tooltip":customElements.get(o(e))||p()}}))};export{u as SpwSearchField,f as defineCustomElement}
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2026-07-31T06:57:25",
2
+ "timestamp": "2026-08-19T14:17:01",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "4.42.0",
@@ -343,6 +343,217 @@
343
343
  ]
344
344
  }
345
345
  },
346
+ {
347
+ "filePath": "src/components/spw-alert/spw-alert.tsx",
348
+ "encapsulation": "shadow",
349
+ "tag": "spw-alert",
350
+ "readme": "# spw-alert\n\n\n",
351
+ "docs": "",
352
+ "docsTags": [],
353
+ "usage": {},
354
+ "props": [
355
+ {
356
+ "name": "alertId",
357
+ "type": "string",
358
+ "complexType": {
359
+ "original": "string",
360
+ "resolved": "string",
361
+ "references": {}
362
+ },
363
+ "mutable": false,
364
+ "attr": "alert-id",
365
+ "reflectToAttr": false,
366
+ "docs": "Identifiant unique pour l'alerte",
367
+ "docsTags": [],
368
+ "values": [
369
+ {
370
+ "type": "string"
371
+ }
372
+ ],
373
+ "optional": false,
374
+ "required": false,
375
+ "getter": false,
376
+ "setter": false
377
+ },
378
+ {
379
+ "name": "alertTitle",
380
+ "type": "string",
381
+ "complexType": {
382
+ "original": "string",
383
+ "resolved": "string",
384
+ "references": {}
385
+ },
386
+ "mutable": false,
387
+ "attr": "alert-title",
388
+ "reflectToAttr": false,
389
+ "docs": "Titre de l'alerte",
390
+ "docsTags": [
391
+ {
392
+ "name": "default",
393
+ "text": "'Notification'"
394
+ }
395
+ ],
396
+ "default": "'Notification'",
397
+ "values": [
398
+ {
399
+ "type": "string"
400
+ }
401
+ ],
402
+ "optional": false,
403
+ "required": false,
404
+ "getter": false,
405
+ "setter": false
406
+ },
407
+ {
408
+ "name": "dismissableText",
409
+ "type": "string",
410
+ "complexType": {
411
+ "original": "string",
412
+ "resolved": "string",
413
+ "references": {}
414
+ },
415
+ "mutable": false,
416
+ "attr": "dismissable-text",
417
+ "reflectToAttr": false,
418
+ "docs": "Texte du bouton pour masquer l'alerte",
419
+ "docsTags": [
420
+ {
421
+ "name": "default",
422
+ "text": "'Masquer'"
423
+ }
424
+ ],
425
+ "default": "'Masquer'",
426
+ "values": [
427
+ {
428
+ "type": "string"
429
+ }
430
+ ],
431
+ "optional": false,
432
+ "required": false,
433
+ "getter": false,
434
+ "setter": false
435
+ },
436
+ {
437
+ "name": "isDismissable",
438
+ "type": "boolean",
439
+ "complexType": {
440
+ "original": "boolean",
441
+ "resolved": "boolean",
442
+ "references": {}
443
+ },
444
+ "mutable": false,
445
+ "attr": "is-dismissable",
446
+ "reflectToAttr": false,
447
+ "docs": "Si l'alerte est masquable",
448
+ "docsTags": [
449
+ {
450
+ "name": "default",
451
+ "text": "true"
452
+ }
453
+ ],
454
+ "default": "true",
455
+ "values": [
456
+ {
457
+ "type": "boolean"
458
+ }
459
+ ],
460
+ "optional": false,
461
+ "required": false,
462
+ "getter": false,
463
+ "setter": false
464
+ }
465
+ ],
466
+ "methods": [
467
+ {
468
+ "name": "hideAlert",
469
+ "returns": {
470
+ "type": "Promise<void>",
471
+ "docs": ""
472
+ },
473
+ "complexType": {
474
+ "signature": "() => Promise<void>",
475
+ "parameters": [],
476
+ "references": {
477
+ "Promise": {
478
+ "location": "global",
479
+ "id": "global::Promise"
480
+ }
481
+ },
482
+ "return": "Promise<void>"
483
+ },
484
+ "signature": "hideAlert() => Promise<void>",
485
+ "parameters": [],
486
+ "docs": "Masque l'alerte",
487
+ "docsTags": []
488
+ },
489
+ {
490
+ "name": "showAlert",
491
+ "returns": {
492
+ "type": "Promise<void>",
493
+ "docs": ""
494
+ },
495
+ "complexType": {
496
+ "signature": "() => Promise<void>",
497
+ "parameters": [],
498
+ "references": {
499
+ "Promise": {
500
+ "location": "global",
501
+ "id": "global::Promise"
502
+ }
503
+ },
504
+ "return": "Promise<void>"
505
+ },
506
+ "signature": "showAlert() => Promise<void>",
507
+ "parameters": [],
508
+ "docs": "Affiche l'alerte",
509
+ "docsTags": []
510
+ }
511
+ ],
512
+ "events": [
513
+ {
514
+ "event": "spwDismiss",
515
+ "detail": "{ alertId: string; }",
516
+ "bubbles": true,
517
+ "complexType": {
518
+ "original": "{ alertId: string }",
519
+ "resolved": "{ alertId: string; }",
520
+ "references": {}
521
+ },
522
+ "cancelable": true,
523
+ "composed": true,
524
+ "docs": "Événement émis lors du clic sur le bouton de fermeture",
525
+ "docsTags": []
526
+ }
527
+ ],
528
+ "listeners": [],
529
+ "styles": [
530
+ {
531
+ "name": "--spw-alert-background-color",
532
+ "annotation": "prop",
533
+ "docs": "Couleur de fond de l'alerte"
534
+ },
535
+ {
536
+ "name": "--spw-alert-font-size",
537
+ "annotation": "prop",
538
+ "docs": "Taille de police de l'alerte"
539
+ }
540
+ ],
541
+ "slots": [],
542
+ "parts": [],
543
+ "states": [],
544
+ "dependents": [],
545
+ "dependencies": [
546
+ "spw-link"
547
+ ],
548
+ "dependencyGraph": {
549
+ "spw-alert": [
550
+ "spw-link"
551
+ ],
552
+ "spw-link": [
553
+ "spw-icon"
554
+ ]
555
+ }
556
+ },
346
557
  {
347
558
  "filePath": "src/components/spw-avatar/spw-avatar.tsx",
348
559
  "encapsulation": "shadow",
@@ -14682,6 +14893,7 @@
14682
14893
  "parts": [],
14683
14894
  "states": [],
14684
14895
  "dependents": [
14896
+ "spw-alert",
14685
14897
  "spw-breadcrumb-item",
14686
14898
  "spw-drawer",
14687
14899
  "spw-field-message",
@@ -14697,6 +14909,9 @@
14697
14909
  "spw-link": [
14698
14910
  "spw-icon"
14699
14911
  ],
14912
+ "spw-alert": [
14913
+ "spw-link"
14914
+ ],
14700
14915
  "spw-breadcrumb-item": [
14701
14916
  "spw-link"
14702
14917
  ],
@@ -18101,7 +18316,13 @@
18101
18316
  }
18102
18317
  ],
18103
18318
  "listeners": [],
18104
- "styles": [],
18319
+ "styles": [
18320
+ {
18321
+ "name": "--spw-search-field-options-max-height",
18322
+ "annotation": "prop",
18323
+ "docs": "Hauteur maximale de la liste d'options avant scroll"
18324
+ }
18325
+ ],
18105
18326
  "slots": [],
18106
18327
  "parts": [],
18107
18328
  "states": [],
@@ -99,6 +99,31 @@
99
99
  }
100
100
  ]
101
101
  },
102
+ {
103
+ "name": "spw-alert",
104
+ "description": {
105
+ "kind": "markdown",
106
+ "value": ""
107
+ },
108
+ "attributes": [
109
+ {
110
+ "name": "alert-id",
111
+ "description": "Identifiant unique pour l'alerte"
112
+ },
113
+ {
114
+ "name": "alert-title",
115
+ "description": "Titre de l'alerte"
116
+ },
117
+ {
118
+ "name": "dismissable-text",
119
+ "description": "Texte du bouton pour masquer l'alerte"
120
+ },
121
+ {
122
+ "name": "is-dismissable",
123
+ "description": "Si l'alerte est masquable"
124
+ }
125
+ ]
126
+ },
102
127
  {
103
128
  "name": "spw-avatar",
104
129
  "description": {
@@ -130,6 +130,10 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
130
130
  }
131
131
  switch(bundleId) {
132
132
 
133
+ case 'spw-alert':
134
+ return import(
135
+ /* webpackMode: "lazy" */
136
+ './spw-alert.entry.js').then(processMod, consoleError);
133
137
  case 'spw-avatar':
134
138
  return import(
135
139
  /* webpackMode: "lazy" */