@nanoporetech-digital/components 8.0.0 → 8.1.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/nano-algolia-results.cjs.entry.js +24 -26
- package/dist/cjs/nano-algolia.cjs.entry.js +4 -0
- package/dist/cjs/nano-avatar_5.cjs.entry.js +120 -117
- package/dist/cjs/nano-dropdown_2.cjs.entry.js +10 -6
- package/dist/cjs/nano-icon_3.cjs.entry.js +1 -1
- package/dist/cjs/nano-in-page-nav.cjs.entry.js +1 -1
- package/dist/cjs/nano-tab-group.cjs.entry.js +1 -1
- package/dist/cjs/{popover-D_uJstEp.js → popover-BxNxwqMv.js} +5 -3
- package/dist/collection/components/algolia/algolia-results.js +25 -27
- package/dist/collection/components/algolia/lib/template.js +4 -0
- package/dist/collection/components/breadcrumb/breadcrumb.js +1 -1
- package/dist/collection/components/dropdown/dropdown.js +9 -5
- package/dist/collection/components/global-search-results/global-search-results.css +121 -189
- package/dist/collection/components/global-search-results/global-search-results.js +121 -117
- package/dist/collection/components/in-page-nav/in-page-nav.css +3 -1
- package/dist/collection/components/tabs/tab-group.js +1 -1
- package/dist/collection/utils/popover.js +5 -3
- package/dist/components/algolia.js +4 -0
- package/dist/components/dropdown.js +9 -5
- package/dist/components/global-search-results.js +122 -118
- package/dist/components/nano-algolia-results.js +25 -27
- package/dist/components/nano-in-page-nav.js +1 -1
- package/dist/components/nano-tab-group.js +1 -1
- package/dist/components/popover.js +5 -3
- package/dist/esm/nano-algolia-results.entry.js +25 -27
- package/dist/esm/nano-algolia.entry.js +4 -0
- package/dist/esm/nano-avatar_5.entry.js +120 -117
- package/dist/esm/nano-dropdown_2.entry.js +10 -6
- package/dist/esm/nano-icon_3.entry.js +1 -1
- package/dist/esm/nano-in-page-nav.entry.js +1 -1
- package/dist/esm/nano-tab-group.entry.js +1 -1
- package/dist/esm/{popover-BKomgCqQ.js → popover-CWVbjtKn.js} +5 -3
- package/dist/nano-components/nano-algolia-results.entry.js +1 -1
- package/dist/nano-components/nano-algolia.entry.js +1 -1
- package/dist/nano-components/nano-avatar_5.entry.js +1 -1
- package/dist/nano-components/nano-components.css +8 -6
- package/dist/nano-components/nano-dropdown_2.entry.js +1 -1
- package/dist/nano-components/nano-icon_3.entry.js +1 -1
- package/dist/nano-components/nano-in-page-nav.entry.js +1 -1
- package/dist/nano-components/nano-tab-group.entry.js +1 -1
- package/dist/nano-components/{popover-BKomgCqQ.js → popover-CWVbjtKn.js} +1 -1
- package/dist/style/components.css +1 -1
- package/dist/style/components.css.map +1 -1
- package/dist/style/core.css +1 -1
- package/dist/style/core.css.map +1 -1
- package/dist/style/nano.css +1 -1
- package/dist/style/nano.css.map +1 -1
- package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/generate-vue-component.d.ts +1 -1
- package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/output-vue.d.ts +1 -1
- package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/plugin.d.ts +1 -1
- package/dist/types/builds/W1hp42tj/0/Digital/nano-components/packages/components/.stencil/stencil.config.d.ts +2 -0
- package/dist/types/builds/W1hp42tj/0/Digital/nano-components/packages/components/.stencil/stencil.config.prod.d.ts +2 -0
- package/dist/types/components/global-search-results/global-search-results.d.ts +2 -0
- package/docs-json.json +2 -2
- package/hydrate/index.js +162 -153
- package/hydrate/index.mjs +162 -153
- package/package.json +2 -2
- package/dist/types/Users/John.Jenkins/projects/nano-components/packages/components/.stencil/stencil.config.d.ts +0 -2
- package/dist/types/Users/John.Jenkins/projects/nano-components/packages/components/.stencil/stencil.config.prod.d.ts +0 -2
- /package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/index.d.ts +0 -0
- /package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/types.d.ts +0 -0
- /package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/plugins/stencil/vue-output/utils.d.ts +0 -0
- /package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/testing/mocks/intersection-observer.d.ts +0 -0
- /package/dist/types/{Users/John.Jenkins/projects → builds/W1hp42tj/0/Digital}/nano-components/packages/components/.stencil/wdio.conf.d.ts +0 -0
@@ -326,7 +326,7 @@ const NanoTabGroup$1 = /*@__PURE__*/ proxyCustomElement(class NanoTabGroup exten
|
|
326
326
|
group: true,
|
327
327
|
'group--top': this.placement === 'top',
|
328
328
|
'group--start': this.placement === 'start',
|
329
|
-
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h("nano-masked-overflow", { role: "
|
329
|
+
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h("nano-masked-overflow", { role: "navigation", class: "group__tabs", part: "tabs__wrapper", exportparts: "items:tabs, scroll-button:tabs__scroll-button, indicator:active-tab-indicator", orientation: this.placement === 'top' ? 'horizontal' : 'vertical', isActiveHandler: (itm) => this.activeTab === itm, scrollControls: !this.noScrollControls, hideScrollbars: true }, h("slot", { name: "tabs", onSlotchange: this.handleTabSlotChange }), h("div", { class: "group__tabs-border" })), h("div", { part: "body", class: "group__body", onTouchStart: this.handleTouchStart, onTouchEnd: this.handleTouchEnd }, h("slot", { onSlotchange: this.handleContentSlotChange })))));
|
330
330
|
}
|
331
331
|
static get style() { return tabGroupCss; }
|
332
332
|
}, [257, "nano-tab-group", {
|
@@ -1831,7 +1831,7 @@ class Popover {
|
|
1831
1831
|
// this.isVisible = false;
|
1832
1832
|
this.popover.hidden = true;
|
1833
1833
|
this.popover.classList.remove(this.options.visibleClass);
|
1834
|
-
this.popover.addEventListener('transitionend', this.handleTransitionEnd
|
1834
|
+
this.popover.addEventListener('transitionend', this.handleTransitionEnd);
|
1835
1835
|
}
|
1836
1836
|
handleTransitionEnd(event) {
|
1837
1837
|
const target = event.target;
|
@@ -1846,10 +1846,13 @@ class Popover {
|
|
1846
1846
|
this.popover.classList.remove(this.options.visibleClass);
|
1847
1847
|
this.options.onAfterHide.call(this);
|
1848
1848
|
}
|
1849
|
+
else {
|
1850
|
+
this.options.onAfterShow.call(this);
|
1851
|
+
}
|
1849
1852
|
}
|
1850
1853
|
}
|
1851
1854
|
destroy() {
|
1852
|
-
this.popover.removeEventListener('transitionend', this.handleTransitionEnd
|
1855
|
+
this.popover.removeEventListener('transitionend', this.handleTransitionEnd);
|
1853
1856
|
if (this.popper) {
|
1854
1857
|
this.popper.destroy();
|
1855
1858
|
this.popper = null;
|
@@ -1901,7 +1904,6 @@ class Popover {
|
|
1901
1904
|
},
|
1902
1905
|
],
|
1903
1906
|
});
|
1904
|
-
this.popover.addEventListener('transitionend', () => this.options.onAfterShow.call(this), { once: true });
|
1905
1907
|
// Reposition the menu after it appears in case a modifier kicked in
|
1906
1908
|
requestAnimationFrame(() => {
|
1907
1909
|
this.popper?.update().catch((e) => {
|
@@ -1,7 +1,7 @@
|
|
1
1
|
/*!
|
2
2
|
* Custom elements for Nanopore-Digital Web applications
|
3
3
|
*/
|
4
|
-
import { r as registerInstance, c as createEvent, g as getElement,
|
4
|
+
import { r as registerInstance, c as createEvent, g as getElement, a as Host } from './index-DgO0qeQ9.js';
|
5
5
|
import { h } from './renderer-T8etwwhk.js';
|
6
6
|
import { W as Wormhole, S as SearchChangeEvent } from './algolia-data-D9ZAstcC.js';
|
7
7
|
|
@@ -160,30 +160,28 @@ const AlgoliaResults = class {
|
|
160
160
|
this.nanoTplUpdated.emit(this.el);
|
161
161
|
}
|
162
162
|
connectedCallback() {
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
}
|
186
|
-
});
|
163
|
+
this.startTplSlot = this.el.querySelector('[slot="start-template"]');
|
164
|
+
this.startOutputSlot = this.el.querySelector('[slot="start-output"]');
|
165
|
+
if (this.startTplSlot) {
|
166
|
+
this.startTpl = this.startTplSlot.innerHTML;
|
167
|
+
this.startTpl = this.startTpl.replace(/=>/gm, '=>');
|
168
|
+
}
|
169
|
+
this.resultTplSlot = this.el.querySelector('[slot="result-template"]');
|
170
|
+
this.outputSlot = this.el.querySelector('[slot="result-output"]');
|
171
|
+
if (this.resultTplSlot) {
|
172
|
+
this.resultTpl = this.resultTplSlot.innerHTML;
|
173
|
+
this.resultTpl = this.resultTpl.replace(/=>/gm, '=>');
|
174
|
+
}
|
175
|
+
this.endTplSlot = this.el.querySelector('[slot="end-template"]');
|
176
|
+
this.endOutputSlot = this.el.querySelector('[slot="end-output"]');
|
177
|
+
if (this.endTplSlot) {
|
178
|
+
this.endTpl = this.endTplSlot.innerHTML;
|
179
|
+
this.endTpl = this.endTpl.replace(/=>/gm, '=>');
|
180
|
+
}
|
181
|
+
if (this.indexResults) {
|
182
|
+
this.addContentIndex();
|
183
|
+
this.updateResultContent();
|
184
|
+
}
|
187
185
|
}
|
188
186
|
componentDidLoad() {
|
189
187
|
this.updateStartEndContent();
|
@@ -195,10 +193,10 @@ const AlgoliaResults = class {
|
|
195
193
|
}
|
196
194
|
}
|
197
195
|
render() {
|
198
|
-
return (h(Host, { key: '
|
196
|
+
return (h(Host, { key: '857784ead2b9536559ef2220bff26d508061781c', class: {
|
199
197
|
'show-results': this.showResults,
|
200
198
|
'nano-results': true,
|
201
|
-
} }, h("div", { key: '
|
199
|
+
} }, h("div", { key: 'be165b02c4ec5d2358e15dadfd4695fd5901f0b0', class: "default" }, h("slot", { key: '1ab64bb71c75531e8f6b0c65833de7d2dc1ee0ca' })), h("div", { key: 'cee981cead8b921e29fd4223e4985c3615e0e063', ref: (div) => (this.outputEle = div) }, h("slot", { key: 'cff96070ca2acf18f7b8165444b28f433ca3601d', name: "start-output" }), h("slot", { key: '76833dd55d415baf083527ed5580049f90c36b40', name: "result-output" }), h("div", { key: 'dac7a9081d1a65b4e17dec60044467e17575568e', ref: (div) => (this.infiniteScrollBar = div) }), h("slot", { key: '07c82d60a58c11bcc50807ab95d63cf3fd59d768', name: "end-output" }))));
|
202
200
|
}
|
203
201
|
static get watchers() { return {
|
204
202
|
"results": ["addContentIndex", "resultsChange"],
|
@@ -1165,6 +1165,10 @@ filters.define('remove_spaces', (str) => str.replace(/ /g, '_'));
|
|
1165
1165
|
filters.define('add_spaces', (str) => (str = str.replace(/[_\-]/g, ' ')));
|
1166
1166
|
filters.define('capitalise', (str) => (str = str.charAt(0).toUpperCase() + str.slice(1)));
|
1167
1167
|
filters.define('lowercase', (str) => (str = str.toLowerCase()));
|
1168
|
+
filters.define('tag_tidy', (str) => {
|
1169
|
+
const arr = str.split('>');
|
1170
|
+
return arr.map((s) => s.trim())[arr.length - 1];
|
1171
|
+
});
|
1168
1172
|
const Squirrel = squirrel;
|
1169
1173
|
|
1170
1174
|
const algoliaCss = ":host,*,*::before,*::after{box-sizing:border-box}[hidden]{display:none !important}@media (prefers-reduced-motion: reduce){:host,*,*::before,*::after{animation-duration:0.01ms !important;animation-iteration-count:1 !important;transition-duration:0.01ms !important;scroll-behavior:auto !important}}:host,*,*::before,*::after{box-sizing:border-box}[hidden]{display:none !important}@media (prefers-reduced-motion: reduce){:host,*,*::before,*::after{animation-duration:0.01ms !important;animation-iteration-count:1 !important;transition-duration:0.01ms !important;scroll-behavior:auto !important}}:host{position:relative;display:block}:host ::slotted([slot=search-template]){display:none !important}.loader{opacity:0;position:fixed;block-size:100%;inline-size:100%;min-block-size:100%;max-block-size:100vh !important;max-inline-size:100vw !important;inset-inline-start:0;inset-block-start:0;z-index:-10;font-size:60px;display:flex;align-items:center;justify-content:center;transition:opacity 0.2s ease, z-index 0.01s ease 0.2s}.loader.loading{opacity:1;z-index:10;transition:z-index 0.01s ease, opacity 0.2s ease 0.01s}.default{block-size:100%}.default:focus{outline:none}.results{opacity:0;outline:none;overflow:auto;transition:transform 0.3s ease, opacity 0.3s ease, visibility 0.01s ease 0.3s, z-index 0.01s ease 0.3s;transform:translate(0, 100px);visibility:hidden;z-index:-1;position:absolute;inset-block-start:0;inset-inline-start:0;display:none}.results-container{position:relative}.results.show{transition:z-index 0.01s ease, visibility 0.01s ease, transform 0.3s ease 0.01s, opacity 0.3s ease 0.01s, overflow 0.01s ease 0.31s;transform:translate(0, 0);visibility:visible;opacity:1;z-index:10;overflow:hidden}.results.shown{block-size:auto !important;inline-size:auto !important;display:block;position:static;transform:none;z-index:auto;visibility:inherit;opacity:initial;overflow:visible}";
|