@supersoniks/concorde 3.3.3 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build-infos.json +1 -1
- package/concorde-core.bundle.js +154 -154
- package/concorde-core.es.js +2365 -2355
- package/dist/concorde-core.bundle.js +154 -154
- package/dist/concorde-core.es.js +2365 -2355
- package/package.json +1 -4
- package/src/core/_types/types.ts +1 -1
- package/src/core/components/functional/queue/queue.ts +3 -4
- package/src/core/components/functional/states/states.demo.ts +5 -2
- package/src/core/components/functional/states/states.spec.ts +14 -13
- package/src/core/components/functional/submit/submit.ts +2 -2
- package/src/core/components/ui/captcha/captcha.ts +16 -12
- package/src/core/components/ui/form/input-autocomplete/input-autocomplete.ts +41 -7
- package/src/core/components/ui/pop/pop.ts +6 -6
- package/src/core/components/ui/theme/theme.ts +3 -3
- package/src/core/decorators/subscriber/bind.ts +2 -2
- package/src/core/decorators/subscriber/onAssign.ts +3 -3
- package/src/core/directives/DataProvider.ts +47 -60
- package/src/core/directives/Wording.ts +4 -4
- package/src/core/mixins/FormCheckable.ts +12 -12
- package/src/core/mixins/FormElement.ts +1 -1
- package/src/core/utils/PublisherProxy.ts +260 -178
- package/src/core/utils/Utils.ts +3 -0
- package/src/core/utils/api.ts +4 -6
- package/src/dataprovider.ts +1 -0
- package/src/directives.ts +27 -13
- package/src/docs/search/docs-search.json +0 -15
- package/src/tsconfig.json +0 -9
- package/src/tsconfig.tsbuildinfo +1 -1
- package/src/utils.ts +2 -4
- package/src/core/components/ui/toast/message-subscriber.stories.ts +0 -43
package/src/directives.ts
CHANGED
|
@@ -1,21 +1,35 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as directives from "@supersoniks/concorde/core/directives/DataProvider";
|
|
2
|
+
import {dp as pubDp, dataProvider as pubDataProvider, get as pubGet, set as pubSet} from "@supersoniks/concorde/core/utils/PublisherProxy";
|
|
2
3
|
|
|
3
4
|
import {ConcordeWindow} from "./core/_types/types";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export const
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated @see pubDp
|
|
7
|
+
*/
|
|
8
|
+
export const dp = pubDp;
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated @see pubDataProvider
|
|
11
|
+
*/
|
|
12
|
+
export const dataProvider = pubDataProvider;
|
|
13
|
+
export const subscribe = directives.subscribe;
|
|
14
|
+
export const sub = directives.sub;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* @deprecated @see pubGet
|
|
18
|
+
*/
|
|
19
|
+
export const get = pubGet;
|
|
20
|
+
/**
|
|
21
|
+
* @deprecated @see pubSet
|
|
22
|
+
*/
|
|
23
|
+
export const set = pubSet;
|
|
10
24
|
|
|
11
25
|
declare const window: ConcordeWindow;
|
|
12
26
|
|
|
13
27
|
window["concorde-directives-data-provider"] = window["concorde-directives-data-provider"] || {};
|
|
14
28
|
window["concorde-directives-data-provider"] = {
|
|
15
|
-
dp:
|
|
16
|
-
dataProvider:
|
|
17
|
-
sub:
|
|
18
|
-
subscribe:
|
|
19
|
-
get:
|
|
20
|
-
set:
|
|
29
|
+
dp: pubDp,
|
|
30
|
+
dataProvider: pubDataProvider,
|
|
31
|
+
sub: directives.sub,
|
|
32
|
+
subscribe: directives.subscribe,
|
|
33
|
+
get: pubGet,
|
|
34
|
+
set: pubSet,
|
|
21
35
|
};
|
|
@@ -4489,21 +4489,6 @@
|
|
|
4489
4489
|
}
|
|
4490
4490
|
}
|
|
4491
4491
|
},
|
|
4492
|
-
{
|
|
4493
|
-
"search": " }\n //\n render() {\n return html <div class="flex flex-col gap-2"> <sonic-select label="Users set" @change=${this.updateDataProvider}> <option value="demoUsers">First set of users</option> <option value="demoUsersAlt">Second set of users</option> </sonic-select> <sonic-input type="number" .value=${this.userIndex} @input=${this.updateUserIndex} min="0" max="9" label="Index" class="block" > </sonic-input> <sonic-button @click=${this.updateCurrentUserData} >Update current user data</sonic-button > <div class="flex flex-col gap-2 border p-2"> <div> <sonic-icon name="user" library="heroicons"></sonic-icon> ${this.user?.firstName} ${this.user?.lastName} </div> <div> <sonic-icon name="envelope" library="heroicons"></sonic-icon> ${this.user?.email} </div> <div> Theme: ${this.userSettings?.theme} | Language: ${this.userSettings?.language} </div> </div> </div> ;\n }\n}\n \n\n",
|
|
4494
|
-
"files": {
|
|
4495
|
-
"docs/_misc/on-assign.md": {
|
|
4496
|
-
"title": "@onAssign",
|
|
4497
|
-
"hashes": {
|
|
4498
|
-
"dynamic-path-driven-by-class-properties": {
|
|
4499
|
-
"count": 1,
|
|
4500
|
-
"title": "Dynamic path driven by class properties",
|
|
4501
|
-
"type": "paragraph"
|
|
4502
|
-
}
|
|
4503
|
-
}
|
|
4504
|
-
}
|
|
4505
|
-
}
|
|
4506
|
-
},
|
|
4507
4492
|
{
|
|
4508
4493
|
"search": "⚠️ Use classic string literals: @onAssign("${dataProvider}.${profileId}", "settings.${profileId}"). Do not use template literals (backticks), otherwise JavaScript would try to interpolate the value immediately.\n",
|
|
4509
4494
|
"files": {
|
package/src/tsconfig.json
CHANGED
|
@@ -734,15 +734,6 @@
|
|
|
734
734
|
"./ui/theme": [
|
|
735
735
|
"/sites/concorde/src/core/components/ui/theme/theme.ts"
|
|
736
736
|
],
|
|
737
|
-
"./message-subscriber.stories": [
|
|
738
|
-
"/sites/concorde/src/core/components/ui/toast/message-subscriber.stories.ts"
|
|
739
|
-
],
|
|
740
|
-
"./ui/message-subscriber.stories": [
|
|
741
|
-
"/sites/concorde/src/core/components/ui/toast/message-subscriber.stories.ts"
|
|
742
|
-
],
|
|
743
|
-
"./ui/toast/message-subscriber.stories": [
|
|
744
|
-
"/sites/concorde/src/core/components/ui/toast/message-subscriber.stories.ts"
|
|
745
|
-
],
|
|
746
737
|
"./message-subscriber": [
|
|
747
738
|
"/sites/concorde/src/core/components/ui/toast/message-subscriber.ts"
|
|
748
739
|
],
|
package/src/tsconfig.tsbuildinfo
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"root":["./components.ts","./concorde-loaded.ts","./decorators.ts","./directives.ts","./index.ts","./mixins.ts","./utils.ts","./core/core.ts","./core/_types/types.ts","./core/components/functional/functional.ts","./core/components/functional/date/date.ts","./core/components/functional/example/example.ts","./core/components/functional/fetch/fetch.ts","./core/components/functional/if/if.test.ts","./core/components/functional/if/if.ts","./core/components/functional/list/list.demo.ts","./core/components/functional/list/list.spec.ts","./core/components/functional/list/list.ts","./core/components/functional/mix/mix.ts","./core/components/functional/queue/queue.demo.ts","./core/components/functional/queue/queue.ts","./core/components/functional/router/redirect.ts","./core/components/functional/router/router.demo.ts","./core/components/functional/router/router.spec.ts","./core/components/functional/router/router.ts","./core/components/functional/sdui/SDUIDescriptorTransformer.ts","./core/components/functional/sdui/sdui-utils.ts","./core/components/functional/sdui/sdui.ts","./core/components/functional/sdui/types.ts","./core/components/functional/sonic-scope/sonic-scope.ts","./core/components/functional/states/states.demo.ts","./core/components/functional/states/states.spec.ts","./core/components/functional/states/states.ts","./core/components/functional/submit/submit.ts","./core/components/functional/subscriber/subscriber.ts","./core/components/functional/translation/translation.ts","./core/components/functional/value/value.ts","./core/components/ui/ui.ts","./core/components/ui/_css/scroll.ts","./core/components/ui/_css/shadow.ts","./core/components/ui/_css/size.ts","./core/components/ui/_css/type.ts","./core/components/ui/alert/alert.ts","./core/components/ui/alert-messages/alert-messages.ts","./core/components/ui/badge/badge.ts","./core/components/ui/button/button.ts","./core/components/ui/captcha/altchaStyles.ts","./core/components/ui/captcha/captcha.ts","./core/components/ui/card/card-footer.ts","./core/components/ui/card/card-header-descripton.ts","./core/components/ui/card/card-header.ts","./core/components/ui/card/card-main.ts","./core/components/ui/card/card.ts","./core/components/ui/divider/divider.ts","./core/components/ui/form/checkbox/checkbox.ts","./core/components/ui/form/css/form-control.ts","./core/components/ui/form/fieldset/fieldset.ts","./core/components/ui/form/fieldset/legend-description.ts","./core/components/ui/form/fieldset/legend.ts","./core/components/ui/form/form-actions/form-actions.ts","./core/components/ui/form/form-layout/form-layout.ts","./core/components/ui/form/input/input.ts","./core/components/ui/form/input/password-helper.ts","./core/components/ui/form/input/same-value-helper.ts","./core/components/ui/form/input-autocomplete/input-autocomplete.ts","./core/components/ui/form/radio/radio.ts","./core/components/ui/form/select/select.ts","./core/components/ui/form/switch/switch.ts","./core/components/ui/form/textarea/textarea.ts","./core/components/ui/group/group.ts","./core/components/ui/icon/icon.stories.ts","./core/components/ui/icon/icon.ts","./core/components/ui/icon/icons.ts","./core/components/ui/image/image.ts","./core/components/ui/link/link.ts","./core/components/ui/loader/loader.stories.ts","./core/components/ui/loader/loader.ts","./core/components/ui/loader/styles/fixed.ts","./core/components/ui/loader/styles/inline.ts","./core/components/ui/menu/menu-item.ts","./core/components/ui/menu/menu.ts","./core/components/ui/modal/modal-actions.ts","./core/components/ui/modal/modal-close.ts","./core/components/ui/modal/modal-content.ts","./core/components/ui/modal/modal-subtitle.ts","./core/components/ui/modal/modal-title.ts","./core/components/ui/modal/modal.stories.ts","./core/components/ui/modal/modal.ts","./core/components/ui/pop/pop.ts","./core/components/ui/progress/progress.ts","./core/components/ui/table/table-caption.ts","./core/components/ui/table/table-tbody.ts","./core/components/ui/table/table-td.ts","./core/components/ui/table/table-tfoot.ts","./core/components/ui/table/table-th.ts","./core/components/ui/table/table-thead.ts","./core/components/ui/table/table-tr.ts","./core/components/ui/table/table.ts","./core/components/ui/theme/theme.ts","./core/components/ui/theme/theme-collection/core-variables.ts","./core/components/ui/theme/theme-collection/dark.ts","./core/components/ui/theme/theme-collection/light.ts","./core/components/ui/toast/message-subscriber.
|
|
1
|
+
{"root":["./components.ts","./concorde-loaded.ts","./dataprovider.ts","./decorators.ts","./directives.ts","./index.ts","./mixins.ts","./utils.ts","./core/core.ts","./core/_types/types.ts","./core/components/functional/functional.ts","./core/components/functional/date/date.ts","./core/components/functional/example/example.ts","./core/components/functional/fetch/fetch.ts","./core/components/functional/if/if.test.ts","./core/components/functional/if/if.ts","./core/components/functional/list/list.demo.ts","./core/components/functional/list/list.spec.ts","./core/components/functional/list/list.ts","./core/components/functional/mix/mix.ts","./core/components/functional/queue/queue.demo.ts","./core/components/functional/queue/queue.ts","./core/components/functional/router/redirect.ts","./core/components/functional/router/router.demo.ts","./core/components/functional/router/router.spec.ts","./core/components/functional/router/router.ts","./core/components/functional/sdui/SDUIDescriptorTransformer.ts","./core/components/functional/sdui/sdui-utils.ts","./core/components/functional/sdui/sdui.ts","./core/components/functional/sdui/types.ts","./core/components/functional/sonic-scope/sonic-scope.ts","./core/components/functional/states/states.demo.ts","./core/components/functional/states/states.spec.ts","./core/components/functional/states/states.ts","./core/components/functional/submit/submit.ts","./core/components/functional/subscriber/subscriber.ts","./core/components/functional/translation/translation.ts","./core/components/functional/value/value.ts","./core/components/ui/ui.ts","./core/components/ui/_css/scroll.ts","./core/components/ui/_css/shadow.ts","./core/components/ui/_css/size.ts","./core/components/ui/_css/type.ts","./core/components/ui/alert/alert.ts","./core/components/ui/alert-messages/alert-messages.ts","./core/components/ui/badge/badge.ts","./core/components/ui/button/button.ts","./core/components/ui/captcha/altchaStyles.ts","./core/components/ui/captcha/captcha.ts","./core/components/ui/card/card-footer.ts","./core/components/ui/card/card-header-descripton.ts","./core/components/ui/card/card-header.ts","./core/components/ui/card/card-main.ts","./core/components/ui/card/card.ts","./core/components/ui/divider/divider.ts","./core/components/ui/form/checkbox/checkbox.ts","./core/components/ui/form/css/form-control.ts","./core/components/ui/form/fieldset/fieldset.ts","./core/components/ui/form/fieldset/legend-description.ts","./core/components/ui/form/fieldset/legend.ts","./core/components/ui/form/form-actions/form-actions.ts","./core/components/ui/form/form-layout/form-layout.ts","./core/components/ui/form/input/input.ts","./core/components/ui/form/input/password-helper.ts","./core/components/ui/form/input/same-value-helper.ts","./core/components/ui/form/input-autocomplete/input-autocomplete.ts","./core/components/ui/form/radio/radio.ts","./core/components/ui/form/select/select.ts","./core/components/ui/form/switch/switch.ts","./core/components/ui/form/textarea/textarea.ts","./core/components/ui/group/group.ts","./core/components/ui/icon/icon.stories.ts","./core/components/ui/icon/icon.ts","./core/components/ui/icon/icons.ts","./core/components/ui/image/image.ts","./core/components/ui/link/link.ts","./core/components/ui/loader/loader.stories.ts","./core/components/ui/loader/loader.ts","./core/components/ui/loader/styles/fixed.ts","./core/components/ui/loader/styles/inline.ts","./core/components/ui/menu/menu-item.ts","./core/components/ui/menu/menu.ts","./core/components/ui/modal/modal-actions.ts","./core/components/ui/modal/modal-close.ts","./core/components/ui/modal/modal-content.ts","./core/components/ui/modal/modal-subtitle.ts","./core/components/ui/modal/modal-title.ts","./core/components/ui/modal/modal.stories.ts","./core/components/ui/modal/modal.ts","./core/components/ui/pop/pop.ts","./core/components/ui/progress/progress.ts","./core/components/ui/table/table-caption.ts","./core/components/ui/table/table-tbody.ts","./core/components/ui/table/table-td.ts","./core/components/ui/table/table-tfoot.ts","./core/components/ui/table/table-th.ts","./core/components/ui/table/table-thead.ts","./core/components/ui/table/table-tr.ts","./core/components/ui/table/table.ts","./core/components/ui/theme/theme.ts","./core/components/ui/theme/theme-collection/core-variables.ts","./core/components/ui/theme/theme-collection/dark.ts","./core/components/ui/theme/theme-collection/light.ts","./core/components/ui/toast/message-subscriber.ts","./core/components/ui/toast/toast-item.ts","./core/components/ui/toast/toast.ts","./core/components/ui/toast/types.ts","./core/components/ui/tooltip/tooltip.ts","./core/decorators/Subscriber.ts","./core/decorators/subscriber/ancestorAttribute.ts","./core/decorators/subscriber/autoFill.ts","./core/decorators/subscriber/autoSubscribe.ts","./core/decorators/subscriber/bind.ts","./core/decorators/subscriber/common.ts","./core/decorators/subscriber/onAssign.ts","./core/directives/DataProvider.ts","./core/directives/Wording.ts","./core/mixins/Fetcher.ts","./core/mixins/FormCheckable.ts","./core/mixins/FormElement.ts","./core/mixins/FormInput.ts","./core/mixins/Subscriber.ts","./core/mixins/TemplatesContainer.ts","./core/mixins/mixins.ts","./core/utils/Arrays.ts","./core/utils/DataBindObserver.ts","./core/utils/Electron.ts","./core/utils/Format.ts","./core/utils/HTML.ts","./core/utils/LocationHandler.ts","./core/utils/Objects.ts","./core/utils/PublisherProxy.ts","./core/utils/Utils.ts","./core/utils/aesCrypto.ts","./core/utils/api.ts","./core/utils/route.spec.ts","./core/utils/route.ts","./core/utils/url-pattern.ts","./test-utils/TestUtils.ts"],"version":"5.9.2"}
|
package/src/utils.ts
CHANGED
|
@@ -14,9 +14,8 @@ import * as myLocationHandler from "@supersoniks/concorde/core/utils/LocationHan
|
|
|
14
14
|
export const LocationHandler = myLocationHandler.default;
|
|
15
15
|
import * as myObjects from "@supersoniks/concorde/core/utils/Objects";
|
|
16
16
|
export const Objects = myObjects.default;
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export const PublisherManager = myPublisherProxy.PublisherManager;
|
|
17
|
+
export * from "@supersoniks/concorde/core/utils/PublisherProxy";
|
|
18
|
+
import { PublisherManager } from "@supersoniks/concorde/core/utils/PublisherProxy";
|
|
20
19
|
import * as myApi from "@supersoniks/concorde/core/utils/api";
|
|
21
20
|
export const api = myApi.default;
|
|
22
21
|
import * as myURLPattern from "@supersoniks/concorde/core/utils/url-pattern";
|
|
@@ -34,7 +33,6 @@ window["concorde-utils"] = {
|
|
|
34
33
|
HTML: HTML,
|
|
35
34
|
LocationHandler: LocationHandler,
|
|
36
35
|
Objects: Objects,
|
|
37
|
-
PublisherProxy: PublisherProxy,
|
|
38
36
|
PublisherManager: PublisherManager,
|
|
39
37
|
api: api,
|
|
40
38
|
URLPattern: URLPattern,
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import {SonicToast} from "./toast";
|
|
2
|
-
import "./message-subscriber";
|
|
3
|
-
import "@supersoniks/concorde/core/components/ui/button/button";
|
|
4
|
-
import {PublisherManager} from "@supersoniks/concorde/core/utils/PublisherProxy";
|
|
5
|
-
import {html} from "lit";
|
|
6
|
-
|
|
7
|
-
// More on default export: https://storybook.js.org/docs/web-components/writing-stories/introduction#default-export
|
|
8
|
-
export default {
|
|
9
|
-
component: "sonic-toast-message-subscriber",
|
|
10
|
-
title: "core/components/ui/MessageSubscriber",
|
|
11
|
-
argTypes: {
|
|
12
|
-
status: {control: "select", options: ["success", "error", "warning", "info"]},
|
|
13
|
-
},
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
const Template: any = (conf: any) => {
|
|
17
|
-
setTimeout(() => {
|
|
18
|
-
SonicToast.removeAll();
|
|
19
|
-
PublisherManager.get("toast-message-exemple").messages = [
|
|
20
|
-
{content: "Chargé via un message", status: conf.status, type: "public"},
|
|
21
|
-
];
|
|
22
|
-
}, 1);
|
|
23
|
-
return html`
|
|
24
|
-
<sonic-toast-message-subscriber dataProvider="toast-message-exemple"></sonic-toast-message-subscriber>
|
|
25
|
-
<!--
|
|
26
|
-
Cet exemple éxécute :
|
|
27
|
-
PublisherManager.get("toast-message-exemple").messages=
|
|
28
|
-
[
|
|
29
|
-
{
|
|
30
|
-
content:"Chargé via un message",
|
|
31
|
-
status:conf.status,
|
|
32
|
-
type:"public"
|
|
33
|
-
}
|
|
34
|
-
]
|
|
35
|
-
-->
|
|
36
|
-
`;
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
export const Example = Template.bind({
|
|
40
|
-
title: "SonicToast",
|
|
41
|
-
text: "The modern web is here!",
|
|
42
|
-
status: "success",
|
|
43
|
-
});
|