UNPKG

@claudebernard/search-bar-element

Version:

An element providing some custom stuff.

1,020 lines 352 kB
{ "schemaVersion": "1.0.0", "readme": "", "modules": [ { "kind": "javascript-module", "path": "src/index.ts", "declarations": [], "exports": [ { "kind": "js", "name": "*", "declaration": { "name": "*", "package": "\"./search-bar/search-input/search-input\"" } }, { "kind": "js", "name": "*", "declaration": { "name": "*", "package": "\"./search-bar/search-item-result/search-item-result\"" } }, { "kind": "js", "name": "*", "declaration": { "name": "*", "package": "\"./search-bar/search-categories/search-categories\"" } }, { "kind": "js", "name": "*", "declaration": { "name": "*", "package": "\"./search-bar/search-bar\"" } } ] }, { "kind": "javascript-module", "path": "src/search-bar/properties.interface.ts", "declarations": [], "exports": [] }, { "kind": "javascript-module", "path": "src/search-bar/search-bar.stories.ts", "declarations": [ { "kind": "variable", "name": "meta", "default": "{\n parameters: {\n deepControls: { enabled: true },\n },\n tags: [\"autodocs\"],\n render: (args) => {\n const handleItemSelection = (event: CustomEvent) => {\n console.log(\"🔍 Event: item-selection\", event.detail);\n };\n\n const handleEnterKeyPressed = (event: CustomEvent) => {\n console.log(\"🔍 Event: enter-key-pressed\", event.detail);\n };\n\n const handleSearching = (event: CustomEvent) => {\n console.log(\"🔍 Event: searching\", event.detail);\n };\n\n return html`<div style=\"height: 65vh; width: 100%; margin: auto;\">\n <bcb-search-bar\n .language=${args.language}\n .apiUrl=${args.apiUrl}\n .apiKey=${args.apiKey}\n ?auto-focus=${args.autoFocus}\n .placeholder=${args.placeholder}\n .resultConfig=${args.resultConfig}\n preselected-category=${args.preselectedCategory}\n .listCategoriesDisplayed=${args.listCategoriesDisplayed}\n @item-selection=${handleItemSelection}\n @enter-key-pressed=${handleEnterKeyPressed}\n @searching=${handleSearching}\n >\n </bcb-search-bar>\n </div>`;\n },\n argTypes: {\n language: {\n description: \"The language of the search\",\n table: {\n category: \"Props\",\n },\n },\n apiUrl: {\n description: \"The URL of the API\",\n table: {\n category: \"Props\",\n },\n },\n apiKey: {\n description: \"The ApiKey of the API\",\n table: {\n category: \"Props\",\n },\n },\n autoFocus: {\n description: \"Whether the search bar should be focused on load\",\n table: {\n category: \"Props\",\n },\n },\n placeholder: {\n description: \"The placeholder text\",\n table: {\n category: \"Props\",\n },\n },\n \"resultConfig.highlight\": {\n description: \"Whether to highlight the search term in the results\",\n table: {\n category: \"Result Config\",\n },\n },\n \"resultConfig.displayCategoriesLabel\": {\n description: \"Whether to display label of the categories on result\",\n table: {\n category: \"Result Config\",\n },\n },\n \"resultConfig.displayPictograms\": {\n description: \"Whether to display pictograms on result\",\n table: {\n category: \"Result Config\",\n },\n },\n \"resultConfig.filters\": {\n description: \"Filters to apply on the search results\",\n table: {\n category: \"Result Config\",\n },\n control: {\n type: \"object\",\n },\n },\n \"resultConfig.formattingTextShort\": {\n description: \"If true, result Text will be on shortLabel\",\n table: {\n category: \"Result Config\",\n },\n },\n \"resultConfig.formattingTooltipTextShort\": {\n description: \"If true, result Tooltip text will be on shortLabel\",\n table: {\n category: \"Result Config\",\n },\n },\n \"resultConfig.numberResultsDisplayed\": {\n description: \"Number of results to be displayed + number of result add on scroll\",\n table: {\n category: \"Result Config\",\n },\n },\n preselectedCategory: {\n description: \"Choose the category to be preselected\",\n table: {\n category: \"Categories Config\",\n },\n },\n listCategoriesDisplayed: {\n description: \"Choose categories that will be displayed\",\n table: {\n category: \"Categories Config\",\n },\n },\n // @ts-ignore\n \"--bcb-search-bar-custom-radius\": {\n control: false,\n description: \"CSS token to override search bar radius\",\n table: {\n category: \"Style Tokens\",\n type: { summary: \"CSS Token\" },\n defaultValue: { summary: \"100px\" },\n },\n },\n },\n args: {\n placeholder: \"Médicaments, molécules, produits de parapharmacie, laboratoires...\",\n language: \"fr-FR\",\n apiUrl: DEFAULT_API_URL,\n apiKey: DEFAULT_API_KEY,\n autoFocus: false,\n resultConfig: {\n highlight: false,\n displayCategoriesLabel: false,\n displayPictograms: false,\n formattingTextShort: false,\n formattingTooltipTextShort: false,\n filters: {\n dopingProducts: true,\n deletedProducts: false,\n hospitalProducts: true,\n homeoProducts: true,\n dermatoProducts: true,\n dieteticProducts: true,\n horsAmmProducts: true,\n veterinarProducts: true,\n medicalDevicesProducts: true,\n genericProducts: true,\n accessoriesProducts: true,\n genericAccessoriesProducts: true,\n specialityProducts: false,\n biosimilarsProducts: true,\n },\n numberResultsDisplayed: 20,\n },\n preselectedCategory: ECategories.allCategories,\n listCategoriesDisplayed: [\n ECategories.allCategories,\n ECategories.products,\n ECategories.companies,\n ECategories.molecules,\n ECategories.indications,\n ECategories.atcclass,\n ECategories.commonNames,\n ECategories.genericAccessoriesGroups,\n ],\n },\n} satisfies TypeWithDeepControls<Meta<SearchBarProps>>" }, { "kind": "variable", "name": "Base", "type": { "text": "Story" }, "default": "{\n args: {\n autoFocus: false,\n resultConfig: {\n highlight: false,\n displayCategoriesLabel: false,\n displayPictograms: false,\n formattingTextShort: false,\n formattingTooltipTextShort: false,\n filters: defaultFilters,\n },\n preselectedCategory: ECategories.allCategories,\n listCategoriesDisplayed: [\n ECategories.allCategories,\n ECategories.products,\n ECategories.companies,\n ECategories.molecules,\n ECategories.indications,\n ECategories.atcclass,\n ECategories.commonNames,\n ECategories.genericAccessoriesGroups,\n ],\n },\n}" }, { "kind": "variable", "name": "WithHighlight", "type": { "text": "Story" }, "default": "{\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n highlight: true,\n },\n },\n}" }, { "kind": "variable", "name": "WithTypeCategories", "type": { "text": "Story" }, "default": "{\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n displayCategoriesLabel: true,\n },\n },\n}" }, { "kind": "variable", "name": "WithPictograms", "type": { "text": "Story" }, "default": "{\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n displayPictograms: true,\n },\n },\n}" }, { "kind": "variable", "name": "ShortText", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n formattingTextShort: true,\n },\n },\n}" }, { "kind": "variable", "name": "ShortTooltipText", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n formattingTooltipTextShort: true,\n },\n },\n}" }, { "kind": "variable", "name": "LaboratoriesCategoryPreSelected", "type": { "text": "Story" }, "default": "{\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n },\n preselectedCategory: ECategories.companies,\n },\n}" }, { "kind": "variable", "name": "Only2CategoriesDisplayed", "type": { "text": "Story" }, "default": "{\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n },\n listCategoriesDisplayed: [\n ECategories.companies,\n ECategories.molecules,\n ],\n },\n}" }, { "kind": "variable", "name": "With10ResultsDisplayed", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...Base.args,\n resultConfig: {\n ...Base.args?.resultConfig,\n numberResultsDisplayed: 10,\n },\n },\n}" }, { "kind": "variable", "name": "WithAllConfigOn", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...Base.args,\n autoFocus: true,\n resultConfig: {\n highlight: true,\n displayCategoriesLabel: true,\n displayPictograms: true,\n filters: defaultFilters,\n formattingTextShort: true,\n formattingTooltipTextShort: true,\n numberResultsDisplayed: 50,\n },\n\n listCategoriesDisplayed: [\n ECategories.allCategories,\n ECategories.products,\n ECategories.companies,\n ECategories.molecules,\n ECategories.indications,\n ECategories.atcclass,\n ECategories.commonNames,\n ECategories.genericAccessoriesGroups,\n ],\n },\n}" }, { "kind": "variable", "name": "WithAllTrueFilters", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...WithAllConfigOn.args,\n resultConfig: {\n ...WithAllConfigOn.args?.resultConfig,\n filters: {\n dopingProducts: true,\n deletedProducts: true,\n hospitalProducts: true,\n homeoProducts: true,\n dermatoProducts: true,\n dieteticProducts: true,\n horsAmmProducts: true,\n veterinarProducts: true,\n medicalDevicesProducts: true,\n genericProducts: true,\n accessoriesProducts: true,\n genericAccessoriesProducts: true,\n specialityProducts: true,\n biosimilarsProducts: true,\n },\n },\n },\n}" }, { "kind": "variable", "name": "WithAllFalseFilters", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...WithAllConfigOn.args,\n resultConfig: {\n ...WithAllConfigOn.args?.resultConfig,\n filters: {\n dopingProducts: false,\n deletedProducts: false,\n hospitalProducts: false,\n homeoProducts: false,\n dermatoProducts: false,\n dieteticProducts: false,\n horsAmmProducts: false,\n veterinarProducts: false,\n medicalDevicesProducts: false,\n genericProducts: false,\n accessoriesProducts: false,\n genericAccessoriesProducts: false,\n specialityProducts: false,\n biosimilarsProducts: false,\n },\n },\n },\n}" }, { "kind": "variable", "name": "WithAutoFocus", "type": { "text": "Story" }, "default": "{\n parameters: {\n docs: {\n disable: true,\n },\n },\n args: {\n ...WithAllConfigOn.args,\n autoFocus: true,\n },\n}" } ], "exports": [ { "kind": "js", "name": "default", "declaration": { "name": "meta", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "Base", "declaration": { "name": "Base", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithHighlight", "declaration": { "name": "WithHighlight", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithTypeCategories", "declaration": { "name": "WithTypeCategories", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithPictograms", "declaration": { "name": "WithPictograms", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "ShortText", "declaration": { "name": "ShortText", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "ShortTooltipText", "declaration": { "name": "ShortTooltipText", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "LaboratoriesCategoryPreSelected", "declaration": { "name": "LaboratoriesCategoryPreSelected", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "Only2CategoriesDisplayed", "declaration": { "name": "Only2CategoriesDisplayed", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "With10ResultsDisplayed", "declaration": { "name": "With10ResultsDisplayed", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithAllConfigOn", "declaration": { "name": "WithAllConfigOn", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithAllTrueFilters", "declaration": { "name": "WithAllTrueFilters", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithAllFalseFilters", "declaration": { "name": "WithAllFalseFilters", "module": "src/search-bar/search-bar.stories.ts" } }, { "kind": "js", "name": "WithAutoFocus", "declaration": { "name": "WithAutoFocus", "module": "src/search-bar/search-bar.stories.ts" } } ] }, { "kind": "javascript-module", "path": "src/search-bar/search-bar.ts", "declarations": [ { "kind": "variable", "name": "{ setLocale }" }, { "kind": "class", "description": "BCB search element.", "name": "SearchBar", "members": [ { "kind": "field", "name": "language", "type": { "text": "string" }, "default": "\"fr-FR\"", "attribute": "language" }, { "kind": "field", "name": "apiUrl", "type": { "text": "string" }, "default": "\"https://api.claudebernard.fr/search\"", "attribute": "api-url" }, { "kind": "field", "name": "apiKey", "type": { "text": "string | undefined" }, "attribute": "api-key" }, { "kind": "field", "name": "placeholder", "type": { "text": "string" }, "default": "\"Médicaments, molécules, produits de parapharmacie, laboratoires...\"", "attribute": "placeholder" }, { "kind": "field", "name": "resultConfig", "type": { "text": "ResultConfig" }, "default": "{\n highlight: false,\n displayCategoriesLabel: false,\n displayPictograms: false,\n filters: defaultFilters,\n formattingTextShort: false,\n formattingTooltipTextShort: false,\n numberResultsDisplayed: 50,\n sponsorOrdering: false,\n }", "attribute": "result-config" }, { "kind": "field", "name": "preselectedCategory", "type": { "text": "ECategories" }, "attribute": "preselected-category" }, { "kind": "field", "name": "listCategoriesDisplayed", "type": { "text": "ECategories[]" }, "default": "[\n ECategories.allCategories,\n ECategories.products,\n ECategories.companies,\n ECategories.molecules,\n ECategories.indications,\n ECategories.atcclass,\n ECategories.commonNames,\n ECategories.genericAccessoriesGroups,\n ]", "attribute": "list-categories-displayed" }, { "kind": "field", "name": "autoFocus", "type": { "text": "boolean" }, "default": "false", "attribute": "auto-focus" }, { "kind": "field", "name": "allResult", "type": { "text": "ProductBean[]" }, "privacy": "private", "default": "[]" }, { "kind": "field", "name": "allResultPerCategories", "type": { "text": "SearchFiltersBean | null" }, "privacy": "private", "default": "null" }, { "kind": "field", "name": "searchRequestBody", "type": { "text": "SearchRequestBean" }, "privacy": "private", "default": "defaultRequestBody" }, { "kind": "field", "name": "selectedCategory", "type": { "text": "ECategories" }, "privacy": "private" }, { "kind": "field", "name": "isScrollBarLoaded", "type": { "text": "boolean" }, "privacy": "private", "default": "false" }, { "kind": "field", "name": "isFocused", "type": { "text": "boolean" }, "privacy": "private", "default": "false" }, { "kind": "field", "name": "itemResultContainerRef", "type": { "text": "Ref<HTMLInputElement>" }, "privacy": "private" }, { "kind": "field", "name": "categoriesContainerRef", "type": { "text": "Ref<HTMLDivElement>" }, "privacy": "private" }, { "kind": "field", "name": "searchContainerRef", "type": { "text": "Ref<HTMLDivElement>" }, "privacy": "private" }, { "kind": "field", "name": "currentSearchRequestId", "type": { "text": "number" }, "privacy": "private", "default": "0" }, { "kind": "field", "name": "keyboardSectionIndex", "type": { "text": "number" }, "privacy": "private", "default": "0" }, { "kind": "field", "name": "keyboardCategoryIndex", "type": { "text": "number" }, "privacy": "private", "default": "0" }, { "kind": "field", "name": "keyboardResultIndex", "type": { "text": "number" }, "privacy": "private", "default": "0" }, { "kind": "method", "name": "dispatchEvent", "return": { "type": { "text": "boolean" } }, "parameters": [ { "name": "event", "type": { "text": "Event" } } ] }, { "kind": "method", "name": "focus", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "options", "optional": true, "type": { "text": "FocusOptions" } } ] }, { "kind": "field", "name": "handleOutsideClick", "privacy": "private" }, { "kind": "field", "name": "handleEscapeKey", "privacy": "private" }, { "kind": "method", "name": "renderResultComponents", "privacy": "private" }, { "kind": "method", "name": "renderItemResult", "privacy": "private" }, { "kind": "method", "name": "handleScroll", "privacy": "private", "parameters": [ { "name": "event", "type": { "text": "Event" } } ] }, { "kind": "field", "name": "handleGlobalKeyDown", "privacy": "private" }, { "kind": "method", "name": "handleTabNavigation", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "event", "type": { "text": "KeyboardEvent" } } ] }, { "kind": "method", "name": "handleArrowNavigation", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "event", "type": { "text": "KeyboardEvent" } } ] }, { "kind": "method", "name": "handleArrowInInput", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "isDown", "type": { "text": "boolean" } } ] }, { "kind": "method", "name": "handleArrowInCategories", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "isDown", "type": { "text": "boolean" } } ] }, { "kind": "method", "name": "handleArrowInResults", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "isDown", "type": { "text": "boolean" } } ] }, { "kind": "method", "name": "handleEnterKey", "privacy": "private", "return": { "type": { "text": "void" } } }, { "kind": "method", "name": "applySectionFocus", "privacy": "private" }, { "kind": "method", "name": "getCategoriesElements", "privacy": "private", "return": { "type": { "text": "HTMLElement[]" } } }, { "kind": "method", "name": "getResultElements", "privacy": "private", "return": { "type": { "text": "HTMLElement[]" } } }, { "kind": "method", "name": "clearKeyboardFocusVisuals", "privacy": "private" }, { "kind": "method", "name": "applyCategoryFocus", "privacy": "private" }, { "kind": "method", "name": "applyResultFocus", "privacy": "private" }, { "kind": "method", "name": "updateSearch", "privacy": "private", "return": { "type": { "text": "void" } } }, { "kind": "method", "name": "convertProductsToEmittedData", "privacy": "private", "return": { "type": { "text": "emittedData[]" } }, "parameters": [ { "name": "products", "type": { "text": "ProductBean | ProductBean[]" } } ] }, { "kind": "method", "name": "convertProductsToEnterKeyEmittedData", "privacy": "private", "return": { "type": { "text": "enterKeyEmittedData" } }, "parameters": [ { "name": "products", "type": { "text": "ProductBean[]" } } ] }, { "kind": "method", "name": "isClicked", "privacy": "private", "return": { "type": { "text": "void" } } }, { "kind": "method", "name": "emitItemSelection", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "product", "type": { "text": "ProductBean" } } ] }, { "kind": "method", "name": "emitEnterKeyPress", "privacy": "private", "return": { "type": { "text": "Promise<void>" } } }, { "kind": "method", "name": "resetResultPerCategories", "privacy": "private", "return": { "type": { "text": "void" } } }, { "kind": "method", "name": "countNumCategories", "privacy": "private", "return": { "type": { "text": "number" } }, "parameters": [ { "name": "categories", "type": { "text": "ECategories" } } ] }, { "kind": "method", "name": "handleChangeCategories", "privacy": "private", "return": { "type": { "text": "void" } }, "parameters": [ { "name": "category", "type": { "text": "ECategories" } } ] }, { "kind": "method", "name": "searchInput", "privacy": "private", "parameters": [ { "name": "requestId", "type": { "text": "number" } } ] }, { "kind": "method", "name": "searchInputNumberCategories", "privacy": "private", "parameters": [ { "name": "requestId", "type": { "text": "number" } } ] } ], "events": [ { "name": "item-selection", "type": { "text": "CustomEvent" } }, { "name": "enter-key-pressed", "type": { "text": "CustomEvent" } }, { "name": "searching", "type": { "text": "CustomEvent" } } ], "attributes": [ { "name": "language", "type": { "text": "string" }, "default": "\"fr-FR\"", "fieldName": "language" }, { "name": "api-url", "type": { "text": "string" }, "default": "\"https://api.claudebernard.fr/search\"", "fieldName": "apiUrl" }, { "name": "api-key", "type": { "text": "string | undefined" }, "fieldName": "apiKey" }, { "name": "placeholder", "type": { "text": "string" }, "default": "\"Médicaments, molécules, produits de parapharmacie, laboratoires...\"", "fieldName": "placeholder" }, { "name": "result-config", "type": { "text": "ResultConfig" }, "default": "{\n highlight: false,\n displayCategoriesLabel: false,\n displayPictograms: false,\n filters: defaultFilters,\n formattingTextShort: false,\n formattingTooltipTextShort: false,\n numberResultsDisplayed: 50,\n sponsorOrdering: false,\n }", "fieldName": "resultConfig" }, { "name": "preselected-category", "type": { "text": "ECategories" }, "fieldName": "preselectedCategory" }, { "name": "list-categories-displayed", "type": { "text": "ECategories[]" }, "default": "[\n ECategories.allCategories,\n ECategories.products,\n ECategories.companies,\n ECategories.molecules,\n ECategories.indications,\n ECategories.atcclass,\n ECategories.commonNames,\n ECategories.genericAccessoriesGroups,\n ]", "fieldName": "listCategoriesDisplayed" }, { "name": "auto-focus", "type": { "text": "boolean" }, "default": "false", "fieldName": "autoFocus" } ], "mixins": [ { "name": "SignalWatcher", "package": "@lit-labs/signals" } ], "superclass": { "name": "LitElement", "package": "lit" }, "tagName": "bcb-search-bar", "customElement": true } ], "exports": [ { "kind": "js", "name": "ECategories", "declaration": { "name": "ECategories", "module": "\"@shared/enums\"" } }, { "kind": "js", "name": "{ setLocale }", "declaration": { "name": "{ setLocale }", "module": "src/search-bar/search-bar.ts" } }, { "kind": "js", "name": "SearchBar", "declaration": { "name": "SearchBar", "module": "src/search-bar/search-bar.ts" } }, { "kind": "custom-element-definition", "name": "bcb-search-bar", "declaration": { "name": "SearchBar", "module": "src/search-bar/search-bar.ts" } } ] }, { "kind": "javascript-module", "path": "src/test/api-results-mock.ts", "declarations": [ { "kind": "variable", "name": "categoriesRequestResponseWithDeletedProducts", "type": { "text": "SearchResponseBean" }, "default": "{\n \"filters\": {\n \"available\": [\n {\n \"type\": \"categorie\",\n \"field\": \"libelleType.keyword\",\n \"label\": \"categorie\",\n \"values\": [\n {\n \"value\": \"Pr&#233;sentation\",\n \"label\": \"Pr&#233;sentation\",\n \"count\": 3,\n \"exclude\": 0\n }\n ],\n \"totalCount\": 3\n }\n ],\n \"active\": []\n },\n \"search\": null\n}" }, { "kind": "variable", "name": "categoriesRequestResponseWithOnlyOneProduct", "type": { "text": "SearchResponseBean" }, "default": "{\n \"filters\": {\n \"available\": [\n {\n \"type\": \"categorie\",\n \"field\": \"libelleType.keyword\",\n \"label\": \"categorie\",\n \"values\": [\n {\n \"value\": \"Pr&#233;sentation\",\n \"label\": \"Pr&#233;sentation\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n ],\n \"active\": [],\n },\n \"search\": undefined,\n}" }, { "kind": "variable", "name": "categoriesRequestResponseWithTwoProducts", "type": { "text": "SearchResponseBean" }, "default": "{\n \"filters\": {\n \"available\": [\n {\n \"type\": \"categorie\",\n \"field\": \"libelleType.keyword\",\n \"label\": \"categorie\",\n \"values\": [\n {\n \"value\": \"Pr&#233;sentation\",\n \"label\": \"Pr&#233;sentation\",\n \"count\": 2,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 2,\n },\n ],\n \"active\": [],\n },\n \"search\": undefined,\n}" }, { "kind": "variable", "name": "categoriesRequestResponseWithManyProducts", "type": { "text": "SearchResponseBean" }, "default": "{\n \"filters\": {\n \"available\": [\n {\n \"type\": \"categorie\",\n \"field\": \"libelleType.keyword\",\n \"label\": \"categorie\",\n \"values\": [\n {\n \"value\": \"Pr&#233;sentation\",\n \"label\": \"Pr&#233;sentation\",\n \"count\": 25,\n \"exclude\": 0\n },\n {\n \"value\": \"Pr&#233;sentation Hosp\",\n \"label\": \"Pr&#233;sentation Hosp\",\n \"count\": 7,\n \"exclude\": 0\n },\n {\n \"value\": \"Gamme\",\n \"label\": \"Gamme\",\n \"count\": 5,\n \"exclude\": 0\n },\n {\n \"value\": \"Marque\",\n \"label\": \"Marque\",\n \"count\": 1,\n \"exclude\": 0\n }\n ],\n \"totalCount\": 38\n }\n ],\n \"active\": []\n },\n \"search\": null\n}" }, { "kind": "variable", "name": "resultsRequestResponseWithOnlyOneProduct", "type": { "text": "SearchResponseBean" }, "default": "{\n \"filters\": {\n \"available\": [\n {\n \"type\": \"terrains\",\n \"field\": \"attributsSegmentation.terrains.libelle.keyword\",\n \"label\": \"Terrains\",\n \"values\": [\n {\n \"value\": \"Adulte\",\n \"label\": \"Adulte\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"Sujet &#226;g&#233;\",\n \"label\": \"Sujet &#226;g&#233;\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 2,\n },\n {\n \"type\": \"laboratoire\",\n \"field\": \"laboratoires.laboratoireExploitant.libelleLaboratoire.keyword\",\n \"label\": \"Laboratoires\",\n \"values\": [\n {\n \"value\": \"PIERRE FABRE MEDICAMENT\",\n \"label\": \"PIERRE FABRE MEDICAMENT\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"supprime\",\n \"field\": \"flags.supprime\",\n \"label\": \"Statut\",\n \"values\": [\n {\n \"value\": \"0\",\n \"label\": \"Commercialisé\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"ci\",\n \"field\": \"motsClefs.motsClefsCI.libelleMotClefCIHtml.keyword\",\n \"label\": \"Contre indications\",\n \"values\": [\n {\n \"value\": \"Allaitement\",\n \"label\": \"Allaitement\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"Asthmatique\",\n \"label\": \"Asthmatique\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"Insuffisance respiratoire\",\n \"label\": \"Insuffisance respiratoire\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"M&#233;taboliseur ultrarapide du CYP2D6\",\n \"label\": \"M&#233;taboliseur ultrarapide du CYP2D6\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"Patient de moins de 12 ans\",\n \"label\": \"Patient de moins de 12 ans\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 5,\n },\n {\n \"type\": \"composant\",\n \"field\": \"composition.principesActifs.libelleComposantPere.keyword\",\n \"label\": \"Composants\",\n \"values\": [\n {\n \"value\": \"Cod&#233;ine\",\n \"label\": \"Cod&#233;ine\",\n \"count\": 1,\n \"exclude\": 0,\n },\n {\n \"value\": \"Erysimum\",\n \"label\": \"Erysimum\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 2,\n },\n {\n \"type\": \"statutsSegmentation\",\n \"field\": \"infoProduit.statutSegmentationHtml.keyword\",\n \"label\": \"Statuts segmentation\",\n \"values\": [\n {\n \"value\": \"M&eacute;dicament\",\n \"label\": \"M&eacute;dicament\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"autres\",\n \"field\": \"attributsSegmentation.autres.libelle.keyword\",\n \"label\": \"Autres attributs segmentation\",\n \"values\": [\n {\n \"value\": \"Hors pilulier\",\n \"label\": \"Hors pilulier\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"voies\",\n \"field\": \"listeVoiesAdm.voieAdministration.keyword\",\n \"label\": \"Voies d'administration\",\n \"values\": [\n {\n \"value\": \"orale\",\n \"label\": \"orale\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"marque\",\n \"field\": \"infoProduit.nomMarqueHtml.keyword\",\n \"label\": \"Marques\",\n \"values\": [\n {\n \"value\": \"POLERY\",\n \"label\": \"POLERY\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"hospitalier\",\n \"field\": \"flags.hospitalier\",\n \"label\": \"Hospitalier\",\n \"values\": [\n {\n \"value\": \"0\",\n \"label\": \"Non\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"gamme\",\n \"field\": \"infoProduit.nomGammeHtml.keyword\",\n \"label\": \"Gammes\",\n \"values\": [\n {\n \"value\": \"Adulte\",\n \"label\": \"Adulte\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"type\",\n \"field\": \"type\",\n \"label\": \"Type\",\n \"values\": [\n {\n \"value\": \"1\",\n \"label\": \"Médicament\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"indication\",\n \"field\": \"motsClefs.motsClefsInd.libelleMotClefIndHtml.keyword\",\n \"label\": \"Indications\",\n \"values\": [\n {\n \"value\": \"Toux non productive\",\n \"label\": \"Toux non productive\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"dopant\",\n \"field\": \"flags.dopant\",\n \"label\": \"Dopant\",\n \"values\": [\n {\n \"value\": \"0\",\n \"label\": \"Non\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n {\n \"type\": \"circuitsDeDistribution\",\n \"field\": \"attributsSegmentation.circuitDeDistribution.libelle.keyword\",\n \"label\": \"Circuits de distribution\",\n \"values\": [\n {\n \"value\": \"Pharmacie\",\n \"label\": \"Pharmacie\",\n \"count\": 1,\n \"exclude\": 0,\n },\n ],\n \"totalCount\": 1,\n },\n ],\n \"active\": [],\n },\n \"search\": {\n \"content\": [\n {\n \"code\": \"40525\",\n \"productId\": 40525,\n \"type\": 1,\n \"labelHtml\": \"POLERY ADULTES SANS SUCRE, sirop, bo&icirc;te de 1 flacon (+ gobelet doseur) de 200 ml\",\n \"code13\": \"3400939845869\",\n \"deletedDate\": \"\",\n \"deleted\": false,\n \"labels\": {\n \"typeLabel\": \"Pr&#233;sentation\",\n \"label\": \"POLERY ADULTES SANS SUCRE. sirop. boite de 1 flacon (+ gobelet doseur) de 200 ml\",\n \"shortLabel\": \"POLERY AD SP S S 200ML\",\n \"shortLabelHtml\": \"POLERY AD SP S/S 200ML\",\n \"longLabel\": \"POLERY ADULTES SANS SUCRE. sirop. boite de 1 flacon (+ gobelet doseur) de 200 ml\",\n \"longLabelHtml\": \"POLERY ADULTES SANS SUCRE, sirop, bo&icirc;te de 1 flacon (+ gobelet doseur) de 200 ml\",\n \"searchLabel\": \"POLERY ADULTES SANS SUCRE. SIROP. BOITE DE 1 FLACON (+ GOBELET DOSEUR) DE 200 ML POLERY ADULTES SANS SUCRE. SIROP. BOITE DE 1 FLACON (+ GOBELET DOSEUR) DE 200 ML POLERY AD SP S S 200ML POLERY AD. S SUC SIR FL200ML CODEINE ERYSIMUM* POLERYADULTESSANSSUCRE.SIROP.BOITEDE1FLACON(+GOBELETDOSEUR)DE200MLPOLERYADULTESSANSSUCRE.SIROP.BOITEDE1FLACON(+GOBELETDOSEUR)DE200MLPOLERYADSPSS200MLPOLERYAD.SSUCSIRFL200MLCODEINEERYSIMUM* POLERY ADULTES SANS SUCRE. SIROP. BOITE DE 1 FLACON (+ GOBELET DOSEUR) DE 200 ML POLERY ADULTES SANS SUCRE. SIROP. BOITE DE 1 FLACON (+ GOBELET DOSEUR) DE 200 ML POLERY AD SP S S 200ML POLERY AD. S SUC SIR FL200ML CODEINE ERYSIMUM* Adulte Sujet_age Hors_pilulier\",\n },\n \"properties\": {\n \"thumbnail\": \"https://documents.resip.fr/vignettes/40525_vign.jpg\",\n \"productName\": \"POLERY ADULTES SANS SUCRE\",\n \"productDosage\": \"\",\n \"galenicFormCode\": \"BB01\",\n \"galenicFormLabel\": \"Sirop\",\n \"galenicFormLabelHtml\": undefined,\n \"aspect\": \" A LIQUIDE SIROP MARRON JAUNE BRUN CLAIR\",\n \"inFacilityFormulary\": false,\n \"codes\": {\n \"cip7\": \"3984586\",\n \"cip13\": \"3400939845869\",\n \"cip13Referent\": \"3400939845869\",\n \"ucd7\": \"9362325\",\n \"ucd13\": \"3400893623251\",\n \"cis\": \"69592294\",\n \"code13Referent\": \"3400939845869\",\n \"ean13\": [],\n },\n \"flags\": {\n \"doping\": 0,\n \"driveWarning\": \"1\",\n \"narcotic\": 1,\n \"crushable\": -1,\n \"referent\": 0,\n \"generic\": 0,\n \"biosimilar\": 0,\n \"hospitalDelivery\": 0,\n \"internal\": 1,\n \"medicalDevice\": 0,\n \"homeo\": 0,\n \"exactcureSimulable\": 1,\n \"pediatrics\": 0,\n \"hybrid\": 0,\n \"extendedFlags\": {\n \"bloodDerivative\": 0,\n \"anticoagulant\": 0,\n \"vaccin\": 0,\n \"soluteDilution\": 0,\n \"emergencyContraceptive\": 0,\n \"minorContraceptive\": 0,\n \"fridge\": 0,\n \"humanAntibiotic\": 0,\n \"veterinaryAntibiotic\": 0,\n \"veterinaryPrescription\": 0,\n \"deconditionning\": 0,\n \"seasonalFluVaccine\":