@empathyco/x-components 3.0.0-alpha.72 → 3.0.0-alpha.75
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/CHANGELOG.md +25 -225
- package/design-system/full-theme.css +49 -48
- package/docs/API-reference/api/x-components.baseresultpreviousprice.format.md +2 -2
- package/docs/API-reference/api/x-components.baseresultpreviousprice.md +1 -1
- package/docs/API-reference/api/x-components.historyqueriesactions.md +1 -0
- package/docs/API-reference/api/x-components.historyqueriesactions.togglehistoryqueries.md +24 -0
- package/docs/API-reference/api/x-components.historyqueriesmutations.md +1 -0
- package/docs/API-reference/api/x-components.historyqueriesmutations.setisenabled.md +24 -0
- package/docs/API-reference/api/x-components.historyqueriesstate.isenabled.md +13 -0
- package/docs/API-reference/api/x-components.historyqueriesstate.md +1 -0
- package/docs/API-reference/api/x-components.historyqueriesxevents.md +1 -0
- package/docs/API-reference/api/x-components.historyqueriesxevents.usertoggledhistoryqueries.md +13 -0
- package/docs/API-reference/api/x-components.md +1 -0
- package/docs/API-reference/api/x-components.togglehistoryqueries.md +13 -0
- package/docs/API-reference/components/common/currency/x-components.base-currency.md +267 -28
- package/docs/API-reference/components/common/result/x-components.base-result-previous-price.md +36 -8
- package/history-queries/index.js +1 -1
- package/js/components/currency/base-currency.vue.js.map +1 -1
- package/js/components/currency/base-currency.vue_rollup-plugin-vue_script.vue.js +1 -5
- package/js/components/currency/base-currency.vue_rollup-plugin-vue_script.vue.js.map +1 -1
- package/js/components/result/base-result-previous-price.vue.js.map +1 -1
- package/js/components/result/base-result-previous-price.vue_rollup-plugin-vue_script.vue.js +1 -1
- package/js/components/result/base-result-previous-price.vue_rollup-plugin-vue_script.vue.js.map +1 -1
- package/js/index.js +1 -1
- package/js/x-modules/history-queries/store/actions/set-history-queries.action.js +6 -4
- package/js/x-modules/history-queries/store/actions/set-history-queries.action.js.map +1 -1
- package/js/x-modules/history-queries/store/actions/toggle-history-queries.action.js +13 -0
- package/js/x-modules/history-queries/store/actions/toggle-history-queries.action.js.map +1 -0
- package/js/x-modules/history-queries/store/constants.js +3 -2
- package/js/x-modules/history-queries/store/constants.js.map +1 -1
- package/js/x-modules/history-queries/store/module.js +11 -3
- package/js/x-modules/history-queries/store/module.js.map +1 -1
- package/js/x-modules/history-queries/wiring.js +10 -1
- package/js/x-modules/history-queries/wiring.js.map +1 -1
- package/package.json +7 -7
- package/report/x-components.api.json +173 -3
- package/report/x-components.api.md +11 -1
- package/types/components/currency/base-currency.vue.d.ts.map +1 -1
- package/types/components/result/base-result-previous-price.vue.d.ts +1 -2
- package/types/components/result/base-result-previous-price.vue.d.ts.map +1 -1
- package/types/x-modules/history-queries/events.types.d.ts +5 -0
- package/types/x-modules/history-queries/events.types.d.ts.map +1 -1
- package/types/x-modules/history-queries/store/actions/set-history-queries.action.d.ts.map +1 -1
- package/types/x-modules/history-queries/store/actions/toggle-history-queries.action.d.ts +3 -0
- package/types/x-modules/history-queries/store/actions/toggle-history-queries.action.d.ts.map +1 -0
- package/types/x-modules/history-queries/store/constants.d.ts +1 -0
- package/types/x-modules/history-queries/store/constants.d.ts.map +1 -1
- package/types/x-modules/history-queries/store/module.d.ts.map +1 -1
- package/types/x-modules/history-queries/store/types.d.ts +17 -0
- package/types/x-modules/history-queries/store/types.d.ts.map +1 -1
- package/types/x-modules/history-queries/wiring.d.ts +9 -0
- package/types/x-modules/history-queries/wiring.d.ts.map +1 -1
|
@@ -14,7 +14,7 @@ __decorate([
|
|
|
14
14
|
Prop({ required: true })
|
|
15
15
|
], BaseResultPreviousPrice.prototype, "result", void 0);
|
|
16
16
|
__decorate([
|
|
17
|
-
Prop(
|
|
17
|
+
Prop()
|
|
18
18
|
], BaseResultPreviousPrice.prototype, "format", void 0);
|
|
19
19
|
BaseResultPreviousPrice = __decorate([
|
|
20
20
|
Component({
|
package/js/components/result/base-result-previous-price.vue_rollup-plugin-vue_script.vue.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue_rollup-plugin-vue_script.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Result } from '@empathyco/x-types';\nimport { Component, Prop } from 'vue-property-decorator';\nimport Vue from 'vue';\nimport BaseCurrency from '../currency/base-currency.vue';\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result | result} previous price.\n *\n * @public\n */\n@Component({\n components: { BaseCurrency }\n})\nexport default class BaseResultPreviousPrice extends Vue {\n /**\n * (Required) The {@link @empathyco/x-types#Result | result} information.\n *\n * @public\n */\n @Prop({ required: true })\n protected result!: Result;\n\n /**\n * Format or mask to be defined as string.\n * - Use 'i' to define integer numbers.\n * - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the\n * doesn't include decimals, it is filled with zeros until reach the length defined with 'd's.\n * - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group.\n * - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more\n * than one character.\n * - Set whatever you need around the integers and decimals marks.\n
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue_rollup-plugin-vue_script.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Result } from '@empathyco/x-types';\nimport { Component, Prop } from 'vue-property-decorator';\nimport Vue from 'vue';\nimport BaseCurrency from '../currency/base-currency.vue';\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result | result} previous price.\n *\n * @public\n */\n@Component({\n components: { BaseCurrency }\n})\nexport default class BaseResultPreviousPrice extends Vue {\n /**\n * (Required) The {@link @empathyco/x-types#Result | result} information.\n *\n * @public\n */\n @Prop({ required: true })\n protected result!: Result;\n\n /**\n * Format or mask to be defined as string.\n * - Use 'i' to define integer numbers.\n * - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the\n * doesn't include decimals, it is filled with zeros until reach the length defined with 'd's.\n * - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group.\n * - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more\n * than one character.\n * - Set whatever you need around the integers and decimals marks.\n *\n * @remarks The number of 'd', which is the maximum decimal length, MUST match with the length\n * of decimals provided from the adapter. Otherwise, when the component truncate the decimal\n * part, delete significant digits.\n *\n * @public\n */\n @Prop()\n protected format?: string;\n}\n"],"names":["BaseCurrency"],"mappings":";;;;;AAsBA;;;;;AAQA,IAAqB,uBAAuB,GAA5C,MAAqB,uBAAwB,SAAQ,GAAG;CA2BvD,CAAA;AApBC;IADC,IAAI,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;uDACC;AAmB1B;IADC,IAAI,EAAE;uDACmB;AA1BP,uBAAuB;IAH3C,SAAS,CAAC;QACT,UAAU,EAAE,gBAAEA,iBAAY,EAAE;KAC7B,CAAC;GACmB,uBAAuB,CA2B3C;aA3BoB,uBAAuB;;;;"}
|
package/js/index.js
CHANGED
|
@@ -216,7 +216,7 @@ export { HistoryQueriesGetter, historyQueries } from './x-modules/history-querie
|
|
|
216
216
|
export { sessionHistoryQueries } from './x-modules/history-queries/store/getters/session-history-queries.getter.js';
|
|
217
217
|
export { storageKey } from './x-modules/history-queries/store/getters/storage-key.getter.js';
|
|
218
218
|
export { historyQueriesXStoreModule } from './x-modules/history-queries/store/module.js';
|
|
219
|
-
export { addQueryToHistoryQueries, clearHistoryQueries, clearHistoryQueriesQuery, historyQueriesWiring, loadHistoryQueriesFromBrowserStorageWire, refreshHistoryQueriesSession, removeHistoryQuery, setHistoryQueriesQuery } from './x-modules/history-queries/wiring.js';
|
|
219
|
+
export { addQueryToHistoryQueries, clearHistoryQueries, clearHistoryQueriesQuery, historyQueriesWiring, loadHistoryQueriesFromBrowserStorageWire, refreshHistoryQueriesSession, removeHistoryQuery, setHistoryQueriesQuery, toggleHistoryQueries } from './x-modules/history-queries/wiring.js';
|
|
220
220
|
export { historyQueriesXModule } from './x-modules/history-queries/x-module.js';
|
|
221
221
|
export { default as IdentifierResult } from './x-modules/identifier-results/components/identifier-result.vue.js';
|
|
222
222
|
export { default as IdentifierResults } from './x-modules/identifier-results/components/identifier-results.vue.js';
|
|
@@ -9,11 +9,13 @@ import { localStorageService } from '../../../../utils/storage.js';
|
|
|
9
9
|
* @public
|
|
10
10
|
*/
|
|
11
11
|
const setHistoryQueries = ({ commit, state, getters }, historyQueries) => {
|
|
12
|
-
if (
|
|
13
|
-
|
|
12
|
+
if (state.isEnabled) {
|
|
13
|
+
if (historyQueries.length > state.config.maxItemsToStore) {
|
|
14
|
+
historyQueries = historyQueries.slice(0, state.config.maxItemsToStore);
|
|
15
|
+
}
|
|
16
|
+
commit('setHistoryQueries', historyQueries);
|
|
17
|
+
localStorageService.setItem(getters.storageKey, historyQueries);
|
|
14
18
|
}
|
|
15
|
-
commit('setHistoryQueries', historyQueries);
|
|
16
|
-
localStorageService.setItem(getters.storageKey, historyQueries);
|
|
17
19
|
};
|
|
18
20
|
|
|
19
21
|
export { setHistoryQueries };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"set-history-queries.action.js","sources":["../../../../../../src/x-modules/history-queries/store/actions/set-history-queries.action.ts"],"sourcesContent":["import { localStorageService } from '../../../../utils/storage';\nimport { HistoryQueriesXStoreModule } from '../types';\n\n/**\n * Default implementation for the {@link HistoryQueriesActions.setHistoryQueries}.\n *\n * @param context - The {@link https://vuex.vuejs.org/guide/actions.html | context} of the actions,\n * provided by Vuex.\n * @param historyQueries - The new history queries to save to the store and browser storage.\n * @public\n */\nexport const setHistoryQueries: HistoryQueriesXStoreModule['actions']['setHistoryQueries'] = (\n { commit, state, getters },\n historyQueries\n) => {\n if (historyQueries.length > state.config.maxItemsToStore) {\n
|
|
1
|
+
{"version":3,"file":"set-history-queries.action.js","sources":["../../../../../../src/x-modules/history-queries/store/actions/set-history-queries.action.ts"],"sourcesContent":["import { localStorageService } from '../../../../utils/storage';\nimport { HistoryQueriesXStoreModule } from '../types';\n\n/**\n * Default implementation for the {@link HistoryQueriesActions.setHistoryQueries}.\n *\n * @param context - The {@link https://vuex.vuejs.org/guide/actions.html | context} of the actions,\n * provided by Vuex.\n * @param historyQueries - The new history queries to save to the store and browser storage.\n * @public\n */\nexport const setHistoryQueries: HistoryQueriesXStoreModule['actions']['setHistoryQueries'] = (\n { commit, state, getters },\n historyQueries\n) => {\n if (state.isEnabled) {\n if (historyQueries.length > state.config.maxItemsToStore) {\n historyQueries = historyQueries.slice(0, state.config.maxItemsToStore);\n }\n commit('setHistoryQueries', historyQueries);\n localStorageService.setItem(getters.storageKey, historyQueries);\n }\n};\n"],"names":[],"mappings":";;AAGA;;;;;;;;MAQa,iBAAiB,GAA+D,CAC3F,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,EAC1B,cAAc;IAEd,IAAI,KAAK,CAAC,SAAS,EAAE;QACnB,IAAI,cAAc,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,eAAe,EAAE;YACxD,cAAc,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;SACxE;QACD,MAAM,CAAC,mBAAmB,EAAE,cAAc,CAAC,CAAC;QAC5C,mBAAmB,CAAC,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;KACjE;AACH;;;;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { localStorageService } from '../../../../utils/storage.js';
|
|
2
|
+
import { HISTORY_QUERIES_ENABLED_KEY } from '../constants.js';
|
|
3
|
+
|
|
4
|
+
const toggleHistoryQueries = async ({ dispatch, commit }, isEnabled) => {
|
|
5
|
+
if (!isEnabled) {
|
|
6
|
+
await dispatch('setHistoryQueries', []);
|
|
7
|
+
}
|
|
8
|
+
commit('setIsEnabled', isEnabled);
|
|
9
|
+
localStorageService.setItem(HISTORY_QUERIES_ENABLED_KEY, isEnabled);
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export { toggleHistoryQueries };
|
|
13
|
+
//# sourceMappingURL=toggle-history-queries.action.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle-history-queries.action.js","sources":["../../../../../../src/x-modules/history-queries/store/actions/toggle-history-queries.action.ts"],"sourcesContent":["import { localStorageService } from '../../../../utils/storage';\nimport { HISTORY_QUERIES_ENABLED_KEY } from '../constants';\nimport { HistoryQueriesXStoreModule } from '../types';\n\nexport const toggleHistoryQueries: HistoryQueriesXStoreModule['actions']['toggleHistoryQueries'] =\n async ({ dispatch, commit }, isEnabled) => {\n if (!isEnabled) {\n await dispatch('setHistoryQueries', []);\n }\n\n commit('setIsEnabled', isEnabled);\n localStorageService.setItem(HISTORY_QUERIES_ENABLED_KEY, isEnabled);\n };\n"],"names":[],"mappings":";;;MAIa,oBAAoB,GAC/B,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,SAAS;IACpC,IAAI,CAAC,SAAS,EAAE;QACd,MAAM,QAAQ,CAAC,mBAAmB,EAAE,EAAE,CAAC,CAAC;KACzC;IAED,MAAM,CAAC,cAAc,EAAE,SAAS,CAAC,CAAC;IAClC,mBAAmB,CAAC,OAAO,CAAC,2BAA2B,EAAE,SAAS,CAAC,CAAC;AACtE;;;;"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
const HISTORY_QUERIES_STORAGE_KEY = 'history-queries';
|
|
2
|
-
const SESSION_TIME_STAMP_STORAGE_KEY = 'session-time-stamp';
|
|
2
|
+
const SESSION_TIME_STAMP_STORAGE_KEY = 'session-time-stamp';
|
|
3
|
+
const HISTORY_QUERIES_ENABLED_KEY = 'history-queries-enabled';
|
|
3
4
|
|
|
4
|
-
export { HISTORY_QUERIES_STORAGE_KEY, SESSION_TIME_STAMP_STORAGE_KEY };
|
|
5
|
+
export { HISTORY_QUERIES_ENABLED_KEY, HISTORY_QUERIES_STORAGE_KEY, SESSION_TIME_STAMP_STORAGE_KEY };
|
|
5
6
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sources":["../../../../../src/x-modules/history-queries/store/constants.ts"],"sourcesContent":["export const HISTORY_QUERIES_STORAGE_KEY = 'history-queries';\nexport const SESSION_TIME_STAMP_STORAGE_KEY = 'session-time-stamp';\n"],"names":[],"mappings":"MAAa,2BAA2B,GAAG,kBAAkB;MAChD,8BAA8B,GAAG;;;;"}
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../src/x-modules/history-queries/store/constants.ts"],"sourcesContent":["export const HISTORY_QUERIES_STORAGE_KEY = 'history-queries';\nexport const SESSION_TIME_STAMP_STORAGE_KEY = 'session-time-stamp';\nexport const HISTORY_QUERIES_ENABLED_KEY = 'history-queries-enabled';\n"],"names":[],"mappings":"MAAa,2BAA2B,GAAG,kBAAkB;MAChD,8BAA8B,GAAG,qBAAqB;MACtD,2BAA2B,GAAG;;;;"}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { setQuery } from '../../../store/utils/query.utils.js';
|
|
2
|
+
import { localStorageService } from '../../../utils/storage.js';
|
|
2
3
|
import { addQueryToHistory } from './actions/add-query-to-history.action.js';
|
|
3
4
|
import { loadHistoryQueriesFromBrowserStorage } from './actions/load-history-queries-from-browser-storage.action.js';
|
|
4
5
|
import { refreshSession } from './actions/refresh-session.action.js';
|
|
5
6
|
import { removeFromHistory } from './actions/remove-query-from-history.action.js';
|
|
6
7
|
import { setHistoryQueries } from './actions/set-history-queries.action.js';
|
|
7
8
|
import { setUrlParams } from './actions/set-url-params.action.js';
|
|
9
|
+
import { toggleHistoryQueries } from './actions/toggle-history-queries.action.js';
|
|
10
|
+
import { HISTORY_QUERIES_ENABLED_KEY } from './constants.js';
|
|
8
11
|
import { historyQueries } from './getters/history-queries.getter.js';
|
|
9
12
|
import { normalizedQuery } from './getters/normalized-query.getter.js';
|
|
10
13
|
import { sessionHistoryQueries } from './getters/session-history-queries.getter.js';
|
|
@@ -25,7 +28,8 @@ const historyQueriesXStoreModule = {
|
|
|
25
28
|
},
|
|
26
29
|
query: '',
|
|
27
30
|
historyQueries: [],
|
|
28
|
-
sessionTimeStampInMs: Date.now()
|
|
31
|
+
sessionTimeStampInMs: Date.now(),
|
|
32
|
+
isEnabled: localStorageService.getItem(HISTORY_QUERIES_ENABLED_KEY) ?? true
|
|
29
33
|
}),
|
|
30
34
|
getters: {
|
|
31
35
|
historyQueries,
|
|
@@ -40,7 +44,10 @@ const historyQueriesXStoreModule = {
|
|
|
40
44
|
setSessionTimeStamp(state, sessionTimeStamp) {
|
|
41
45
|
state.sessionTimeStampInMs = sessionTimeStamp;
|
|
42
46
|
},
|
|
43
|
-
setQuery
|
|
47
|
+
setQuery,
|
|
48
|
+
setIsEnabled(state, isEnabled) {
|
|
49
|
+
state.isEnabled = isEnabled;
|
|
50
|
+
}
|
|
44
51
|
},
|
|
45
52
|
actions: {
|
|
46
53
|
addQueryToHistory,
|
|
@@ -48,7 +55,8 @@ const historyQueriesXStoreModule = {
|
|
|
48
55
|
refreshSession,
|
|
49
56
|
removeFromHistory,
|
|
50
57
|
setHistoryQueries,
|
|
51
|
-
setUrlParams
|
|
58
|
+
setUrlParams,
|
|
59
|
+
toggleHistoryQueries
|
|
52
60
|
}
|
|
53
61
|
};
|
|
54
62
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module.js","sources":["../../../../../src/x-modules/history-queries/store/module.ts"],"sourcesContent":["import { setQuery } from '../../../store/utils/query.utils';\nimport { addQueryToHistory } from './actions/add-query-to-history.action';\n// eslint-disable-next-line max-len\nimport { loadHistoryQueriesFromBrowserStorage } from './actions/load-history-queries-from-browser-storage.action';\nimport { refreshSession } from './actions/refresh-session.action';\nimport { removeFromHistory } from './actions/remove-query-from-history.action';\nimport { setHistoryQueries } from './actions/set-history-queries.action';\nimport { setUrlParams } from './actions/set-url-params.action';\nimport { historyQueries } from './getters/history-queries.getter';\nimport { normalizedQuery } from './getters/normalized-query.getter';\nimport { sessionHistoryQueries } from './getters/session-history-queries.getter';\nimport { storageKey } from './getters/storage-key.getter';\nimport { HistoryQueriesXStoreModule } from './types';\n\n/**\n * {@link XStoreModule} For the history-queries module.\n *\n * @internal\n */\nexport const historyQueriesXStoreModule: HistoryQueriesXStoreModule = {\n state: () => ({\n config: {\n debounceInMs: 150,\n maxItemsToStore: 50,\n hideIfEqualsQuery: true,\n sessionTTLInMs: 30 * 60 * 1000\n },\n query: '',\n historyQueries: [],\n sessionTimeStampInMs: Date.now()\n }),\n getters: {\n historyQueries,\n normalizedQuery,\n sessionHistoryQueries,\n storageKey\n },\n mutations: {\n setHistoryQueries(state, historyQueries) {\n state.historyQueries = historyQueries;\n },\n setSessionTimeStamp(state, sessionTimeStamp) {\n state.sessionTimeStampInMs = sessionTimeStamp;\n },\n setQuery\n },\n actions: {\n addQueryToHistory,\n loadHistoryQueriesFromBrowserStorage,\n refreshSession,\n removeFromHistory,\n setHistoryQueries,\n setUrlParams\n }\n};\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"module.js","sources":["../../../../../src/x-modules/history-queries/store/module.ts"],"sourcesContent":["import { setQuery } from '../../../store/utils/query.utils';\nimport { localStorageService } from '../../../utils/storage';\nimport { addQueryToHistory } from './actions/add-query-to-history.action';\n// eslint-disable-next-line max-len\nimport { loadHistoryQueriesFromBrowserStorage } from './actions/load-history-queries-from-browser-storage.action';\nimport { refreshSession } from './actions/refresh-session.action';\nimport { removeFromHistory } from './actions/remove-query-from-history.action';\nimport { setHistoryQueries } from './actions/set-history-queries.action';\nimport { setUrlParams } from './actions/set-url-params.action';\nimport { toggleHistoryQueries } from './actions/toggle-history-queries.action';\nimport { HISTORY_QUERIES_ENABLED_KEY } from './constants';\nimport { historyQueries } from './getters/history-queries.getter';\nimport { normalizedQuery } from './getters/normalized-query.getter';\nimport { sessionHistoryQueries } from './getters/session-history-queries.getter';\nimport { storageKey } from './getters/storage-key.getter';\nimport { HistoryQueriesXStoreModule } from './types';\n\n/**\n * {@link XStoreModule} For the history-queries module.\n *\n * @internal\n */\nexport const historyQueriesXStoreModule: HistoryQueriesXStoreModule = {\n state: () => ({\n config: {\n debounceInMs: 150,\n maxItemsToStore: 50,\n hideIfEqualsQuery: true,\n sessionTTLInMs: 30 * 60 * 1000\n },\n query: '',\n historyQueries: [],\n sessionTimeStampInMs: Date.now(),\n isEnabled: localStorageService.getItem<boolean>(HISTORY_QUERIES_ENABLED_KEY) ?? true\n }),\n getters: {\n historyQueries,\n normalizedQuery,\n sessionHistoryQueries,\n storageKey\n },\n mutations: {\n setHistoryQueries(state, historyQueries) {\n state.historyQueries = historyQueries;\n },\n setSessionTimeStamp(state, sessionTimeStamp) {\n state.sessionTimeStampInMs = sessionTimeStamp;\n },\n setQuery,\n setIsEnabled(state, isEnabled) {\n state.isEnabled = isEnabled;\n }\n },\n actions: {\n addQueryToHistory,\n loadHistoryQueriesFromBrowserStorage,\n refreshSession,\n removeFromHistory,\n setHistoryQueries,\n setUrlParams,\n toggleHistoryQueries\n }\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AAiBA;;;;;MAKa,0BAA0B,GAA+B;IACpE,KAAK,EAAE,OAAO;QACZ,MAAM,EAAE;YACN,YAAY,EAAE,GAAG;YACjB,eAAe,EAAE,EAAE;YACnB,iBAAiB,EAAE,IAAI;YACvB,cAAc,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI;SAC/B;QACD,KAAK,EAAE,EAAE;QACT,cAAc,EAAE,EAAE;QAClB,oBAAoB,EAAE,IAAI,CAAC,GAAG,EAAE;QAChC,SAAS,EAAE,mBAAmB,CAAC,OAAO,CAAU,2BAA2B,CAAC,IAAI,IAAI;KACrF,CAAC;IACF,OAAO,EAAE;QACP,cAAc;QACd,eAAe;QACf,qBAAqB;QACrB,UAAU;KACX;IACD,SAAS,EAAE;QACT,iBAAiB,CAAC,KAAK,EAAE,cAAc;YACrC,KAAK,CAAC,cAAc,GAAG,cAAc,CAAC;SACvC;QACD,mBAAmB,CAAC,KAAK,EAAE,gBAAgB;YACzC,KAAK,CAAC,oBAAoB,GAAG,gBAAgB,CAAC;SAC/C;QACD,QAAQ;QACR,YAAY,CAAC,KAAK,EAAE,SAAS;YAC3B,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;SAC7B;KACF;IACD,OAAO,EAAE;QACP,iBAAiB;QACjB,oCAAoC;QACpC,cAAc;QACd,iBAAiB;QACjB,iBAAiB;QACjB,YAAY;QACZ,oBAAoB;KACrB;;;;;"}
|
|
@@ -76,6 +76,12 @@ const clearHistoryQueries = wireDispatch('setHistoryQueries', []);
|
|
|
76
76
|
* @public
|
|
77
77
|
*/
|
|
78
78
|
const removeHistoryQuery = wireDispatch('removeFromHistory');
|
|
79
|
+
/**
|
|
80
|
+
* Enables or disables history queries.
|
|
81
|
+
*
|
|
82
|
+
* @public
|
|
83
|
+
*/
|
|
84
|
+
const toggleHistoryQueries = wireDispatch('toggleHistoryQueries');
|
|
79
85
|
/**
|
|
80
86
|
* Debounce function for the module.
|
|
81
87
|
*/
|
|
@@ -110,8 +116,11 @@ const historyQueriesWiring = createWiring({
|
|
|
110
116
|
},
|
|
111
117
|
UserPressedRemoveHistoryQuery: {
|
|
112
118
|
removeHistoryQuery
|
|
119
|
+
},
|
|
120
|
+
UserToggledHistoryQueries: {
|
|
121
|
+
toggleHistoryQueries
|
|
113
122
|
}
|
|
114
123
|
});
|
|
115
124
|
|
|
116
|
-
export { addQueryToHistoryQueries, clearHistoryQueries, clearHistoryQueriesQuery, historyQueriesWiring, loadHistoryQueriesFromBrowserStorageWire, refreshHistoryQueriesSession, removeHistoryQuery, setHistoryQueriesQuery };
|
|
125
|
+
export { addQueryToHistoryQueries, clearHistoryQueries, clearHistoryQueriesQuery, historyQueriesWiring, loadHistoryQueriesFromBrowserStorageWire, refreshHistoryQueriesSession, removeHistoryQuery, setHistoryQueriesQuery, toggleHistoryQueries };
|
|
117
126
|
//# sourceMappingURL=wiring.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wiring.js","sources":["../../../../src/x-modules/history-queries/wiring.ts"],"sourcesContent":["import {\n namespacedWireCommit,\n namespacedWireDispatch,\n namespacedWireDispatchWithoutPayload\n} from '../../wiring/namespaced-wires.factory';\nimport { namespacedDebounce } from '../../wiring/namespaced-wires.operators';\nimport { NamespacedWireCommit, NamespacedWireDispatch } from '../../wiring/namespaced-wiring.types';\nimport { createWiring } from '../../wiring/wiring.utils';\n\n/**\n * `historyQueries` {@link XModuleName | XModule name}.\n *\n * @internal\n */\nconst moduleName = 'historyQueries';\n/**\n * WireCommit for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireCommit: NamespacedWireCommit<typeof moduleName> = namespacedWireCommit(moduleName);\n/**\n * WireDispatch for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireDispatch: NamespacedWireDispatch<typeof moduleName> = namespacedWireDispatch(moduleName);\n/**\n * WireDispatchWithoutPayload for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireDispatchWithoutPayload = namespacedWireDispatchWithoutPayload(moduleName);\n\n/**\n * Saves a new query into the history queries.\n *\n * @public\n */\nexport const addQueryToHistoryQueries = wireDispatch('addQueryToHistory');\n\n/**\n * Sets the query of the history queries module. Used for searching into the history queries.\n *\n * @public\n */\nexport const setHistoryQueriesQuery = wireCommit('setQuery');\n\n/**\n * Sets the history queries state `query` from url.\n *\n * @public\n */\nconst setUrlParams = wireDispatch('setUrlParams');\n\n/**\n * Sets the query of the history queries module to an empty string.\n *\n * @public\n */\nexport const clearHistoryQueriesQuery = wireCommit('setQuery', '');\n\n/**\n * Triggers a session refresh, extending its validity for the time configured in the\n * {@link HistoryQueriesConfig.sessionTTLInMs}.\n *\n * @public\n */\nexport const refreshHistoryQueriesSession = wireDispatchWithoutPayload('refreshSession');\n\n/**\n * Loads the history queries from the browser storage, saving them to the\n * {@link HistoryQueriesState.historyQueries}.\n *\n * @public\n */\nexport const loadHistoryQueriesFromBrowserStorageWire = wireDispatchWithoutPayload(\n 'loadHistoryQueriesFromBrowserStorage'\n);\n\n/**\n * Clears the history queries.\n *\n * @public\n */\nexport const clearHistoryQueries = wireDispatch('setHistoryQueries', []);\n\n/**\n * Removes a single history query from the history queries.\n *\n * @public\n */\nexport const removeHistoryQuery = wireDispatch('removeFromHistory');\n\n/**\n * Debounce function for the module.\n */\nconst moduleDebounce = namespacedDebounce(moduleName);\n\n/**\n * Default wiring for the {@link HistoryQueries} module.\n *\n * @internal\n */\nexport const historyQueriesWiring = createWiring({\n ParamsLoadedFromUrl: {\n setUrlParams\n },\n HistoryQueriesQueryChanged: {\n refreshHistoryQueriesSession\n },\n HistoryQueriesStorageKeyChanged: {\n loadHistoryQueriesFromBrowserStorageWire\n },\n UserClearedQuery: {\n clearHistoryQueriesQuery\n },\n UserAcceptedAQuery: {\n setHistoryQueriesQuery,\n addQueryToHistoryQueries\n },\n UserIsTypingAQuery: {\n setHistoryQueriesQueryDebounce: moduleDebounce(\n setHistoryQueriesQuery,\n ({ state }) => state.config.debounceInMs,\n { cancelOn: 'UserAcceptedAQuery' }\n )\n },\n UserPressedClearHistoryQueries: {\n clearHistoryQueries\n },\n UserPressedRemoveHistoryQuery: {\n removeHistoryQuery\n }\n});\n"],"names":[],"mappings":";;;;AASA;;;;;AAKA,MAAM,UAAU,GAAG,gBAAgB,CAAC;AACpC;;;;;AAKA,MAAM,UAAU,GAA4C,oBAAoB,CAAC,UAAU,CAAC,CAAC;AAC7F;;;;;AAKA,MAAM,YAAY,GAA8C,sBAAsB,CAAC,UAAU,CAAC,CAAC;AACnG;;;;;AAKA,MAAM,0BAA0B,GAAG,oCAAoC,CAAC,UAAU,CAAC,CAAC;AAEpF;;;;;MAKa,wBAAwB,GAAG,YAAY,CAAC,mBAAmB,EAAE;AAE1E;;;;;MAKa,sBAAsB,GAAG,UAAU,CAAC,UAAU,EAAE;AAE7D;;;;;AAKA,MAAM,YAAY,GAAG,YAAY,CAAC,cAAc,CAAC,CAAC;AAElD;;;;;MAKa,wBAAwB,GAAG,UAAU,CAAC,UAAU,EAAE,EAAE,EAAE;AAEnE;;;;;;MAMa,4BAA4B,GAAG,0BAA0B,CAAC,gBAAgB,EAAE;AAEzF;;;;;;MAMa,wCAAwC,GAAG,0BAA0B,CAChF,sCAAsC,EACtC;AAEF;;;;;MAKa,mBAAmB,GAAG,YAAY,CAAC,mBAAmB,EAAE,EAAE,EAAE;AAEzE;;;;;MAKa,kBAAkB,GAAG,YAAY,CAAC,mBAAmB,EAAE;
|
|
1
|
+
{"version":3,"file":"wiring.js","sources":["../../../../src/x-modules/history-queries/wiring.ts"],"sourcesContent":["import {\n namespacedWireCommit,\n namespacedWireDispatch,\n namespacedWireDispatchWithoutPayload\n} from '../../wiring/namespaced-wires.factory';\nimport { namespacedDebounce } from '../../wiring/namespaced-wires.operators';\nimport { NamespacedWireCommit, NamespacedWireDispatch } from '../../wiring/namespaced-wiring.types';\nimport { createWiring } from '../../wiring/wiring.utils';\n\n/**\n * `historyQueries` {@link XModuleName | XModule name}.\n *\n * @internal\n */\nconst moduleName = 'historyQueries';\n/**\n * WireCommit for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireCommit: NamespacedWireCommit<typeof moduleName> = namespacedWireCommit(moduleName);\n/**\n * WireDispatch for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireDispatch: NamespacedWireDispatch<typeof moduleName> = namespacedWireDispatch(moduleName);\n/**\n * WireDispatchWithoutPayload for {@link HistoryQueriesXModule}.\n *\n * @internal\n */\nconst wireDispatchWithoutPayload = namespacedWireDispatchWithoutPayload(moduleName);\n\n/**\n * Saves a new query into the history queries.\n *\n * @public\n */\nexport const addQueryToHistoryQueries = wireDispatch('addQueryToHistory');\n\n/**\n * Sets the query of the history queries module. Used for searching into the history queries.\n *\n * @public\n */\nexport const setHistoryQueriesQuery = wireCommit('setQuery');\n\n/**\n * Sets the history queries state `query` from url.\n *\n * @public\n */\nconst setUrlParams = wireDispatch('setUrlParams');\n\n/**\n * Sets the query of the history queries module to an empty string.\n *\n * @public\n */\nexport const clearHistoryQueriesQuery = wireCommit('setQuery', '');\n\n/**\n * Triggers a session refresh, extending its validity for the time configured in the\n * {@link HistoryQueriesConfig.sessionTTLInMs}.\n *\n * @public\n */\nexport const refreshHistoryQueriesSession = wireDispatchWithoutPayload('refreshSession');\n\n/**\n * Loads the history queries from the browser storage, saving them to the\n * {@link HistoryQueriesState.historyQueries}.\n *\n * @public\n */\nexport const loadHistoryQueriesFromBrowserStorageWire = wireDispatchWithoutPayload(\n 'loadHistoryQueriesFromBrowserStorage'\n);\n\n/**\n * Clears the history queries.\n *\n * @public\n */\nexport const clearHistoryQueries = wireDispatch('setHistoryQueries', []);\n\n/**\n * Removes a single history query from the history queries.\n *\n * @public\n */\nexport const removeHistoryQuery = wireDispatch('removeFromHistory');\n/**\n * Enables or disables history queries.\n *\n * @public\n */\nexport const toggleHistoryQueries = wireDispatch('toggleHistoryQueries');\n\n/**\n * Debounce function for the module.\n */\nconst moduleDebounce = namespacedDebounce(moduleName);\n\n/**\n * Default wiring for the {@link HistoryQueries} module.\n *\n * @internal\n */\nexport const historyQueriesWiring = createWiring({\n ParamsLoadedFromUrl: {\n setUrlParams\n },\n HistoryQueriesQueryChanged: {\n refreshHistoryQueriesSession\n },\n HistoryQueriesStorageKeyChanged: {\n loadHistoryQueriesFromBrowserStorageWire\n },\n UserClearedQuery: {\n clearHistoryQueriesQuery\n },\n UserAcceptedAQuery: {\n setHistoryQueriesQuery,\n addQueryToHistoryQueries\n },\n UserIsTypingAQuery: {\n setHistoryQueriesQueryDebounce: moduleDebounce(\n setHistoryQueriesQuery,\n ({ state }) => state.config.debounceInMs,\n { cancelOn: 'UserAcceptedAQuery' }\n )\n },\n UserPressedClearHistoryQueries: {\n clearHistoryQueries\n },\n UserPressedRemoveHistoryQuery: {\n removeHistoryQuery\n },\n UserToggledHistoryQueries: {\n toggleHistoryQueries\n }\n});\n"],"names":[],"mappings":";;;;AASA;;;;;AAKA,MAAM,UAAU,GAAG,gBAAgB,CAAC;AACpC;;;;;AAKA,MAAM,UAAU,GAA4C,oBAAoB,CAAC,UAAU,CAAC,CAAC;AAC7F;;;;;AAKA,MAAM,YAAY,GAA8C,sBAAsB,CAAC,UAAU,CAAC,CAAC;AACnG;;;;;AAKA,MAAM,0BAA0B,GAAG,oCAAoC,CAAC,UAAU,CAAC,CAAC;AAEpF;;;;;MAKa,wBAAwB,GAAG,YAAY,CAAC,mBAAmB,EAAE;AAE1E;;;;;MAKa,sBAAsB,GAAG,UAAU,CAAC,UAAU,EAAE;AAE7D;;;;;AAKA,MAAM,YAAY,GAAG,YAAY,CAAC,cAAc,CAAC,CAAC;AAElD;;;;;MAKa,wBAAwB,GAAG,UAAU,CAAC,UAAU,EAAE,EAAE,EAAE;AAEnE;;;;;;MAMa,4BAA4B,GAAG,0BAA0B,CAAC,gBAAgB,EAAE;AAEzF;;;;;;MAMa,wCAAwC,GAAG,0BAA0B,CAChF,sCAAsC,EACtC;AAEF;;;;;MAKa,mBAAmB,GAAG,YAAY,CAAC,mBAAmB,EAAE,EAAE,EAAE;AAEzE;;;;;MAKa,kBAAkB,GAAG,YAAY,CAAC,mBAAmB,EAAE;AACpE;;;;;MAKa,oBAAoB,GAAG,YAAY,CAAC,sBAAsB,EAAE;AAEzE;;;AAGA,MAAM,cAAc,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC;AAEtD;;;;;MAKa,oBAAoB,GAAG,YAAY,CAAC;IAC/C,mBAAmB,EAAE;QACnB,YAAY;KACb;IACD,0BAA0B,EAAE;QAC1B,4BAA4B;KAC7B;IACD,+BAA+B,EAAE;QAC/B,wCAAwC;KACzC;IACD,gBAAgB,EAAE;QAChB,wBAAwB;KACzB;IACD,kBAAkB,EAAE;QAClB,sBAAsB;QACtB,wBAAwB;KACzB;IACD,kBAAkB,EAAE;QAClB,8BAA8B,EAAE,cAAc,CAC5C,sBAAsB,EACtB,CAAC,EAAE,KAAK,EAAE,KAAK,KAAK,CAAC,MAAM,CAAC,YAAY,EACxC,EAAE,QAAQ,EAAE,oBAAoB,EAAE,CACnC;KACF;IACD,8BAA8B,EAAE;QAC9B,mBAAmB;KACpB;IACD,6BAA6B,EAAE;QAC7B,kBAAkB;KACnB;IACD,yBAAyB,EAAE;QACzB,oBAAoB;KACrB;CACF;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empathyco/x-components",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.75",
|
|
4
4
|
"description": "Empathy X Components",
|
|
5
5
|
"author": "Empathy Systems Corporation S.L.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -59,11 +59,11 @@
|
|
|
59
59
|
"cypress:open:component": "cypress open-ct"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@empathyco/x-adapter": "^7.0.0-alpha.
|
|
63
|
-
"@empathyco/x-deep-merge": "^1.3.0-alpha.
|
|
64
|
-
"@empathyco/x-logger": "^1.2.0-alpha.
|
|
65
|
-
"@empathyco/x-storage-service": "^2.0.0-alpha.
|
|
66
|
-
"@empathyco/x-types": "^10.0.0-alpha.
|
|
62
|
+
"@empathyco/x-adapter": "^7.0.0-alpha.16",
|
|
63
|
+
"@empathyco/x-deep-merge": "^1.3.0-alpha.4",
|
|
64
|
+
"@empathyco/x-logger": "^1.2.0-alpha.3",
|
|
65
|
+
"@empathyco/x-storage-service": "^2.0.0-alpha.2",
|
|
66
|
+
"@empathyco/x-types": "^10.0.0-alpha.20",
|
|
67
67
|
"@types/resize-observer-browser": "~0.1.5",
|
|
68
68
|
"nanoid": "~3.1.31",
|
|
69
69
|
"reflect-metadata": "~0.1.13",
|
|
@@ -127,5 +127,5 @@
|
|
|
127
127
|
"access": "public",
|
|
128
128
|
"directory": "dist"
|
|
129
129
|
},
|
|
130
|
-
"gitHead": "
|
|
130
|
+
"gitHead": "fc23e6ad9d61be10fd1c56545902ef349de2e57c"
|
|
131
131
|
}
|
|
@@ -5638,11 +5638,11 @@
|
|
|
5638
5638
|
{
|
|
5639
5639
|
"kind": "Property",
|
|
5640
5640
|
"canonicalReference": "@empathyco/x-components!BaseResultPreviousPrice#format:member",
|
|
5641
|
-
"docComment": "/**\n * Format or mask to be defined as string. - Use 'i' to define integer numbers. - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the doesn't include decimals, it is filled with zeros until reach the length defined with 'd's. - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group. - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more than one character. - Set whatever you need around the integers and decimals marks
|
|
5641
|
+
"docComment": "/**\n * Format or mask to be defined as string. - Use 'i' to define integer numbers. - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the doesn't include decimals, it is filled with zeros until reach the length defined with 'd's. - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group. - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more than one character. - Set whatever you need around the integers and decimals marks.\n *\n * @remarks\n *\n * The number of 'd', which is the maximum decimal length, MUST match with the length of decimals provided from the adapter. Otherwise, when the component truncate the decimal part, delete significant digits.\n *\n * @public\n */\n",
|
|
5642
5642
|
"excerptTokens": [
|
|
5643
5643
|
{
|
|
5644
5644
|
"kind": "Content",
|
|
5645
|
-
"text": "protected format
|
|
5645
|
+
"text": "protected format?: "
|
|
5646
5646
|
},
|
|
5647
5647
|
{
|
|
5648
5648
|
"kind": "Content",
|
|
@@ -5653,7 +5653,7 @@
|
|
|
5653
5653
|
"text": ";"
|
|
5654
5654
|
}
|
|
5655
5655
|
],
|
|
5656
|
-
"isOptional":
|
|
5656
|
+
"isOptional": true,
|
|
5657
5657
|
"releaseTag": "Public",
|
|
5658
5658
|
"name": "format",
|
|
5659
5659
|
"propertyTypeTokenRange": {
|
|
@@ -19282,6 +19282,50 @@
|
|
|
19282
19282
|
}
|
|
19283
19283
|
],
|
|
19284
19284
|
"name": "setUrlParams"
|
|
19285
|
+
},
|
|
19286
|
+
{
|
|
19287
|
+
"kind": "MethodSignature",
|
|
19288
|
+
"canonicalReference": "@empathyco/x-components!HistoryQueriesActions#toggleHistoryQueries:member(1)",
|
|
19289
|
+
"docComment": "/**\n * Toggles the history queries and stores the state in the browser storage. It also cleans the history queries when disabling them.\n *\n * @param isEnabled - Whether to enable or disable the history queries.\n */\n",
|
|
19290
|
+
"excerptTokens": [
|
|
19291
|
+
{
|
|
19292
|
+
"kind": "Content",
|
|
19293
|
+
"text": "toggleHistoryQueries(isEnabled: "
|
|
19294
|
+
},
|
|
19295
|
+
{
|
|
19296
|
+
"kind": "Content",
|
|
19297
|
+
"text": "boolean"
|
|
19298
|
+
},
|
|
19299
|
+
{
|
|
19300
|
+
"kind": "Content",
|
|
19301
|
+
"text": "): "
|
|
19302
|
+
},
|
|
19303
|
+
{
|
|
19304
|
+
"kind": "Content",
|
|
19305
|
+
"text": "void"
|
|
19306
|
+
},
|
|
19307
|
+
{
|
|
19308
|
+
"kind": "Content",
|
|
19309
|
+
"text": ";"
|
|
19310
|
+
}
|
|
19311
|
+
],
|
|
19312
|
+
"isOptional": false,
|
|
19313
|
+
"returnTypeTokenRange": {
|
|
19314
|
+
"startIndex": 3,
|
|
19315
|
+
"endIndex": 4
|
|
19316
|
+
},
|
|
19317
|
+
"releaseTag": "Public",
|
|
19318
|
+
"overloadIndex": 1,
|
|
19319
|
+
"parameters": [
|
|
19320
|
+
{
|
|
19321
|
+
"parameterName": "isEnabled",
|
|
19322
|
+
"parameterTypeTokenRange": {
|
|
19323
|
+
"startIndex": 1,
|
|
19324
|
+
"endIndex": 2
|
|
19325
|
+
}
|
|
19326
|
+
}
|
|
19327
|
+
],
|
|
19328
|
+
"name": "toggleHistoryQueries"
|
|
19285
19329
|
}
|
|
19286
19330
|
],
|
|
19287
19331
|
"extendsTokenRanges": []
|
|
@@ -19697,6 +19741,50 @@
|
|
|
19697
19741
|
],
|
|
19698
19742
|
"name": "setHistoryQueries"
|
|
19699
19743
|
},
|
|
19744
|
+
{
|
|
19745
|
+
"kind": "MethodSignature",
|
|
19746
|
+
"canonicalReference": "@empathyco/x-components!HistoryQueriesMutations#setIsEnabled:member(1)",
|
|
19747
|
+
"docComment": "/**\n * Sets the {@link HistoryQueriesState.isEnabled} property.\n *\n * @param isEnabled - The new {@link HistoryQueriesState.isEnabled}.\n */\n",
|
|
19748
|
+
"excerptTokens": [
|
|
19749
|
+
{
|
|
19750
|
+
"kind": "Content",
|
|
19751
|
+
"text": "setIsEnabled(isEnabled: "
|
|
19752
|
+
},
|
|
19753
|
+
{
|
|
19754
|
+
"kind": "Content",
|
|
19755
|
+
"text": "boolean"
|
|
19756
|
+
},
|
|
19757
|
+
{
|
|
19758
|
+
"kind": "Content",
|
|
19759
|
+
"text": "): "
|
|
19760
|
+
},
|
|
19761
|
+
{
|
|
19762
|
+
"kind": "Content",
|
|
19763
|
+
"text": "void"
|
|
19764
|
+
},
|
|
19765
|
+
{
|
|
19766
|
+
"kind": "Content",
|
|
19767
|
+
"text": ";"
|
|
19768
|
+
}
|
|
19769
|
+
],
|
|
19770
|
+
"isOptional": false,
|
|
19771
|
+
"returnTypeTokenRange": {
|
|
19772
|
+
"startIndex": 3,
|
|
19773
|
+
"endIndex": 4
|
|
19774
|
+
},
|
|
19775
|
+
"releaseTag": "Public",
|
|
19776
|
+
"overloadIndex": 1,
|
|
19777
|
+
"parameters": [
|
|
19778
|
+
{
|
|
19779
|
+
"parameterName": "isEnabled",
|
|
19780
|
+
"parameterTypeTokenRange": {
|
|
19781
|
+
"startIndex": 1,
|
|
19782
|
+
"endIndex": 2
|
|
19783
|
+
}
|
|
19784
|
+
}
|
|
19785
|
+
],
|
|
19786
|
+
"name": "setIsEnabled"
|
|
19787
|
+
},
|
|
19700
19788
|
{
|
|
19701
19789
|
"kind": "MethodSignature",
|
|
19702
19790
|
"canonicalReference": "@empathyco/x-components!HistoryQueriesMutations#setQuery:member(1)",
|
|
@@ -19873,6 +19961,32 @@
|
|
|
19873
19961
|
"endIndex": 3
|
|
19874
19962
|
}
|
|
19875
19963
|
},
|
|
19964
|
+
{
|
|
19965
|
+
"kind": "PropertySignature",
|
|
19966
|
+
"canonicalReference": "@empathyco/x-components!HistoryQueriesState#isEnabled:member",
|
|
19967
|
+
"docComment": "/**\n * Whether the history queries are enabled or disabled.\n */\n",
|
|
19968
|
+
"excerptTokens": [
|
|
19969
|
+
{
|
|
19970
|
+
"kind": "Content",
|
|
19971
|
+
"text": "isEnabled: "
|
|
19972
|
+
},
|
|
19973
|
+
{
|
|
19974
|
+
"kind": "Content",
|
|
19975
|
+
"text": "boolean"
|
|
19976
|
+
},
|
|
19977
|
+
{
|
|
19978
|
+
"kind": "Content",
|
|
19979
|
+
"text": ";"
|
|
19980
|
+
}
|
|
19981
|
+
],
|
|
19982
|
+
"isOptional": false,
|
|
19983
|
+
"releaseTag": "Public",
|
|
19984
|
+
"name": "isEnabled",
|
|
19985
|
+
"propertyTypeTokenRange": {
|
|
19986
|
+
"startIndex": 1,
|
|
19987
|
+
"endIndex": 2
|
|
19988
|
+
}
|
|
19989
|
+
},
|
|
19876
19990
|
{
|
|
19877
19991
|
"kind": "PropertySignature",
|
|
19878
19992
|
"canonicalReference": "@empathyco/x-components!HistoryQueriesState#query:member",
|
|
@@ -20139,6 +20253,32 @@
|
|
|
20139
20253
|
"startIndex": 1,
|
|
20140
20254
|
"endIndex": 2
|
|
20141
20255
|
}
|
|
20256
|
+
},
|
|
20257
|
+
{
|
|
20258
|
+
"kind": "PropertySignature",
|
|
20259
|
+
"canonicalReference": "@empathyco/x-components!HistoryQueriesXEvents#UserToggledHistoryQueries:member",
|
|
20260
|
+
"docComment": "/**\n * The user has toggled the history queries. * Payload: whether it has been set to enable or disable.\n */\n",
|
|
20261
|
+
"excerptTokens": [
|
|
20262
|
+
{
|
|
20263
|
+
"kind": "Content",
|
|
20264
|
+
"text": "UserToggledHistoryQueries: "
|
|
20265
|
+
},
|
|
20266
|
+
{
|
|
20267
|
+
"kind": "Content",
|
|
20268
|
+
"text": "boolean"
|
|
20269
|
+
},
|
|
20270
|
+
{
|
|
20271
|
+
"kind": "Content",
|
|
20272
|
+
"text": ";"
|
|
20273
|
+
}
|
|
20274
|
+
],
|
|
20275
|
+
"isOptional": false,
|
|
20276
|
+
"releaseTag": "Public",
|
|
20277
|
+
"name": "UserToggledHistoryQueries",
|
|
20278
|
+
"propertyTypeTokenRange": {
|
|
20279
|
+
"startIndex": 1,
|
|
20280
|
+
"endIndex": 2
|
|
20281
|
+
}
|
|
20142
20282
|
}
|
|
20143
20283
|
],
|
|
20144
20284
|
"extendsTokenRanges": []
|
|
@@ -45488,6 +45628,36 @@
|
|
|
45488
45628
|
"endIndex": 6
|
|
45489
45629
|
}
|
|
45490
45630
|
},
|
|
45631
|
+
{
|
|
45632
|
+
"kind": "Variable",
|
|
45633
|
+
"canonicalReference": "@empathyco/x-components!toggleHistoryQueries:var",
|
|
45634
|
+
"docComment": "/**\n * Enables or disables history queries.\n *\n * @public\n */\n",
|
|
45635
|
+
"excerptTokens": [
|
|
45636
|
+
{
|
|
45637
|
+
"kind": "Content",
|
|
45638
|
+
"text": "toggleHistoryQueries: "
|
|
45639
|
+
},
|
|
45640
|
+
{
|
|
45641
|
+
"kind": "Content",
|
|
45642
|
+
"text": "import(\"../..\")."
|
|
45643
|
+
},
|
|
45644
|
+
{
|
|
45645
|
+
"kind": "Reference",
|
|
45646
|
+
"text": "Wire",
|
|
45647
|
+
"canonicalReference": "@empathyco/x-components!Wire:type"
|
|
45648
|
+
},
|
|
45649
|
+
{
|
|
45650
|
+
"kind": "Content",
|
|
45651
|
+
"text": "<boolean>"
|
|
45652
|
+
}
|
|
45653
|
+
],
|
|
45654
|
+
"releaseTag": "Public",
|
|
45655
|
+
"name": "toggleHistoryQueries",
|
|
45656
|
+
"variableTypeTokenRange": {
|
|
45657
|
+
"startIndex": 1,
|
|
45658
|
+
"endIndex": 4
|
|
45659
|
+
}
|
|
45660
|
+
},
|
|
45491
45661
|
{
|
|
45492
45662
|
"kind": "Variable",
|
|
45493
45663
|
"canonicalReference": "@empathyco/x-components!toggleRelatedTag:var",
|
|
@@ -544,7 +544,7 @@ export class BaseResultLink extends Vue_2 {
|
|
|
544
544
|
|
|
545
545
|
// @public
|
|
546
546
|
export class BaseResultPreviousPrice extends Vue_2 {
|
|
547
|
-
protected format
|
|
547
|
+
protected format?: string;
|
|
548
548
|
protected result: Result;
|
|
549
549
|
}
|
|
550
550
|
|
|
@@ -1835,6 +1835,7 @@ export interface HistoryQueriesActions {
|
|
|
1835
1835
|
removeFromHistory(historyQuery: HistoryQuery_2): void;
|
|
1836
1836
|
setHistoryQueries(historyQueries: HistoryQuery_2[]): void;
|
|
1837
1837
|
setUrlParams(urlParams: UrlParams): void;
|
|
1838
|
+
toggleHistoryQueries(isEnabled: boolean): void;
|
|
1838
1839
|
}
|
|
1839
1840
|
|
|
1840
1841
|
// @public
|
|
@@ -1878,6 +1879,7 @@ export interface HistoryQueriesGetters {
|
|
|
1878
1879
|
// @public
|
|
1879
1880
|
export interface HistoryQueriesMutations extends QueryMutations {
|
|
1880
1881
|
setHistoryQueries(historyQueries: HistoryQuery_2[]): void;
|
|
1882
|
+
setIsEnabled(isEnabled: boolean): void;
|
|
1881
1883
|
setQuery(query: string): void;
|
|
1882
1884
|
setSessionTimeStamp(timeStamp: number): void;
|
|
1883
1885
|
}
|
|
@@ -1888,6 +1890,7 @@ export interface HistoryQueriesMutations extends QueryMutations {
|
|
|
1888
1890
|
export interface HistoryQueriesState extends QueryState {
|
|
1889
1891
|
config: HistoryQueriesConfig;
|
|
1890
1892
|
historyQueries: HistoryQuery_2[];
|
|
1893
|
+
isEnabled: boolean;
|
|
1891
1894
|
query: string;
|
|
1892
1895
|
sessionTimeStampInMs: number;
|
|
1893
1896
|
}
|
|
@@ -1919,6 +1922,9 @@ export const historyQueriesWiring: {
|
|
|
1919
1922
|
UserPressedRemoveHistoryQuery: {
|
|
1920
1923
|
removeHistoryQuery: Wire<HistoryQuery_2>;
|
|
1921
1924
|
};
|
|
1925
|
+
UserToggledHistoryQueries: {
|
|
1926
|
+
toggleHistoryQueries: Wire<boolean>;
|
|
1927
|
+
};
|
|
1922
1928
|
};
|
|
1923
1929
|
|
|
1924
1930
|
// @public
|
|
@@ -1930,6 +1936,7 @@ export interface HistoryQueriesXEvents {
|
|
|
1930
1936
|
UserPressedClearHistoryQueries: void;
|
|
1931
1937
|
UserPressedRemoveHistoryQuery: HistoryQuery_2;
|
|
1932
1938
|
UserSelectedAHistoryQuery: HistoryQuery_2;
|
|
1939
|
+
UserToggledHistoryQueries: boolean;
|
|
1933
1940
|
}
|
|
1934
1941
|
|
|
1935
1942
|
// @public
|
|
@@ -4357,6 +4364,9 @@ export interface TimedWireOperatorOptions {
|
|
|
4357
4364
|
// @public
|
|
4358
4365
|
export type TimeSelector = (storeModule: Store<RootXStoreState>) => number;
|
|
4359
4366
|
|
|
4367
|
+
// @public
|
|
4368
|
+
export const toggleHistoryQueries: Wire<boolean>;
|
|
4369
|
+
|
|
4360
4370
|
// @public
|
|
4361
4371
|
export const toggleRelatedTag: RelatedTagsXStoreModule['actions']['toggleRelatedTag'];
|
|
4362
4372
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-currency.vue?rollup-plugin-vue=script.d.ts","sourceRoot":"","sources":["../../../../src/components/currency/base-currency.vue?rollup-plugin-vue=script.ts"],"names":[],"mappings":"AAKA,OAAO,GAAG,MAAM,KAAK,CAAC;AAKtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AAEH,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,GAAG;IAC3C;;;;;;;OAOG;IAEH,SAAS,CAAC,KAAK,EAAG,MAAM,CAAC;IAEzB;;;;OAIG;IAEH,SAAS,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAE1B;;;;OAIG;IAEI,cAAc,EAAG,MAAM,CAAC;IAE/B;;;;;;OAMG;IACH,SAAS,KAAK,cAAc,IAAI,MAAM,
|
|
1
|
+
{"version":3,"file":"base-currency.vue?rollup-plugin-vue=script.d.ts","sourceRoot":"","sources":["../../../../src/components/currency/base-currency.vue?rollup-plugin-vue=script.ts"],"names":[],"mappings":"AAKA,OAAO,GAAG,MAAM,KAAK,CAAC;AAKtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AAEH,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,GAAG;IAC3C;;;;;;;OAOG;IAEH,SAAS,CAAC,KAAK,EAAG,MAAM,CAAC;IAEzB;;;;OAIG;IAEH,SAAS,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAE1B;;;;OAIG;IAEI,cAAc,EAAG,MAAM,CAAC;IAE/B;;;;;;OAMG;IACH,SAAS,KAAK,cAAc,IAAI,MAAM,CAErC;IAED;;;;;;OAMG;IACH,SAAS,KAAK,QAAQ,IAAI,MAAM,CAE/B;CACF"}
|
|
@@ -21,7 +21,6 @@ export default class BaseResultPreviousPrice extends Vue {
|
|
|
21
21
|
* - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more
|
|
22
22
|
* than one character.
|
|
23
23
|
* - Set whatever you need around the integers and decimals marks.
|
|
24
|
-
* - Default mask: 'i.iii,dd' which returns '1.345,67'.
|
|
25
24
|
*
|
|
26
25
|
* @remarks The number of 'd', which is the maximum decimal length, MUST match with the length
|
|
27
26
|
* of decimals provided from the adapter. Otherwise, when the component truncate the decimal
|
|
@@ -29,6 +28,6 @@ export default class BaseResultPreviousPrice extends Vue {
|
|
|
29
28
|
*
|
|
30
29
|
* @public
|
|
31
30
|
*/
|
|
32
|
-
protected format
|
|
31
|
+
protected format?: string;
|
|
33
32
|
}
|
|
34
33
|
//# sourceMappingURL=base-result-previous-price.vue?rollup-plugin-vue=script.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue?rollup-plugin-vue=script.d.ts","sourceRoot":"","sources":["../../../../src/components/result/base-result-previous-price.vue?rollup-plugin-vue=script.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAE5C,OAAO,GAAG,MAAM,KAAK,CAAC;AAGtB;;;;GAIG;AAIH,MAAM,CAAC,OAAO,OAAO,uBAAwB,SAAQ,GAAG;IACtD;;;;OAIG;IAEH,SAAS,CAAC,MAAM,EAAG,MAAM,CAAC;IAE1B
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue?rollup-plugin-vue=script.d.ts","sourceRoot":"","sources":["../../../../src/components/result/base-result-previous-price.vue?rollup-plugin-vue=script.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAE5C,OAAO,GAAG,MAAM,KAAK,CAAC;AAGtB;;;;GAIG;AAIH,MAAM,CAAC,OAAO,OAAO,uBAAwB,SAAQ,GAAG;IACtD;;;;OAIG;IAEH,SAAS,CAAC,MAAM,EAAG,MAAM,CAAC;IAE1B;;;;;;;;;;;;;;;OAeG;IAEH,SAAS,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC3B"}
|
|
@@ -42,5 +42,10 @@ export interface HistoryQueriesXEvents {
|
|
|
42
42
|
* * Payload: The {@link @empathyco/x-types#HistoryQuery | history query} selected.
|
|
43
43
|
*/
|
|
44
44
|
UserSelectedAHistoryQuery: HistoryQuery;
|
|
45
|
+
/**
|
|
46
|
+
* The user has toggled the history queries.
|
|
47
|
+
* * Payload: whether it has been set to enable or disable.
|
|
48
|
+
*/
|
|
49
|
+
UserToggledHistoryQueries: boolean;
|
|
45
50
|
}
|
|
46
51
|
//# sourceMappingURL=events.types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"events.types.d.ts","sourceRoot":"","sources":["../../../../src/x-modules/history-queries/events.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;;;;GAKG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,uBAAuB,EAAE,YAAY,EAAE,CAAC;IACxC;;;OAGG;IACH,0BAA0B,EAAE,MAAM,CAAC;IACnC;;;OAGG;IACH,+BAA+B,EAAE,MAAM,CAAC;IACxC;;;OAGG;IACH,4BAA4B,EAAE,YAAY,EAAE,CAAC;IAC7C;;;OAGG;IACH,8BAA8B,EAAE,IAAI,CAAC;IACrC;;;;OAIG;IACH,6BAA6B,EAAE,YAAY,CAAC;IAC5C;;;OAGG;IACH,yBAAyB,EAAE,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"events.types.d.ts","sourceRoot":"","sources":["../../../../src/x-modules/history-queries/events.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;;;;GAKG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,uBAAuB,EAAE,YAAY,EAAE,CAAC;IACxC;;;OAGG;IACH,0BAA0B,EAAE,MAAM,CAAC;IACnC;;;OAGG;IACH,+BAA+B,EAAE,MAAM,CAAC;IACxC;;;OAGG;IACH,4BAA4B,EAAE,YAAY,EAAE,CAAC;IAC7C;;;OAGG;IACH,8BAA8B,EAAE,IAAI,CAAC;IACrC;;;;OAIG;IACH,6BAA6B,EAAE,YAAY,CAAC;IAC5C;;;OAGG;IACH,yBAAyB,EAAE,YAAY,CAAC;IACxC;;;OAGG;IACH,yBAAyB,EAAE,OAAO,CAAC;CACpC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"set-history-queries.action.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/history-queries/store/actions/set-history-queries.action.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AAEtD;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,EAAE,0BAA0B,CAAC,SAAS,CAAC,CAAC,mBAAmB,
|
|
1
|
+
{"version":3,"file":"set-history-queries.action.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/history-queries/store/actions/set-history-queries.action.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AAEtD;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,EAAE,0BAA0B,CAAC,SAAS,CAAC,CAAC,mBAAmB,CAWxF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle-history-queries.action.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/history-queries/store/actions/toggle-history-queries.action.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AAEtD,eAAO,MAAM,oBAAoB,EAAE,0BAA0B,CAAC,SAAS,CAAC,CAAC,sBAAsB,CAQ5F,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/history-queries/store/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAC7D,eAAO,MAAM,8BAA8B,uBAAuB,CAAC"}
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/history-queries/store/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAC7D,eAAO,MAAM,8BAA8B,uBAAuB,CAAC;AACnE,eAAO,MAAM,2BAA2B,4BAA4B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/history-queries/store/module.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/history-queries/store/module.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,0BAA0B,EAAE,MAAM,SAAS,CAAC;AAErD;;;;GAIG;AACH,eAAO,MAAM,0BAA0B,EAAE,0BAwCxC,CAAC"}
|