@searchcraft/javascript-sdk 0.7.2 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{store-f6ba3dfb.js → SearchcraftStore-75fac5e0.js} +576 -443
- package/dist/cjs/SearchcraftStore-75fac5e0.js.map +1 -0
- package/dist/cjs/index.cjs.js +2 -3
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/searchcraft-base-search-result_2.cjs.entry.js +152 -0
- package/dist/cjs/searchcraft-base-search-result_2.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-base-search-results.cjs.entry.js +30 -80
- package/dist/cjs/searchcraft-base-search-results.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-button_3.cjs.entry.js +22 -7
- package/dist/cjs/searchcraft-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-facet-list_3.cjs.entry.js +19 -18
- package/dist/cjs/searchcraft-facet-list_3.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-filter-panel.cjs.entry.js +6 -6
- package/dist/cjs/searchcraft-filter-panel.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-input-form_2.cjs.entry.js +20 -33
- package/dist/cjs/searchcraft-input-form_2.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-javascript-sdk.cjs.js +1 -1
- package/dist/cjs/searchcraft-pagination.cjs.entry.js +106 -0
- package/dist/cjs/searchcraft-pagination.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-popover-button.cjs.entry.js +3 -3
- package/dist/cjs/searchcraft-popover-button.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-popover-form.cjs.entry.js +27 -25
- package/dist/cjs/searchcraft-popover-form.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-popover-list-item_2.cjs.entry.js +101 -0
- package/dist/cjs/searchcraft-popover-list-item_2.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-results-info.cjs.entry.js +51 -13
- package/dist/cjs/searchcraft-results-info.cjs.entry.js.map +1 -1
- package/dist/cjs/searchcraft-search-results-per-page.cjs.entry.js +75 -0
- package/dist/cjs/searchcraft-search-results-per-page.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-select.cjs.entry.js +70 -0
- package/dist/cjs/searchcraft-select.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-theme.cjs.entry.js +29 -11
- package/dist/cjs/searchcraft-theme.cjs.entry.js.map +1 -1
- package/dist/cjs/units-fe4d8083.js.map +1 -1
- package/dist/collection/collection-manifest.json +5 -0
- package/dist/collection/components/searchcraft-base-search-result/searchcraft-base-search-result.js +86 -208
- package/dist/collection/components/searchcraft-base-search-result/searchcraft-base-search-result.js.map +1 -1
- package/dist/collection/components/searchcraft-base-search-result-ad/searchcraft-base-search-result-ad.js +73 -0
- package/dist/collection/components/searchcraft-base-search-result-ad/searchcraft-base-search-result-ad.js.map +1 -0
- package/dist/collection/components/searchcraft-base-search-results/searchcraft-base-search-results.js +37 -144
- package/dist/collection/components/searchcraft-base-search-results/searchcraft-base-search-results.js.map +1 -1
- package/dist/collection/components/searchcraft-button/searchcraft-button.js +87 -17
- package/dist/collection/components/searchcraft-button/searchcraft-button.js.map +1 -1
- package/dist/collection/components/searchcraft-error-message/searchcraft-error-message.js +1 -1
- package/dist/collection/components/searchcraft-facet-list/searchcraft-facet-list.js +8 -8
- package/dist/collection/components/searchcraft-facet-list/searchcraft-facet-list.js.map +1 -1
- package/dist/collection/components/searchcraft-filter-panel/searchcraft-filter-panel.js +7 -7
- package/dist/collection/components/searchcraft-filter-panel/searchcraft-filter-panel.js.map +1 -1
- package/dist/collection/components/searchcraft-input-form/searchcraft-input-form.js +10 -14
- package/dist/collection/components/searchcraft-input-form/searchcraft-input-form.js.map +1 -1
- package/dist/collection/components/searchcraft-input-label/searchcraft-input-label.js +1 -1
- package/dist/collection/components/searchcraft-pagination/searchcraft-pagination.js +141 -0
- package/dist/collection/components/searchcraft-pagination/searchcraft-pagination.js.map +1 -0
- package/dist/collection/components/searchcraft-popover-button/searchcraft-popover-button.js +1 -1
- package/dist/collection/components/searchcraft-popover-form/searchcraft-popover-form.js +26 -21
- package/dist/collection/components/searchcraft-popover-form/searchcraft-popover-form.js.map +1 -1
- package/dist/collection/components/searchcraft-popover-list-item/searchcraft-popover-list-item.js +59 -92
- package/dist/collection/components/searchcraft-popover-list-item/searchcraft-popover-list-item.js.map +1 -1
- package/dist/collection/components/searchcraft-popover-list-item-ad/searchcraft-popover-list-item-ad.js +73 -0
- package/dist/collection/components/searchcraft-popover-list-item-ad/searchcraft-popover-list-item-ad.js.map +1 -0
- package/dist/collection/components/searchcraft-popover-list-view/searchcraft-popover-list-view.js +77 -24
- package/dist/collection/components/searchcraft-popover-list-view/searchcraft-popover-list-view.js.map +1 -1
- package/dist/collection/components/searchcraft-results-info/searchcraft-results-info.js +105 -17
- package/dist/collection/components/searchcraft-results-info/searchcraft-results-info.js.map +1 -1
- package/dist/collection/components/searchcraft-search-results-per-page/searchcraft-search-results-per-page.js +129 -0
- package/dist/collection/components/searchcraft-search-results-per-page/searchcraft-search-results-per-page.js.map +1 -0
- package/dist/collection/components/searchcraft-select/searchcraft-select.js +261 -0
- package/dist/collection/components/searchcraft-select/searchcraft-select.js.map +1 -0
- package/dist/collection/components/searchcraft-slider/searchcraft-slider.js +2 -2
- package/dist/collection/components/searchcraft-theme/searchcraft-theme.js +72 -12
- package/dist/collection/components/searchcraft-theme/searchcraft-theme.js.map +1 -1
- package/dist/collection/components/searchcraft-toggle-button/searchcraft-toggle-button.js +7 -6
- package/dist/collection/components/searchcraft-toggle-button/searchcraft-toggle-button.js.map +1 -1
- package/dist/collection/index.js +1 -2
- package/dist/collection/index.js.map +1 -1
- package/dist/collection/provider/SearchcraftStore.js +160 -0
- package/dist/collection/provider/SearchcraftStore.js.map +1 -0
- package/dist/collection/provider/SearchcraftStore.types.js +2 -0
- package/dist/collection/provider/SearchcraftStore.types.js.map +1 -0
- package/dist/collection/provider/store.js +2 -136
- package/dist/collection/provider/store.js.map +1 -1
- package/dist/collection/utils/units.js.map +1 -1
- package/dist/components/index.js +11 -1
- package/dist/components/index.js.map +1 -1
- package/dist/components/{p-a75ef832.js → p-0e393fe1.js} +2 -2
- package/dist/components/{p-a75ef832.js.map → p-0e393fe1.js.map} +1 -1
- package/dist/components/p-25ee7496.js +58 -0
- package/dist/components/p-25ee7496.js.map +1 -0
- package/dist/components/{p-936e2ed4.js → p-38419178.js} +576 -442
- package/dist/components/p-38419178.js.map +1 -0
- package/dist/components/{p-1234974c.js → p-433f974c.js} +9 -8
- package/dist/components/p-433f974c.js.map +1 -0
- package/dist/components/{p-4b92ae26.js → p-4e9cd62e.js} +4 -4
- package/dist/components/{p-4b92ae26.js.map → p-4e9cd62e.js.map} +1 -1
- package/dist/components/{p-755f491b.js → p-6104fe5d.js} +2 -2
- package/dist/components/p-6104fe5d.js.map +1 -0
- package/dist/components/{p-b4a8fcbe.js → p-97332d3e.js} +51 -59
- package/dist/components/p-97332d3e.js.map +1 -0
- package/dist/components/{p-960ddc89.js → p-ae78be68.js} +17 -21
- package/dist/components/p-ae78be68.js.map +1 -0
- package/dist/components/p-bf6a086a.js +92 -0
- package/dist/components/p-bf6a086a.js.map +1 -0
- package/dist/components/p-bff4d3fc.js +65 -0
- package/dist/components/p-bff4d3fc.js.map +1 -0
- package/dist/components/{p-521fe971.js → p-d19bf6ff.js} +25 -8
- package/dist/components/p-d19bf6ff.js.map +1 -0
- package/dist/components/p-de4a48b1.js +65 -0
- package/dist/components/p-de4a48b1.js.map +1 -0
- package/dist/components/{p-ca881e5c.js → p-e55a7970.js} +2 -2
- package/dist/components/{p-ca881e5c.js.map → p-e55a7970.js.map} +1 -1
- package/dist/components/p-ec0d230e.js +75 -0
- package/dist/components/p-ec0d230e.js.map +1 -0
- package/dist/components/{p-54998882.js → p-fc7cda96.js} +10 -10
- package/dist/components/p-fc7cda96.js.map +1 -0
- package/dist/components/searchcraft-base-search-result-ad.d.ts +11 -0
- package/dist/components/searchcraft-base-search-result-ad.js +8 -0
- package/dist/components/searchcraft-base-search-result-ad.js.map +1 -0
- package/dist/components/searchcraft-base-search-result.js +1 -1
- package/dist/components/searchcraft-base-search-results.js +44 -89
- package/dist/components/searchcraft-base-search-results.js.map +1 -1
- package/dist/components/searchcraft-button.js +1 -1
- package/dist/components/searchcraft-error-message.js +1 -1
- package/dist/components/searchcraft-facet-list.js +1 -1
- package/dist/components/searchcraft-filter-panel.js +9 -9
- package/dist/components/searchcraft-filter-panel.js.map +1 -1
- package/dist/components/searchcraft-input-form.js +1 -1
- package/dist/components/searchcraft-input-label.js +1 -1
- package/dist/components/searchcraft-pagination.d.ts +11 -0
- package/dist/components/searchcraft-pagination.js +135 -0
- package/dist/components/searchcraft-pagination.js.map +1 -0
- package/dist/components/searchcraft-popover-button.js +2 -2
- package/dist/components/searchcraft-popover-form.js +41 -30
- package/dist/components/searchcraft-popover-form.js.map +1 -1
- package/dist/components/searchcraft-popover-list-item-ad.d.ts +11 -0
- package/dist/components/searchcraft-popover-list-item-ad.js +8 -0
- package/dist/components/searchcraft-popover-list-item-ad.js.map +1 -0
- package/dist/components/searchcraft-popover-list-item.js +1 -1
- package/dist/components/searchcraft-popover-list-view.js +1 -1
- package/dist/components/searchcraft-results-info.js +60 -17
- package/dist/components/searchcraft-results-info.js.map +1 -1
- package/dist/components/searchcraft-search-results-per-page.d.ts +11 -0
- package/dist/components/searchcraft-search-results-per-page.js +105 -0
- package/dist/components/searchcraft-search-results-per-page.js.map +1 -0
- package/dist/components/searchcraft-select.d.ts +11 -0
- package/dist/components/searchcraft-select.js +8 -0
- package/dist/components/searchcraft-select.js.map +1 -0
- package/dist/components/searchcraft-slider.js +1 -1
- package/dist/components/searchcraft-theme.js +34 -13
- package/dist/components/searchcraft-theme.js.map +1 -1
- package/dist/components/searchcraft-toggle-button.js +1 -1
- package/dist/esm/{store-aa071d9c.js → SearchcraftStore-3cfd565a.js} +576 -442
- package/dist/esm/SearchcraftStore-3cfd565a.js.map +1 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/searchcraft-base-search-result_2.entry.js +147 -0
- package/dist/esm/searchcraft-base-search-result_2.entry.js.map +1 -0
- package/dist/esm/searchcraft-base-search-results.entry.js +30 -80
- package/dist/esm/searchcraft-base-search-results.entry.js.map +1 -1
- package/dist/esm/searchcraft-button_3.entry.js +22 -7
- package/dist/esm/searchcraft-button_3.entry.js.map +1 -1
- package/dist/esm/searchcraft-facet-list_3.entry.js +17 -16
- package/dist/esm/searchcraft-facet-list_3.entry.js.map +1 -1
- package/dist/esm/searchcraft-filter-panel.entry.js +5 -5
- package/dist/esm/searchcraft-filter-panel.entry.js.map +1 -1
- package/dist/esm/searchcraft-input-form_2.entry.js +19 -32
- package/dist/esm/searchcraft-input-form_2.entry.js.map +1 -1
- package/dist/esm/searchcraft-javascript-sdk.js +1 -1
- package/dist/esm/searchcraft-pagination.entry.js +102 -0
- package/dist/esm/searchcraft-pagination.entry.js.map +1 -0
- package/dist/esm/searchcraft-popover-button.entry.js +2 -2
- package/dist/esm/searchcraft-popover-form.entry.js +20 -18
- package/dist/esm/searchcraft-popover-form.entry.js.map +1 -1
- package/dist/esm/searchcraft-popover-list-item_2.entry.js +96 -0
- package/dist/esm/searchcraft-popover-list-item_2.entry.js.map +1 -0
- package/dist/esm/searchcraft-results-info.entry.js +51 -13
- package/dist/esm/searchcraft-results-info.entry.js.map +1 -1
- package/dist/esm/searchcraft-search-results-per-page.entry.js +71 -0
- package/dist/esm/searchcraft-search-results-per-page.entry.js.map +1 -0
- package/dist/esm/searchcraft-select.entry.js +66 -0
- package/dist/esm/searchcraft-select.entry.js.map +1 -0
- package/dist/esm/searchcraft-theme.entry.js +29 -11
- package/dist/esm/searchcraft-theme.entry.js.map +1 -1
- package/dist/esm/{units-b6eba560.js → units-daaf96f5.js} +2 -2
- package/dist/esm/units-daaf96f5.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/index.esm.js +1 -1
- package/dist/searchcraft-javascript-sdk/p-279f3e15.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-279f3e15.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-2bc82b48.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-2bc82b48.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-2dc07b47.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-2dc07b47.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-38419178.js +11 -0
- package/dist/searchcraft-javascript-sdk/p-38419178.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-5e064c07.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-5e064c07.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/{p-755f491b.js → p-6104fe5d.js} +2 -2
- package/dist/searchcraft-javascript-sdk/p-6104fe5d.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-69da4e58.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-69da4e58.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-6bffd3f5.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-6bffd3f5.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-75779e4b.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-75779e4b.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-7f4dd50c.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-9340f4e4.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-9340f4e4.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-a84b1548.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-a84b1548.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-b8ea0454.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-b8ea0454.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-c4a9d8ab.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-c4a9d8ab.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-d2fffca9.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-d2fffca9.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/p-e11de2d6.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-e11de2d6.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js +1 -1
- package/dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js.map +1 -1
- package/dist/types/components/searchcraft-base-search-result/searchcraft-base-search-result.d.ts +20 -41
- package/dist/types/components/searchcraft-base-search-result-ad/searchcraft-base-search-result-ad.d.ts +14 -0
- package/dist/types/components/searchcraft-base-search-results/searchcraft-base-search-results.d.ts +9 -18
- package/dist/types/components/searchcraft-button/searchcraft-button.d.ts +17 -6
- package/dist/types/components/searchcraft-facet-list/searchcraft-facet-list.d.ts +1 -1
- package/dist/types/components/searchcraft-filter-panel/searchcraft-filter-panel.d.ts +2 -2
- package/dist/types/components/searchcraft-input-form/searchcraft-input-form.d.ts +1 -1
- package/dist/types/components/searchcraft-pagination/searchcraft-pagination.d.ts +33 -0
- package/dist/types/components/searchcraft-popover-form/searchcraft-popover-form.d.ts +9 -7
- package/dist/types/components/searchcraft-popover-list-item/searchcraft-popover-list-item.d.ts +9 -12
- package/dist/types/components/searchcraft-popover-list-item-ad/searchcraft-popover-list-item-ad.d.ts +14 -0
- package/dist/types/components/searchcraft-popover-list-view/searchcraft-popover-list-view.d.ts +7 -4
- package/dist/types/components/searchcraft-results-info/searchcraft-results-info.d.ts +26 -4
- package/dist/types/components/searchcraft-search-results-per-page/searchcraft-search-results-per-page.d.ts +33 -0
- package/dist/types/components/searchcraft-select/searchcraft-select.d.ts +64 -0
- package/dist/types/components/searchcraft-theme/searchcraft-theme.d.ts +11 -2
- package/dist/types/components/searchcraft-toggle-button/searchcraft-toggle-button.d.ts +1 -1
- package/dist/types/components.d.ts +444 -170
- package/dist/types/index.d.ts +1 -2
- package/dist/types/provider/SearchcraftStore.d.ts +4 -0
- package/dist/types/provider/SearchcraftStore.types.d.ts +44 -0
- package/dist/types/provider/store.d.ts +2 -34
- package/dist/types/utils/units.d.ts +1 -1
- package/package.json +3 -3
- package/dist/cjs/searchcraft-base-search-result.cjs.entry.js +0 -117
- package/dist/cjs/searchcraft-base-search-result.cjs.entry.js.map +0 -1
- package/dist/cjs/searchcraft-popover-list-item.cjs.entry.js +0 -49
- package/dist/cjs/searchcraft-popover-list-item.cjs.entry.js.map +0 -1
- package/dist/cjs/store-f6ba3dfb.js.map +0 -1
- package/dist/collection/types/_shared.types.js +0 -2
- package/dist/collection/types/_shared.types.js.map +0 -1
- package/dist/collection/types/index.js +0 -5
- package/dist/collection/types/index.js.map +0 -1
- package/dist/collection/types/searchcraft-base-search-results.types.js +0 -2
- package/dist/collection/types/searchcraft-base-search-results.types.js.map +0 -1
- package/dist/collection/types/searchcraft-filter-panel.types.js +0 -2
- package/dist/collection/types/searchcraft-filter-panel.types.js.map +0 -1
- package/dist/collection/types/searchcraft-popover-form.types.js +0 -2
- package/dist/collection/types/searchcraft-popover-form.types.js.map +0 -1
- package/dist/components/p-0ef4ab33.js +0 -66
- package/dist/components/p-0ef4ab33.js.map +0 -1
- package/dist/components/p-1234974c.js.map +0 -1
- package/dist/components/p-506cdac1.js +0 -58
- package/dist/components/p-506cdac1.js.map +0 -1
- package/dist/components/p-521fe971.js.map +0 -1
- package/dist/components/p-54998882.js.map +0 -1
- package/dist/components/p-755f491b.js.map +0 -1
- package/dist/components/p-936e2ed4.js.map +0 -1
- package/dist/components/p-960ddc89.js.map +0 -1
- package/dist/components/p-b4a8fcbe.js.map +0 -1
- package/dist/esm/searchcraft-base-search-result.entry.js +0 -113
- package/dist/esm/searchcraft-base-search-result.entry.js.map +0 -1
- package/dist/esm/searchcraft-popover-list-item.entry.js +0 -45
- package/dist/esm/searchcraft-popover-list-item.entry.js.map +0 -1
- package/dist/esm/store-aa071d9c.js.map +0 -1
- package/dist/esm/units-b6eba560.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-109ab0e0.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-109ab0e0.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-26f5263d.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-26f5263d.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-2ff7eb35.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-2ff7eb35.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-36f0532e.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-36f0532e.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-41b6bc5d.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-41b6bc5d.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-57eddb07.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-57eddb07.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-5d6fbee0.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-5d6fbee0.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-64c5a1d2.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-64c5a1d2.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-755f491b.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-936e2ed4.js +0 -11
- package/dist/searchcraft-javascript-sdk/p-936e2ed4.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-c7df8be6.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-c7df8be6.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-eb6058e8.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-eb6058e8.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-faaa4394.entry.js +0 -2
- package/dist/types/types/_shared.types.d.ts +0 -46
- package/dist/types/types/index.d.ts +0 -5
- package/dist/types/types/searchcraft-base-search-results.types.d.ts +0 -11
- package/dist/types/types/searchcraft-filter-panel.types.d.ts +0 -43
- package/dist/types/types/searchcraft-popover-form.types.d.ts +0 -9
- /package/dist/searchcraft-javascript-sdk/{p-faaa4394.entry.js.map → p-7f4dd50c.entry.js.map} +0 -0
- /package/dist/types/{types → themes}/raw.d.ts +0 -0
|
@@ -5,12 +5,10 @@
|
|
|
5
5
|
* It contains typing information for all components that exist in this project.
|
|
6
6
|
*/
|
|
7
7
|
import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
8
|
-
import { PopoverResultMappings, SearchResultMappings } from "
|
|
9
|
-
import {
|
|
10
|
-
|
|
11
|
-
export {
|
|
12
|
-
export { FilterItem } from "./types/searchcraft-filter-panel.types";
|
|
13
|
-
export { SearchcraftConfig } from "@searchcraft/core";
|
|
8
|
+
import { AdClientResponseItem, FilterItem, PopoverResultMappings, SearchClientResponseItem, SearchcraftConfig, SearchResultMappings } from "@searchcraft/core";
|
|
9
|
+
import { SearchcraftSelectOption } from "./components/searchcraft-select/searchcraft-select";
|
|
10
|
+
export { AdClientResponseItem, FilterItem, PopoverResultMappings, SearchClientResponseItem, SearchcraftConfig, SearchResultMappings } from "@searchcraft/core";
|
|
11
|
+
export { SearchcraftSelectOption } from "./components/searchcraft-select/searchcraft-select";
|
|
14
12
|
export namespace Components {
|
|
15
13
|
/**
|
|
16
14
|
* This web component is designed to display detailed information for a single search result.
|
|
@@ -18,18 +16,6 @@ export namespace Components {
|
|
|
18
16
|
* It is consumed within the `searchcraft-base-search-results` component.
|
|
19
17
|
*/
|
|
20
18
|
interface SearchcraftBaseSearchResult {
|
|
21
|
-
/**
|
|
22
|
-
* The body content.
|
|
23
|
-
*/
|
|
24
|
-
"bodyContent": string | undefined;
|
|
25
|
-
/**
|
|
26
|
-
* The link for the button rendered when containerHref is not present.
|
|
27
|
-
*/
|
|
28
|
-
"buttonHref": string | undefined;
|
|
29
|
-
/**
|
|
30
|
-
* The label for the button rendered when containerHref is not present.
|
|
31
|
-
*/
|
|
32
|
-
"buttonLabel": string | undefined;
|
|
33
19
|
/**
|
|
34
20
|
* The relationship between the current document and the link for the button rendered when containerHref is not present.
|
|
35
21
|
*/
|
|
@@ -38,10 +24,6 @@ export namespace Components {
|
|
|
38
24
|
* Where to open the link for the button rendered when containerHref is not present.
|
|
39
25
|
*/
|
|
40
26
|
"buttonTarget": '_blank' | '_self' | '_top' | '_parent';
|
|
41
|
-
/**
|
|
42
|
-
* The link for the containing element.
|
|
43
|
-
*/
|
|
44
|
-
"containerHref": string | undefined;
|
|
45
27
|
/**
|
|
46
28
|
* The relationship between the current document and the link for the containing element.
|
|
47
29
|
*/
|
|
@@ -58,30 +40,18 @@ export namespace Components {
|
|
|
58
40
|
* The position in the document. Used with the "document_clicked" measure event.
|
|
59
41
|
*/
|
|
60
42
|
"documentPosition": number;
|
|
61
|
-
/**
|
|
62
|
-
* The footer content.
|
|
63
|
-
*/
|
|
64
|
-
"footerContent": string | undefined;
|
|
65
|
-
/**
|
|
66
|
-
* The image alternative text.
|
|
67
|
-
*/
|
|
68
|
-
"imageAlt": string | undefined;
|
|
69
43
|
/**
|
|
70
44
|
* The placement of the image.
|
|
71
45
|
*/
|
|
72
46
|
"imagePlacement": 'left' | 'right';
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
"
|
|
81
|
-
/**
|
|
82
|
-
* The title content.
|
|
83
|
-
*/
|
|
84
|
-
"titleContent": string | undefined;
|
|
47
|
+
"item": SearchClientResponseItem | undefined;
|
|
48
|
+
"searchResultMappings": SearchResultMappings | undefined;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
52
|
+
*/
|
|
53
|
+
interface SearchcraftBaseSearchResultAd {
|
|
54
|
+
"adClientResponseItem"?: AdClientResponseItem;
|
|
85
55
|
}
|
|
86
56
|
/**
|
|
87
57
|
* This web component is responsible for displaying the results of a search query.
|
|
@@ -112,10 +82,6 @@ export namespace Components {
|
|
|
112
82
|
* ```
|
|
113
83
|
*/
|
|
114
84
|
interface SearchcraftBaseSearchResults {
|
|
115
|
-
/**
|
|
116
|
-
* How often ads are injected.
|
|
117
|
-
*/
|
|
118
|
-
"adInterval": number;
|
|
119
85
|
/**
|
|
120
86
|
* The label for the button rendered when containerHref is not present for each result.
|
|
121
87
|
*/
|
|
@@ -142,14 +108,6 @@ export namespace Components {
|
|
|
142
108
|
"customStylesForResults": | string
|
|
143
109
|
| Record<string, Record<string, string>>
|
|
144
110
|
| undefined;
|
|
145
|
-
/**
|
|
146
|
-
* Should an ad be placed at the end of the results.
|
|
147
|
-
*/
|
|
148
|
-
"placeAdAtEnd": boolean;
|
|
149
|
-
/**
|
|
150
|
-
* Should an ad be placed at the start of the results.
|
|
151
|
-
*/
|
|
152
|
-
"placeAdAtStart": boolean;
|
|
153
111
|
/**
|
|
154
112
|
* The placement of the image for each result.
|
|
155
113
|
*/
|
|
@@ -165,22 +123,34 @@ export namespace Components {
|
|
|
165
123
|
* It is consumed within the `searchcraft-input-form` component.
|
|
166
124
|
*/
|
|
167
125
|
interface SearchcraftButton {
|
|
126
|
+
/**
|
|
127
|
+
* Whether the button is disabled.
|
|
128
|
+
*/
|
|
129
|
+
"disabled"?: boolean;
|
|
130
|
+
/**
|
|
131
|
+
* Controls the visual representation of the button.
|
|
132
|
+
*/
|
|
133
|
+
"hierarchy"?: 'primary' | 'tertiary';
|
|
168
134
|
/**
|
|
169
135
|
* The icon element.
|
|
170
136
|
*/
|
|
171
|
-
"
|
|
137
|
+
"icon"?: Element;
|
|
172
138
|
/**
|
|
173
139
|
* Should the button only display an icon.
|
|
174
140
|
*/
|
|
175
|
-
"iconOnly"
|
|
141
|
+
"iconOnly"?: boolean;
|
|
176
142
|
/**
|
|
177
143
|
* The position of the icon.
|
|
178
144
|
*/
|
|
179
|
-
"iconPosition"
|
|
145
|
+
"iconPosition"?: 'left' | 'right';
|
|
180
146
|
/**
|
|
181
147
|
* The label for the button.
|
|
182
148
|
*/
|
|
183
149
|
"label": string;
|
|
150
|
+
/**
|
|
151
|
+
* The type of the button.
|
|
152
|
+
*/
|
|
153
|
+
"type"?: 'submit' | 'reset' | 'button';
|
|
184
154
|
}
|
|
185
155
|
/**
|
|
186
156
|
* This web component is designed to display a user-friendly error message when a search query fails, providing clear feedback to users and enhancing their experience when an issue arises during the search process.
|
|
@@ -243,7 +213,7 @@ export namespace Components {
|
|
|
243
213
|
* ```js
|
|
244
214
|
* // index.js
|
|
245
215
|
* const searchInputForm = document.querySelector('searchcraft-input-form');
|
|
246
|
-
*
|
|
216
|
+
* searchInputForm.config = {
|
|
247
217
|
* index: [],
|
|
248
218
|
* readKey: '',
|
|
249
219
|
* endpointUrl: '',
|
|
@@ -302,13 +272,28 @@ export namespace Components {
|
|
|
302
272
|
"inputLabelClassName"?: string | undefined;
|
|
303
273
|
"label": string;
|
|
304
274
|
}
|
|
275
|
+
/**
|
|
276
|
+
* This web component is designed to facilitate pagination of search results.
|
|
277
|
+
* Once a query is submitted, calculates the number for pages.
|
|
278
|
+
* ## Usage
|
|
279
|
+
* ```html
|
|
280
|
+
* <!-- index.html -->
|
|
281
|
+
* <searchcraft-pagination />
|
|
282
|
+
* ```
|
|
283
|
+
*/
|
|
284
|
+
interface SearchcraftPagination {
|
|
285
|
+
/**
|
|
286
|
+
* The custom styles object.
|
|
287
|
+
*/
|
|
288
|
+
"customStyles"?: string;
|
|
289
|
+
}
|
|
305
290
|
/**
|
|
306
291
|
* Renders a button which, when clicked, turns on popover visibility.
|
|
307
292
|
*/
|
|
308
293
|
interface SearchcraftPopoverButton {
|
|
309
294
|
}
|
|
310
295
|
/**
|
|
311
|
-
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field.
|
|
296
|
+
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field, or when a popover-button is pressed.
|
|
312
297
|
* ## Usage
|
|
313
298
|
* ```html
|
|
314
299
|
* <!-- index.html -->
|
|
@@ -363,56 +348,128 @@ export namespace Components {
|
|
|
363
348
|
* The document position relative to the search results (For Measure)
|
|
364
349
|
*/
|
|
365
350
|
"documentPosition": number;
|
|
351
|
+
"item": SearchClientResponseItem | undefined;
|
|
352
|
+
"popoverResultMappings": PopoverResultMappings | undefined;
|
|
353
|
+
}
|
|
354
|
+
/**
|
|
355
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
356
|
+
*/
|
|
357
|
+
interface SearchcraftPopoverListItemAd {
|
|
358
|
+
"adClientResponseItem"?: AdClientResponseItem;
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* This web component is designed to display a list of results within a popover interface.
|
|
362
|
+
* It is consumed within the `searchcraft-popover-form` component.
|
|
363
|
+
* ## Usage
|
|
364
|
+
* ```html
|
|
365
|
+
* <!-- index.html -->
|
|
366
|
+
* <searchcraft-popover-list-view />
|
|
367
|
+
* ```
|
|
368
|
+
*/
|
|
369
|
+
interface SearchcraftPopoverListView {
|
|
370
|
+
"adClientResponseItems": AdClientResponseItem[] | undefined;
|
|
366
371
|
/**
|
|
367
|
-
* The
|
|
368
|
-
*/
|
|
369
|
-
"href": string | undefined;
|
|
370
|
-
/**
|
|
371
|
-
* The image alt tag.
|
|
372
|
+
* The mappings that define how the data in the documents are mapped to the list-view-item elements.
|
|
372
373
|
*/
|
|
373
|
-
"
|
|
374
|
+
"popoverResultMappings": PopoverResultMappings | undefined;
|
|
374
375
|
/**
|
|
375
|
-
* The
|
|
376
|
+
* The items to render in the list view.
|
|
376
377
|
*/
|
|
377
|
-
"
|
|
378
|
+
"searchClientResponseItems": SearchClientResponseItem[] | undefined;
|
|
379
|
+
"searchResultsPage": number;
|
|
380
|
+
"searchResultsPerPage": number;
|
|
381
|
+
}
|
|
382
|
+
/**
|
|
383
|
+
* This web component is designed to display the number of results returned from a search query.
|
|
384
|
+
* ## Usage
|
|
385
|
+
* ```html
|
|
386
|
+
* <!-- index.html -->
|
|
387
|
+
* <script>
|
|
388
|
+
* const resultsInfo = document.querySelector('searchcraft-results-info');
|
|
389
|
+
* resultsInfo.customFormatter = (range, count, responseTime) =>
|
|
390
|
+
* `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`;
|
|
391
|
+
* </script>
|
|
392
|
+
* <searchcraft-results-info />
|
|
393
|
+
* ```
|
|
394
|
+
*/
|
|
395
|
+
interface SearchcraftResultsInfo {
|
|
378
396
|
/**
|
|
379
|
-
* The
|
|
397
|
+
* The custom formatter for the resulting string.
|
|
398
|
+
* @example ```ts resultsInfo.customFormatter = (range, count, responseTime) => `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`; ```
|
|
380
399
|
*/
|
|
381
|
-
"
|
|
400
|
+
"customFormatter"?: (
|
|
401
|
+
range: [string, string],
|
|
402
|
+
count: string,
|
|
403
|
+
responseTime: string,
|
|
404
|
+
) => void;
|
|
382
405
|
/**
|
|
383
|
-
* The
|
|
406
|
+
* The custom styles object.
|
|
384
407
|
*/
|
|
385
|
-
"
|
|
408
|
+
"customStyles"?: string;
|
|
386
409
|
}
|
|
387
410
|
/**
|
|
388
|
-
* This web component is designed to
|
|
389
|
-
* It is consumed within the `searchcraft-popover-form` component.
|
|
411
|
+
* This web component is designed to choose the number of search results displayed.
|
|
390
412
|
* ## Usage
|
|
391
413
|
* ```html
|
|
392
414
|
* <!-- index.html -->
|
|
393
|
-
* <searchcraft-
|
|
415
|
+
* <searchcraft-search-results-per-page increment="20" />
|
|
394
416
|
* ```
|
|
395
417
|
*/
|
|
396
|
-
interface
|
|
418
|
+
interface SearchcraftSearchResultsPerPage {
|
|
397
419
|
/**
|
|
398
|
-
* The
|
|
420
|
+
* The custom styles object.
|
|
399
421
|
*/
|
|
400
|
-
"
|
|
422
|
+
"customStyles"?: string;
|
|
401
423
|
/**
|
|
402
|
-
* The
|
|
424
|
+
* The amount the options will increase (e.g. 20 = [20, 40, 60, 80, 100]). The base value is defined by the `searchResultsPerPage` option in the configuration.
|
|
403
425
|
*/
|
|
404
|
-
"
|
|
426
|
+
"increment": string | number;
|
|
405
427
|
}
|
|
406
428
|
/**
|
|
407
|
-
* This web component is designed to
|
|
408
|
-
* It provides users with real-time feedback on the scale of the results, such as the total number of items found.
|
|
429
|
+
* This web component is designed to allow users to select between a group of options.
|
|
409
430
|
* ## Usage
|
|
410
431
|
* ```html
|
|
411
432
|
* <!-- index.html -->
|
|
412
|
-
* <searchcraft-
|
|
433
|
+
* <searchcraft-select
|
|
434
|
+
* inputId="searchcraft-select"
|
|
435
|
+
* name="searchcraft-select"
|
|
436
|
+
* options="[{ label: 'label', value: 'value' }]"
|
|
437
|
+
* />
|
|
413
438
|
* ```
|
|
414
439
|
*/
|
|
415
|
-
interface
|
|
440
|
+
interface SearchcraftSelect {
|
|
441
|
+
/**
|
|
442
|
+
* The caption displayed below the select input.
|
|
443
|
+
*/
|
|
444
|
+
"caption"?: string;
|
|
445
|
+
/**
|
|
446
|
+
* A custom styles object.
|
|
447
|
+
*/
|
|
448
|
+
"customStyles"?: string;
|
|
449
|
+
/**
|
|
450
|
+
* Whether the select input is disabled.
|
|
451
|
+
*/
|
|
452
|
+
"disabled"?: boolean;
|
|
453
|
+
/**
|
|
454
|
+
* The ID for the select input.
|
|
455
|
+
*/
|
|
456
|
+
"inputId": string;
|
|
457
|
+
/**
|
|
458
|
+
* The label of the select input.
|
|
459
|
+
*/
|
|
460
|
+
"label"?: string;
|
|
461
|
+
/**
|
|
462
|
+
* The ID for the label of the select input.
|
|
463
|
+
*/
|
|
464
|
+
"labelId"?: string;
|
|
465
|
+
/**
|
|
466
|
+
* The name of the select input.
|
|
467
|
+
*/
|
|
468
|
+
"name": string;
|
|
469
|
+
/**
|
|
470
|
+
* The options for the select input.
|
|
471
|
+
*/
|
|
472
|
+
"options": SearchcraftSelectOption[] | string;
|
|
416
473
|
}
|
|
417
474
|
/**
|
|
418
475
|
* This web component is designed to allow users to select a value from a range defined by a minimum and maximum value.
|
|
@@ -443,10 +500,18 @@ export namespace Components {
|
|
|
443
500
|
* ## Usage
|
|
444
501
|
* ```html
|
|
445
502
|
* <!-- index.html -->
|
|
446
|
-
* <searchcraft-theme />
|
|
503
|
+
* <searchcraft-theme theme="light" custom-theme="{}" />
|
|
447
504
|
* ```
|
|
448
505
|
*/
|
|
449
506
|
interface SearchcraftTheme {
|
|
507
|
+
/**
|
|
508
|
+
* The custom theme configuration object.
|
|
509
|
+
*/
|
|
510
|
+
"customTheme": string;
|
|
511
|
+
/**
|
|
512
|
+
* The name of the theme.
|
|
513
|
+
*/
|
|
514
|
+
"theme": string;
|
|
450
515
|
}
|
|
451
516
|
/**
|
|
452
517
|
* This web component simulates a light switch functionality, providing a simple and intuitive toggle between two states—on and off.
|
|
@@ -479,6 +544,10 @@ export interface SearchcraftInputFormCustomEvent<T> extends CustomEvent<T> {
|
|
|
479
544
|
detail: T;
|
|
480
545
|
target: HTMLSearchcraftInputFormElement;
|
|
481
546
|
}
|
|
547
|
+
export interface SearchcraftSelectCustomEvent<T> extends CustomEvent<T> {
|
|
548
|
+
detail: T;
|
|
549
|
+
target: HTMLSearchcraftSelectElement;
|
|
550
|
+
}
|
|
482
551
|
export interface SearchcraftSliderCustomEvent<T> extends CustomEvent<T> {
|
|
483
552
|
detail: T;
|
|
484
553
|
target: HTMLSearchcraftSliderElement;
|
|
@@ -499,6 +568,15 @@ declare global {
|
|
|
499
568
|
prototype: HTMLSearchcraftBaseSearchResultElement;
|
|
500
569
|
new (): HTMLSearchcraftBaseSearchResultElement;
|
|
501
570
|
};
|
|
571
|
+
/**
|
|
572
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
573
|
+
*/
|
|
574
|
+
interface HTMLSearchcraftBaseSearchResultAdElement extends Components.SearchcraftBaseSearchResultAd, HTMLStencilElement {
|
|
575
|
+
}
|
|
576
|
+
var HTMLSearchcraftBaseSearchResultAdElement: {
|
|
577
|
+
prototype: HTMLSearchcraftBaseSearchResultAdElement;
|
|
578
|
+
new (): HTMLSearchcraftBaseSearchResultAdElement;
|
|
579
|
+
};
|
|
502
580
|
interface HTMLSearchcraftBaseSearchResultsElementEventMap {
|
|
503
581
|
"noResults": void;
|
|
504
582
|
}
|
|
@@ -646,7 +724,7 @@ declare global {
|
|
|
646
724
|
* ```js
|
|
647
725
|
* // index.js
|
|
648
726
|
* const searchInputForm = document.querySelector('searchcraft-input-form');
|
|
649
|
-
*
|
|
727
|
+
* searchInputForm.config = {
|
|
650
728
|
* index: [],
|
|
651
729
|
* readKey: '',
|
|
652
730
|
* endpointUrl: '',
|
|
@@ -684,6 +762,21 @@ declare global {
|
|
|
684
762
|
prototype: HTMLSearchcraftInputLabelElement;
|
|
685
763
|
new (): HTMLSearchcraftInputLabelElement;
|
|
686
764
|
};
|
|
765
|
+
/**
|
|
766
|
+
* This web component is designed to facilitate pagination of search results.
|
|
767
|
+
* Once a query is submitted, calculates the number for pages.
|
|
768
|
+
* ## Usage
|
|
769
|
+
* ```html
|
|
770
|
+
* <!-- index.html -->
|
|
771
|
+
* <searchcraft-pagination />
|
|
772
|
+
* ```
|
|
773
|
+
*/
|
|
774
|
+
interface HTMLSearchcraftPaginationElement extends Components.SearchcraftPagination, HTMLStencilElement {
|
|
775
|
+
}
|
|
776
|
+
var HTMLSearchcraftPaginationElement: {
|
|
777
|
+
prototype: HTMLSearchcraftPaginationElement;
|
|
778
|
+
new (): HTMLSearchcraftPaginationElement;
|
|
779
|
+
};
|
|
687
780
|
/**
|
|
688
781
|
* Renders a button which, when clicked, turns on popover visibility.
|
|
689
782
|
*/
|
|
@@ -694,7 +787,7 @@ declare global {
|
|
|
694
787
|
new (): HTMLSearchcraftPopoverButtonElement;
|
|
695
788
|
};
|
|
696
789
|
/**
|
|
697
|
-
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field.
|
|
790
|
+
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field, or when a popover-button is pressed.
|
|
698
791
|
* ## Usage
|
|
699
792
|
* ```html
|
|
700
793
|
* <!-- index.html -->
|
|
@@ -734,6 +827,15 @@ declare global {
|
|
|
734
827
|
prototype: HTMLSearchcraftPopoverListItemElement;
|
|
735
828
|
new (): HTMLSearchcraftPopoverListItemElement;
|
|
736
829
|
};
|
|
830
|
+
/**
|
|
831
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
832
|
+
*/
|
|
833
|
+
interface HTMLSearchcraftPopoverListItemAdElement extends Components.SearchcraftPopoverListItemAd, HTMLStencilElement {
|
|
834
|
+
}
|
|
835
|
+
var HTMLSearchcraftPopoverListItemAdElement: {
|
|
836
|
+
prototype: HTMLSearchcraftPopoverListItemAdElement;
|
|
837
|
+
new (): HTMLSearchcraftPopoverListItemAdElement;
|
|
838
|
+
};
|
|
737
839
|
/**
|
|
738
840
|
* This web component is designed to display a list of results within a popover interface.
|
|
739
841
|
* It is consumed within the `searchcraft-popover-form` component.
|
|
@@ -751,10 +853,14 @@ declare global {
|
|
|
751
853
|
};
|
|
752
854
|
/**
|
|
753
855
|
* This web component is designed to display the number of results returned from a search query.
|
|
754
|
-
* It provides users with real-time feedback on the scale of the results, such as the total number of items found.
|
|
755
856
|
* ## Usage
|
|
756
857
|
* ```html
|
|
757
858
|
* <!-- index.html -->
|
|
859
|
+
* <script>
|
|
860
|
+
* const resultsInfo = document.querySelector('searchcraft-results-info');
|
|
861
|
+
* resultsInfo.customFormatter = (range, count, responseTime) =>
|
|
862
|
+
* `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`;
|
|
863
|
+
* </script>
|
|
758
864
|
* <searchcraft-results-info />
|
|
759
865
|
* ```
|
|
760
866
|
*/
|
|
@@ -764,6 +870,49 @@ declare global {
|
|
|
764
870
|
prototype: HTMLSearchcraftResultsInfoElement;
|
|
765
871
|
new (): HTMLSearchcraftResultsInfoElement;
|
|
766
872
|
};
|
|
873
|
+
/**
|
|
874
|
+
* This web component is designed to choose the number of search results displayed.
|
|
875
|
+
* ## Usage
|
|
876
|
+
* ```html
|
|
877
|
+
* <!-- index.html -->
|
|
878
|
+
* <searchcraft-search-results-per-page increment="20" />
|
|
879
|
+
* ```
|
|
880
|
+
*/
|
|
881
|
+
interface HTMLSearchcraftSearchResultsPerPageElement extends Components.SearchcraftSearchResultsPerPage, HTMLStencilElement {
|
|
882
|
+
}
|
|
883
|
+
var HTMLSearchcraftSearchResultsPerPageElement: {
|
|
884
|
+
prototype: HTMLSearchcraftSearchResultsPerPageElement;
|
|
885
|
+
new (): HTMLSearchcraftSearchResultsPerPageElement;
|
|
886
|
+
};
|
|
887
|
+
interface HTMLSearchcraftSelectElementEventMap {
|
|
888
|
+
"selectChange": string;
|
|
889
|
+
}
|
|
890
|
+
/**
|
|
891
|
+
* This web component is designed to allow users to select between a group of options.
|
|
892
|
+
* ## Usage
|
|
893
|
+
* ```html
|
|
894
|
+
* <!-- index.html -->
|
|
895
|
+
* <searchcraft-select
|
|
896
|
+
* inputId="searchcraft-select"
|
|
897
|
+
* name="searchcraft-select"
|
|
898
|
+
* options="[{ label: 'label', value: 'value' }]"
|
|
899
|
+
* />
|
|
900
|
+
* ```
|
|
901
|
+
*/
|
|
902
|
+
interface HTMLSearchcraftSelectElement extends Components.SearchcraftSelect, HTMLStencilElement {
|
|
903
|
+
addEventListener<K extends keyof HTMLSearchcraftSelectElementEventMap>(type: K, listener: (this: HTMLSearchcraftSelectElement, ev: SearchcraftSelectCustomEvent<HTMLSearchcraftSelectElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
904
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
905
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
906
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
907
|
+
removeEventListener<K extends keyof HTMLSearchcraftSelectElementEventMap>(type: K, listener: (this: HTMLSearchcraftSelectElement, ev: SearchcraftSelectCustomEvent<HTMLSearchcraftSelectElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
908
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
909
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
910
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
911
|
+
}
|
|
912
|
+
var HTMLSearchcraftSelectElement: {
|
|
913
|
+
prototype: HTMLSearchcraftSelectElement;
|
|
914
|
+
new (): HTMLSearchcraftSelectElement;
|
|
915
|
+
};
|
|
767
916
|
interface HTMLSearchcraftSliderElementEventMap {
|
|
768
917
|
"rangeChanged": any;
|
|
769
918
|
}
|
|
@@ -792,7 +941,7 @@ declare global {
|
|
|
792
941
|
* ## Usage
|
|
793
942
|
* ```html
|
|
794
943
|
* <!-- index.html -->
|
|
795
|
-
* <searchcraft-theme />
|
|
944
|
+
* <searchcraft-theme theme="light" custom-theme="{}" />
|
|
796
945
|
* ```
|
|
797
946
|
*/
|
|
798
947
|
interface HTMLSearchcraftThemeElement extends Components.SearchcraftTheme, HTMLStencilElement {
|
|
@@ -824,6 +973,7 @@ declare global {
|
|
|
824
973
|
};
|
|
825
974
|
interface HTMLElementTagNameMap {
|
|
826
975
|
"searchcraft-base-search-result": HTMLSearchcraftBaseSearchResultElement;
|
|
976
|
+
"searchcraft-base-search-result-ad": HTMLSearchcraftBaseSearchResultAdElement;
|
|
827
977
|
"searchcraft-base-search-results": HTMLSearchcraftBaseSearchResultsElement;
|
|
828
978
|
"searchcraft-button": HTMLSearchcraftButtonElement;
|
|
829
979
|
"searchcraft-error-message": HTMLSearchcraftErrorMessageElement;
|
|
@@ -831,11 +981,15 @@ declare global {
|
|
|
831
981
|
"searchcraft-filter-panel": HTMLSearchcraftFilterPanelElement;
|
|
832
982
|
"searchcraft-input-form": HTMLSearchcraftInputFormElement;
|
|
833
983
|
"searchcraft-input-label": HTMLSearchcraftInputLabelElement;
|
|
984
|
+
"searchcraft-pagination": HTMLSearchcraftPaginationElement;
|
|
834
985
|
"searchcraft-popover-button": HTMLSearchcraftPopoverButtonElement;
|
|
835
986
|
"searchcraft-popover-form": HTMLSearchcraftPopoverFormElement;
|
|
836
987
|
"searchcraft-popover-list-item": HTMLSearchcraftPopoverListItemElement;
|
|
988
|
+
"searchcraft-popover-list-item-ad": HTMLSearchcraftPopoverListItemAdElement;
|
|
837
989
|
"searchcraft-popover-list-view": HTMLSearchcraftPopoverListViewElement;
|
|
838
990
|
"searchcraft-results-info": HTMLSearchcraftResultsInfoElement;
|
|
991
|
+
"searchcraft-search-results-per-page": HTMLSearchcraftSearchResultsPerPageElement;
|
|
992
|
+
"searchcraft-select": HTMLSearchcraftSelectElement;
|
|
839
993
|
"searchcraft-slider": HTMLSearchcraftSliderElement;
|
|
840
994
|
"searchcraft-theme": HTMLSearchcraftThemeElement;
|
|
841
995
|
"searchcraft-toggle-button": HTMLSearchcraftToggleButtonElement;
|
|
@@ -848,18 +1002,6 @@ declare namespace LocalJSX {
|
|
|
848
1002
|
* It is consumed within the `searchcraft-base-search-results` component.
|
|
849
1003
|
*/
|
|
850
1004
|
interface SearchcraftBaseSearchResult {
|
|
851
|
-
/**
|
|
852
|
-
* The body content.
|
|
853
|
-
*/
|
|
854
|
-
"bodyContent"?: string | undefined;
|
|
855
|
-
/**
|
|
856
|
-
* The link for the button rendered when containerHref is not present.
|
|
857
|
-
*/
|
|
858
|
-
"buttonHref"?: string | undefined;
|
|
859
|
-
/**
|
|
860
|
-
* The label for the button rendered when containerHref is not present.
|
|
861
|
-
*/
|
|
862
|
-
"buttonLabel"?: string | undefined;
|
|
863
1005
|
/**
|
|
864
1006
|
* The relationship between the current document and the link for the button rendered when containerHref is not present.
|
|
865
1007
|
*/
|
|
@@ -868,10 +1010,6 @@ declare namespace LocalJSX {
|
|
|
868
1010
|
* Where to open the link for the button rendered when containerHref is not present.
|
|
869
1011
|
*/
|
|
870
1012
|
"buttonTarget"?: '_blank' | '_self' | '_top' | '_parent';
|
|
871
|
-
/**
|
|
872
|
-
* The link for the containing element.
|
|
873
|
-
*/
|
|
874
|
-
"containerHref"?: string | undefined;
|
|
875
1013
|
/**
|
|
876
1014
|
* The relationship between the current document and the link for the containing element.
|
|
877
1015
|
*/
|
|
@@ -888,30 +1026,18 @@ declare namespace LocalJSX {
|
|
|
888
1026
|
* The position in the document. Used with the "document_clicked" measure event.
|
|
889
1027
|
*/
|
|
890
1028
|
"documentPosition"?: number;
|
|
891
|
-
/**
|
|
892
|
-
* The footer content.
|
|
893
|
-
*/
|
|
894
|
-
"footerContent"?: string | undefined;
|
|
895
|
-
/**
|
|
896
|
-
* The image alternative text.
|
|
897
|
-
*/
|
|
898
|
-
"imageAlt"?: string | undefined;
|
|
899
1029
|
/**
|
|
900
1030
|
* The placement of the image.
|
|
901
1031
|
*/
|
|
902
1032
|
"imagePlacement"?: 'left' | 'right';
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
"
|
|
911
|
-
/**
|
|
912
|
-
* The title content.
|
|
913
|
-
*/
|
|
914
|
-
"titleContent"?: string | undefined;
|
|
1033
|
+
"item"?: SearchClientResponseItem | undefined;
|
|
1034
|
+
"searchResultMappings"?: SearchResultMappings | undefined;
|
|
1035
|
+
}
|
|
1036
|
+
/**
|
|
1037
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
1038
|
+
*/
|
|
1039
|
+
interface SearchcraftBaseSearchResultAd {
|
|
1040
|
+
"adClientResponseItem"?: AdClientResponseItem;
|
|
915
1041
|
}
|
|
916
1042
|
/**
|
|
917
1043
|
* This web component is responsible for displaying the results of a search query.
|
|
@@ -942,10 +1068,6 @@ declare namespace LocalJSX {
|
|
|
942
1068
|
* ```
|
|
943
1069
|
*/
|
|
944
1070
|
interface SearchcraftBaseSearchResults {
|
|
945
|
-
/**
|
|
946
|
-
* How often ads are injected.
|
|
947
|
-
*/
|
|
948
|
-
"adInterval"?: number;
|
|
949
1071
|
/**
|
|
950
1072
|
* The label for the button rendered when containerHref is not present for each result.
|
|
951
1073
|
*/
|
|
@@ -976,14 +1098,6 @@ declare namespace LocalJSX {
|
|
|
976
1098
|
* When no results are returned.
|
|
977
1099
|
*/
|
|
978
1100
|
"onNoResults"?: (event: SearchcraftBaseSearchResultsCustomEvent<void>) => void;
|
|
979
|
-
/**
|
|
980
|
-
* Should an ad be placed at the end of the results.
|
|
981
|
-
*/
|
|
982
|
-
"placeAdAtEnd"?: boolean;
|
|
983
|
-
/**
|
|
984
|
-
* Should an ad be placed at the start of the results.
|
|
985
|
-
*/
|
|
986
|
-
"placeAdAtStart"?: boolean;
|
|
987
1101
|
/**
|
|
988
1102
|
* The placement of the image for each result.
|
|
989
1103
|
*/
|
|
@@ -999,10 +1113,18 @@ declare namespace LocalJSX {
|
|
|
999
1113
|
* It is consumed within the `searchcraft-input-form` component.
|
|
1000
1114
|
*/
|
|
1001
1115
|
interface SearchcraftButton {
|
|
1116
|
+
/**
|
|
1117
|
+
* Whether the button is disabled.
|
|
1118
|
+
*/
|
|
1119
|
+
"disabled"?: boolean;
|
|
1120
|
+
/**
|
|
1121
|
+
* Controls the visual representation of the button.
|
|
1122
|
+
*/
|
|
1123
|
+
"hierarchy"?: 'primary' | 'tertiary';
|
|
1002
1124
|
/**
|
|
1003
1125
|
* The icon element.
|
|
1004
1126
|
*/
|
|
1005
|
-
"
|
|
1127
|
+
"icon"?: Element;
|
|
1006
1128
|
/**
|
|
1007
1129
|
* Should the button only display an icon.
|
|
1008
1130
|
*/
|
|
@@ -1010,15 +1132,19 @@ declare namespace LocalJSX {
|
|
|
1010
1132
|
/**
|
|
1011
1133
|
* The position of the icon.
|
|
1012
1134
|
*/
|
|
1013
|
-
"iconPosition"?:
|
|
1135
|
+
"iconPosition"?: 'left' | 'right';
|
|
1014
1136
|
/**
|
|
1015
1137
|
* The label for the button.
|
|
1016
1138
|
*/
|
|
1017
1139
|
"label"?: string;
|
|
1018
1140
|
/**
|
|
1019
|
-
*
|
|
1141
|
+
* The event fired when the button is clicked.
|
|
1020
1142
|
*/
|
|
1021
1143
|
"onButtonClick"?: (event: SearchcraftButtonCustomEvent<void>) => void;
|
|
1144
|
+
/**
|
|
1145
|
+
* The type of the button.
|
|
1146
|
+
*/
|
|
1147
|
+
"type"?: 'submit' | 'reset' | 'button';
|
|
1022
1148
|
}
|
|
1023
1149
|
/**
|
|
1024
1150
|
* This web component is designed to display a user-friendly error message when a search query fails, providing clear feedback to users and enhancing their experience when an issue arises during the search process.
|
|
@@ -1085,7 +1211,7 @@ declare namespace LocalJSX {
|
|
|
1085
1211
|
* ```js
|
|
1086
1212
|
* // index.js
|
|
1087
1213
|
* const searchInputForm = document.querySelector('searchcraft-input-form');
|
|
1088
|
-
*
|
|
1214
|
+
* searchInputForm.config = {
|
|
1089
1215
|
* index: [],
|
|
1090
1216
|
* readKey: '',
|
|
1091
1217
|
* endpointUrl: '',
|
|
@@ -1168,13 +1294,28 @@ declare namespace LocalJSX {
|
|
|
1168
1294
|
"inputLabelClassName"?: string | undefined;
|
|
1169
1295
|
"label"?: string;
|
|
1170
1296
|
}
|
|
1297
|
+
/**
|
|
1298
|
+
* This web component is designed to facilitate pagination of search results.
|
|
1299
|
+
* Once a query is submitted, calculates the number for pages.
|
|
1300
|
+
* ## Usage
|
|
1301
|
+
* ```html
|
|
1302
|
+
* <!-- index.html -->
|
|
1303
|
+
* <searchcraft-pagination />
|
|
1304
|
+
* ```
|
|
1305
|
+
*/
|
|
1306
|
+
interface SearchcraftPagination {
|
|
1307
|
+
/**
|
|
1308
|
+
* The custom styles object.
|
|
1309
|
+
*/
|
|
1310
|
+
"customStyles"?: string;
|
|
1311
|
+
}
|
|
1171
1312
|
/**
|
|
1172
1313
|
* Renders a button which, when clicked, turns on popover visibility.
|
|
1173
1314
|
*/
|
|
1174
1315
|
interface SearchcraftPopoverButton {
|
|
1175
1316
|
}
|
|
1176
1317
|
/**
|
|
1177
|
-
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field.
|
|
1318
|
+
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field, or when a popover-button is pressed.
|
|
1178
1319
|
* ## Usage
|
|
1179
1320
|
* ```html
|
|
1180
1321
|
* <!-- index.html -->
|
|
@@ -1229,56 +1370,132 @@ declare namespace LocalJSX {
|
|
|
1229
1370
|
* The document position relative to the search results (For Measure)
|
|
1230
1371
|
*/
|
|
1231
1372
|
"documentPosition"?: number;
|
|
1373
|
+
"item"?: SearchClientResponseItem | undefined;
|
|
1374
|
+
"popoverResultMappings"?: PopoverResultMappings | undefined;
|
|
1375
|
+
}
|
|
1376
|
+
/**
|
|
1377
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
1378
|
+
*/
|
|
1379
|
+
interface SearchcraftPopoverListItemAd {
|
|
1380
|
+
"adClientResponseItem"?: AdClientResponseItem;
|
|
1381
|
+
}
|
|
1382
|
+
/**
|
|
1383
|
+
* This web component is designed to display a list of results within a popover interface.
|
|
1384
|
+
* It is consumed within the `searchcraft-popover-form` component.
|
|
1385
|
+
* ## Usage
|
|
1386
|
+
* ```html
|
|
1387
|
+
* <!-- index.html -->
|
|
1388
|
+
* <searchcraft-popover-list-view />
|
|
1389
|
+
* ```
|
|
1390
|
+
*/
|
|
1391
|
+
interface SearchcraftPopoverListView {
|
|
1392
|
+
"adClientResponseItems"?: AdClientResponseItem[] | undefined;
|
|
1232
1393
|
/**
|
|
1233
|
-
* The
|
|
1234
|
-
*/
|
|
1235
|
-
"href"?: string | undefined;
|
|
1236
|
-
/**
|
|
1237
|
-
* The image alt tag.
|
|
1394
|
+
* The mappings that define how the data in the documents are mapped to the list-view-item elements.
|
|
1238
1395
|
*/
|
|
1239
|
-
"
|
|
1396
|
+
"popoverResultMappings"?: PopoverResultMappings | undefined;
|
|
1240
1397
|
/**
|
|
1241
|
-
* The
|
|
1398
|
+
* The items to render in the list view.
|
|
1242
1399
|
*/
|
|
1243
|
-
"
|
|
1400
|
+
"searchClientResponseItems"?: SearchClientResponseItem[] | undefined;
|
|
1401
|
+
"searchResultsPage": number;
|
|
1402
|
+
"searchResultsPerPage": number;
|
|
1403
|
+
}
|
|
1404
|
+
/**
|
|
1405
|
+
* This web component is designed to display the number of results returned from a search query.
|
|
1406
|
+
* ## Usage
|
|
1407
|
+
* ```html
|
|
1408
|
+
* <!-- index.html -->
|
|
1409
|
+
* <script>
|
|
1410
|
+
* const resultsInfo = document.querySelector('searchcraft-results-info');
|
|
1411
|
+
* resultsInfo.customFormatter = (range, count, responseTime) =>
|
|
1412
|
+
* `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`;
|
|
1413
|
+
* </script>
|
|
1414
|
+
* <searchcraft-results-info />
|
|
1415
|
+
* ```
|
|
1416
|
+
*/
|
|
1417
|
+
interface SearchcraftResultsInfo {
|
|
1244
1418
|
/**
|
|
1245
|
-
* The
|
|
1419
|
+
* The custom formatter for the resulting string.
|
|
1420
|
+
* @example ```ts resultsInfo.customFormatter = (range, count, responseTime) => `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`; ```
|
|
1246
1421
|
*/
|
|
1247
|
-
"
|
|
1422
|
+
"customFormatter"?: (
|
|
1423
|
+
range: [string, string],
|
|
1424
|
+
count: string,
|
|
1425
|
+
responseTime: string,
|
|
1426
|
+
) => void;
|
|
1248
1427
|
/**
|
|
1249
|
-
* The
|
|
1428
|
+
* The custom styles object.
|
|
1250
1429
|
*/
|
|
1251
|
-
"
|
|
1430
|
+
"customStyles"?: string;
|
|
1252
1431
|
}
|
|
1253
1432
|
/**
|
|
1254
|
-
* This web component is designed to
|
|
1255
|
-
* It is consumed within the `searchcraft-popover-form` component.
|
|
1433
|
+
* This web component is designed to choose the number of search results displayed.
|
|
1256
1434
|
* ## Usage
|
|
1257
1435
|
* ```html
|
|
1258
1436
|
* <!-- index.html -->
|
|
1259
|
-
* <searchcraft-
|
|
1437
|
+
* <searchcraft-search-results-per-page increment="20" />
|
|
1260
1438
|
* ```
|
|
1261
1439
|
*/
|
|
1262
|
-
interface
|
|
1440
|
+
interface SearchcraftSearchResultsPerPage {
|
|
1263
1441
|
/**
|
|
1264
|
-
* The
|
|
1442
|
+
* The custom styles object.
|
|
1265
1443
|
*/
|
|
1266
|
-
"
|
|
1444
|
+
"customStyles"?: string;
|
|
1267
1445
|
/**
|
|
1268
|
-
* The
|
|
1446
|
+
* The amount the options will increase (e.g. 20 = [20, 40, 60, 80, 100]). The base value is defined by the `searchResultsPerPage` option in the configuration.
|
|
1269
1447
|
*/
|
|
1270
|
-
"
|
|
1448
|
+
"increment"?: string | number;
|
|
1271
1449
|
}
|
|
1272
1450
|
/**
|
|
1273
|
-
* This web component is designed to
|
|
1274
|
-
* It provides users with real-time feedback on the scale of the results, such as the total number of items found.
|
|
1451
|
+
* This web component is designed to allow users to select between a group of options.
|
|
1275
1452
|
* ## Usage
|
|
1276
1453
|
* ```html
|
|
1277
1454
|
* <!-- index.html -->
|
|
1278
|
-
* <searchcraft-
|
|
1455
|
+
* <searchcraft-select
|
|
1456
|
+
* inputId="searchcraft-select"
|
|
1457
|
+
* name="searchcraft-select"
|
|
1458
|
+
* options="[{ label: 'label', value: 'value' }]"
|
|
1459
|
+
* />
|
|
1279
1460
|
* ```
|
|
1280
1461
|
*/
|
|
1281
|
-
interface
|
|
1462
|
+
interface SearchcraftSelect {
|
|
1463
|
+
/**
|
|
1464
|
+
* The caption displayed below the select input.
|
|
1465
|
+
*/
|
|
1466
|
+
"caption"?: string;
|
|
1467
|
+
/**
|
|
1468
|
+
* A custom styles object.
|
|
1469
|
+
*/
|
|
1470
|
+
"customStyles"?: string;
|
|
1471
|
+
/**
|
|
1472
|
+
* Whether the select input is disabled.
|
|
1473
|
+
*/
|
|
1474
|
+
"disabled"?: boolean;
|
|
1475
|
+
/**
|
|
1476
|
+
* The ID for the select input.
|
|
1477
|
+
*/
|
|
1478
|
+
"inputId": string;
|
|
1479
|
+
/**
|
|
1480
|
+
* The label of the select input.
|
|
1481
|
+
*/
|
|
1482
|
+
"label"?: string;
|
|
1483
|
+
/**
|
|
1484
|
+
* The ID for the label of the select input.
|
|
1485
|
+
*/
|
|
1486
|
+
"labelId"?: string;
|
|
1487
|
+
/**
|
|
1488
|
+
* The name of the select input.
|
|
1489
|
+
*/
|
|
1490
|
+
"name": string;
|
|
1491
|
+
/**
|
|
1492
|
+
* The event fired when the select is changed.
|
|
1493
|
+
*/
|
|
1494
|
+
"onSelectChange"?: (event: SearchcraftSelectCustomEvent<string>) => void;
|
|
1495
|
+
/**
|
|
1496
|
+
* The options for the select input.
|
|
1497
|
+
*/
|
|
1498
|
+
"options"?: SearchcraftSelectOption[] | string;
|
|
1282
1499
|
}
|
|
1283
1500
|
/**
|
|
1284
1501
|
* This web component is designed to allow users to select a value from a range defined by a minimum and maximum value.
|
|
@@ -1313,10 +1530,18 @@ declare namespace LocalJSX {
|
|
|
1313
1530
|
* ## Usage
|
|
1314
1531
|
* ```html
|
|
1315
1532
|
* <!-- index.html -->
|
|
1316
|
-
* <searchcraft-theme />
|
|
1533
|
+
* <searchcraft-theme theme="light" custom-theme="{}" />
|
|
1317
1534
|
* ```
|
|
1318
1535
|
*/
|
|
1319
1536
|
interface SearchcraftTheme {
|
|
1537
|
+
/**
|
|
1538
|
+
* The custom theme configuration object.
|
|
1539
|
+
*/
|
|
1540
|
+
"customTheme"?: string;
|
|
1541
|
+
/**
|
|
1542
|
+
* The name of the theme.
|
|
1543
|
+
*/
|
|
1544
|
+
"theme"?: string;
|
|
1320
1545
|
}
|
|
1321
1546
|
/**
|
|
1322
1547
|
* This web component simulates a light switch functionality, providing a simple and intuitive toggle between two states—on and off.
|
|
@@ -1338,6 +1563,7 @@ declare namespace LocalJSX {
|
|
|
1338
1563
|
}
|
|
1339
1564
|
interface IntrinsicElements {
|
|
1340
1565
|
"searchcraft-base-search-result": SearchcraftBaseSearchResult;
|
|
1566
|
+
"searchcraft-base-search-result-ad": SearchcraftBaseSearchResultAd;
|
|
1341
1567
|
"searchcraft-base-search-results": SearchcraftBaseSearchResults;
|
|
1342
1568
|
"searchcraft-button": SearchcraftButton;
|
|
1343
1569
|
"searchcraft-error-message": SearchcraftErrorMessage;
|
|
@@ -1345,11 +1571,15 @@ declare namespace LocalJSX {
|
|
|
1345
1571
|
"searchcraft-filter-panel": SearchcraftFilterPanel;
|
|
1346
1572
|
"searchcraft-input-form": SearchcraftInputForm;
|
|
1347
1573
|
"searchcraft-input-label": SearchcraftInputLabel;
|
|
1574
|
+
"searchcraft-pagination": SearchcraftPagination;
|
|
1348
1575
|
"searchcraft-popover-button": SearchcraftPopoverButton;
|
|
1349
1576
|
"searchcraft-popover-form": SearchcraftPopoverForm;
|
|
1350
1577
|
"searchcraft-popover-list-item": SearchcraftPopoverListItem;
|
|
1578
|
+
"searchcraft-popover-list-item-ad": SearchcraftPopoverListItemAd;
|
|
1351
1579
|
"searchcraft-popover-list-view": SearchcraftPopoverListView;
|
|
1352
1580
|
"searchcraft-results-info": SearchcraftResultsInfo;
|
|
1581
|
+
"searchcraft-search-results-per-page": SearchcraftSearchResultsPerPage;
|
|
1582
|
+
"searchcraft-select": SearchcraftSelect;
|
|
1353
1583
|
"searchcraft-slider": SearchcraftSlider;
|
|
1354
1584
|
"searchcraft-theme": SearchcraftTheme;
|
|
1355
1585
|
"searchcraft-toggle-button": SearchcraftToggleButton;
|
|
@@ -1365,6 +1595,10 @@ declare module "@stencil/core" {
|
|
|
1365
1595
|
* It is consumed within the `searchcraft-base-search-results` component.
|
|
1366
1596
|
*/
|
|
1367
1597
|
"searchcraft-base-search-result": LocalJSX.SearchcraftBaseSearchResult & JSXBase.HTMLAttributes<HTMLSearchcraftBaseSearchResultElement>;
|
|
1598
|
+
/**
|
|
1599
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
1600
|
+
*/
|
|
1601
|
+
"searchcraft-base-search-result-ad": LocalJSX.SearchcraftBaseSearchResultAd & JSXBase.HTMLAttributes<HTMLSearchcraftBaseSearchResultAdElement>;
|
|
1368
1602
|
/**
|
|
1369
1603
|
* This web component is responsible for displaying the results of a search query.
|
|
1370
1604
|
* Once a query is submitted, the component formats and presents an ordered list of the results.
|
|
@@ -1446,7 +1680,7 @@ declare module "@stencil/core" {
|
|
|
1446
1680
|
* ```js
|
|
1447
1681
|
* // index.js
|
|
1448
1682
|
* const searchInputForm = document.querySelector('searchcraft-input-form');
|
|
1449
|
-
*
|
|
1683
|
+
* searchInputForm.config = {
|
|
1450
1684
|
* index: [],
|
|
1451
1685
|
* readKey: '',
|
|
1452
1686
|
* endpointUrl: '',
|
|
@@ -1466,12 +1700,22 @@ declare module "@stencil/core" {
|
|
|
1466
1700
|
* ```
|
|
1467
1701
|
*/
|
|
1468
1702
|
"searchcraft-input-label": LocalJSX.SearchcraftInputLabel & JSXBase.HTMLAttributes<HTMLSearchcraftInputLabelElement>;
|
|
1703
|
+
/**
|
|
1704
|
+
* This web component is designed to facilitate pagination of search results.
|
|
1705
|
+
* Once a query is submitted, calculates the number for pages.
|
|
1706
|
+
* ## Usage
|
|
1707
|
+
* ```html
|
|
1708
|
+
* <!-- index.html -->
|
|
1709
|
+
* <searchcraft-pagination />
|
|
1710
|
+
* ```
|
|
1711
|
+
*/
|
|
1712
|
+
"searchcraft-pagination": LocalJSX.SearchcraftPagination & JSXBase.HTMLAttributes<HTMLSearchcraftPaginationElement>;
|
|
1469
1713
|
/**
|
|
1470
1714
|
* Renders a button which, when clicked, turns on popover visibility.
|
|
1471
1715
|
*/
|
|
1472
1716
|
"searchcraft-popover-button": LocalJSX.SearchcraftPopoverButton & JSXBase.HTMLAttributes<HTMLSearchcraftPopoverButtonElement>;
|
|
1473
1717
|
/**
|
|
1474
|
-
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field.
|
|
1718
|
+
* This web component is designed to display search results in a popover container that dynamically appears when the user interacts with a search input field, or when a popover-button is pressed.
|
|
1475
1719
|
* ## Usage
|
|
1476
1720
|
* ```html
|
|
1477
1721
|
* <!-- index.html -->
|
|
@@ -1501,6 +1745,10 @@ declare module "@stencil/core" {
|
|
|
1501
1745
|
* A single list item rendered in a searchcraft-popover-list-view.
|
|
1502
1746
|
*/
|
|
1503
1747
|
"searchcraft-popover-list-item": LocalJSX.SearchcraftPopoverListItem & JSXBase.HTMLAttributes<HTMLSearchcraftPopoverListItemElement>;
|
|
1748
|
+
/**
|
|
1749
|
+
* A single list item rendered in a searchcraft-popover-list-view.
|
|
1750
|
+
*/
|
|
1751
|
+
"searchcraft-popover-list-item-ad": LocalJSX.SearchcraftPopoverListItemAd & JSXBase.HTMLAttributes<HTMLSearchcraftPopoverListItemAdElement>;
|
|
1504
1752
|
/**
|
|
1505
1753
|
* This web component is designed to display a list of results within a popover interface.
|
|
1506
1754
|
* It is consumed within the `searchcraft-popover-form` component.
|
|
@@ -1513,14 +1761,40 @@ declare module "@stencil/core" {
|
|
|
1513
1761
|
"searchcraft-popover-list-view": LocalJSX.SearchcraftPopoverListView & JSXBase.HTMLAttributes<HTMLSearchcraftPopoverListViewElement>;
|
|
1514
1762
|
/**
|
|
1515
1763
|
* This web component is designed to display the number of results returned from a search query.
|
|
1516
|
-
* It provides users with real-time feedback on the scale of the results, such as the total number of items found.
|
|
1517
1764
|
* ## Usage
|
|
1518
1765
|
* ```html
|
|
1519
1766
|
* <!-- index.html -->
|
|
1767
|
+
* <script>
|
|
1768
|
+
* const resultsInfo = document.querySelector('searchcraft-results-info');
|
|
1769
|
+
* resultsInfo.customFormatter = (range, count, responseTime) =>
|
|
1770
|
+
* `${range[0]}-${range[1]} of ${count} results in ${responseTime}ms`;
|
|
1771
|
+
* </script>
|
|
1520
1772
|
* <searchcraft-results-info />
|
|
1521
1773
|
* ```
|
|
1522
1774
|
*/
|
|
1523
1775
|
"searchcraft-results-info": LocalJSX.SearchcraftResultsInfo & JSXBase.HTMLAttributes<HTMLSearchcraftResultsInfoElement>;
|
|
1776
|
+
/**
|
|
1777
|
+
* This web component is designed to choose the number of search results displayed.
|
|
1778
|
+
* ## Usage
|
|
1779
|
+
* ```html
|
|
1780
|
+
* <!-- index.html -->
|
|
1781
|
+
* <searchcraft-search-results-per-page increment="20" />
|
|
1782
|
+
* ```
|
|
1783
|
+
*/
|
|
1784
|
+
"searchcraft-search-results-per-page": LocalJSX.SearchcraftSearchResultsPerPage & JSXBase.HTMLAttributes<HTMLSearchcraftSearchResultsPerPageElement>;
|
|
1785
|
+
/**
|
|
1786
|
+
* This web component is designed to allow users to select between a group of options.
|
|
1787
|
+
* ## Usage
|
|
1788
|
+
* ```html
|
|
1789
|
+
* <!-- index.html -->
|
|
1790
|
+
* <searchcraft-select
|
|
1791
|
+
* inputId="searchcraft-select"
|
|
1792
|
+
* name="searchcraft-select"
|
|
1793
|
+
* options="[{ label: 'label', value: 'value' }]"
|
|
1794
|
+
* />
|
|
1795
|
+
* ```
|
|
1796
|
+
*/
|
|
1797
|
+
"searchcraft-select": LocalJSX.SearchcraftSelect & JSXBase.HTMLAttributes<HTMLSearchcraftSelectElement>;
|
|
1524
1798
|
/**
|
|
1525
1799
|
* This web component is designed to allow users to select a value from a range defined by a minimum and maximum value.
|
|
1526
1800
|
* The component renders a slider interface, which can be used to visually choose a value between two boundaries.
|
|
@@ -1533,7 +1807,7 @@ declare module "@stencil/core" {
|
|
|
1533
1807
|
* ## Usage
|
|
1534
1808
|
* ```html
|
|
1535
1809
|
* <!-- index.html -->
|
|
1536
|
-
* <searchcraft-theme />
|
|
1810
|
+
* <searchcraft-theme theme="light" custom-theme="{}" />
|
|
1537
1811
|
* ```
|
|
1538
1812
|
*/
|
|
1539
1813
|
"searchcraft-theme": LocalJSX.SearchcraftTheme & JSXBase.HTMLAttributes<HTMLSearchcraftThemeElement>;
|