@dxs-ts/eveli-ide 0.0.6 → 0.0.7

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/index.d.ts CHANGED
@@ -516,8 +516,31 @@ declare namespace HdesClient {
516
516
 
517
517
 
518
518
  declare namespace Composer {
519
+ interface SearchData {
520
+ values: readonly SearchDataEntry[];
521
+ filterLinks(keyword: string): readonly SearchResult[];
522
+ filterWorkflows(keyword: string): readonly SearchResult[];
523
+ filterArticles(keyword: string): readonly SearchResult[];
524
+ }
525
+ interface SearchDataEntry {
526
+ id: string;
527
+ type: "ARTICLE" | "LINK" | "WORKFLOW";
528
+ values: readonly SearchableValue[];
529
+ }
530
+ interface SearchResult {
531
+ source: SearchDataEntry;
532
+ matches: SearchableValue[];
533
+ }
534
+ interface SearchableValue {
535
+ id: string;
536
+ value: string;
537
+ type: "ARTICLE_NAME" | "ARTICLE_PAGE" | "WORKFLOW_NAME" | "WORKFLOW_LABEL" | "LINK_VALUE" | "LINK_LABEL";
538
+ }
539
+ type NavType = "ARTICLE_LINKS" | "ARTICLE_WORKFLOWS" | "ARTICLE_PAGES";
519
540
  interface Nav {
541
+ type: NavType;
520
542
  value?: string | null;
543
+ value2?: string | null;
521
544
  }
522
545
  interface TabData {
523
546
  nav?: Nav;
@@ -525,53 +548,87 @@ declare namespace Composer {
525
548
  }
526
549
  interface Tab extends Burger.TabSession<TabData> {
527
550
  }
528
- interface DebugSession {
529
- error?: HdesClient.StoreError;
530
- debug?: HdesClient.DebugResponse;
531
- csv?: string;
532
- json?: string;
533
- selected: HdesClient.EntityId;
534
- inputType: DebugInputType;
535
- }
536
- type DebugInputType = "CSV" | "JSON";
537
- interface DebugSessions {
538
- selected?: HdesClient.EntityId;
539
- values: Record<HdesClient.EntityId, DebugSession>;
540
- }
541
551
  interface PageUpdate {
542
552
  saved: boolean;
543
- origin: HdesClient.Entity<any>;
544
- value: HdesClient.AstCommand[];
545
- withValue(value: HdesClient.AstCommand[]): PageUpdate;
553
+ origin: StencilClient.Page;
554
+ value: StencilClient.LocalisedContent;
555
+ withValue(value: StencilClient.LocalisedContent): PageUpdate;
556
+ }
557
+ interface SessionFilter {
558
+ locale?: StencilClient.LocaleId;
559
+ withLocale(locale?: StencilClient.LocaleId): SessionFilter;
546
560
  }
547
561
  interface Session {
548
- site: HdesClient.Site;
549
- pages: Record<HdesClient.EntityId, PageUpdate>;
550
- debug: DebugSessions;
551
- branchName?: string;
552
- getDecision(decisionName: string): undefined | HdesClient.Entity<HdesClient.AstDecision>;
553
- getFlow(flowName: string): undefined | HdesClient.Entity<HdesClient.AstFlow>;
554
- getService(serviceName: string): undefined | HdesClient.Entity<HdesClient.AstService>;
555
- getEntity(id: HdesClient.EntityId): undefined | HdesClient.Entity<any>;
556
- withDebug(page: DebugSession): Session;
557
- withPage(page: HdesClient.EntityId): Session;
558
- withPageValue(page: HdesClient.EntityId, value: HdesClient.AstCommand[]): Session;
559
- withoutPages(pages: HdesClient.EntityId[]): Session;
560
- withBranch(branchName?: string): Session;
561
- withSite(site: HdesClient.Site): Session;
562
+ site: StencilClient.Site;
563
+ pages: Record<StencilClient.PageId, PageUpdate>;
564
+ articles: ArticleView[];
565
+ workflows: WorkflowView[];
566
+ links: LinkView[];
567
+ search: SearchData;
568
+ filter: SessionFilter;
569
+ getArticleName(articleId: StencilClient.ArticleId): {
570
+ missing: boolean;
571
+ name: string;
572
+ };
573
+ getArticleView(articleId: StencilClient.ArticleId): ArticleView;
574
+ getLinkView(linkId: StencilClient.LinkId): LinkView;
575
+ getLinkName(linkId: StencilClient.LinkId): {
576
+ missing: boolean;
577
+ name: string;
578
+ };
579
+ getWorkflowView(workflowId: StencilClient.WorkflowId): WorkflowView;
580
+ getWorkflowName(workflowId: StencilClient.WorkflowId): {
581
+ missing: boolean;
582
+ name: string;
583
+ };
584
+ getArticlesForLocale(locale: StencilClient.LocaleId): StencilClient.Article[];
585
+ getArticlesForLocales(locales: StencilClient.LocaleId[]): StencilClient.Article[];
586
+ withPage(page: StencilClient.PageId): Session;
587
+ withPageValue(page: StencilClient.PageId, value: StencilClient.LocalisedContent): Session;
588
+ withoutPages(pages: StencilClient.PageId[]): Session;
589
+ withLocaleFilter(locale?: StencilClient.LocaleId): Session;
590
+ withSite(site: StencilClient.Site): Session;
562
591
  }
563
592
  interface Actions {
564
593
  handleLoad(): Promise<void>;
565
- handleLoadSite(site?: HdesClient.Site): Promise<void>;
566
- handleDebugUpdate(debug: DebugSession): void;
567
- handlePageUpdate(page: HdesClient.EntityId, value: HdesClient.AstCommand[]): void;
568
- handlePageUpdateRemove(pages: HdesClient.EntityId[]): void;
569
- handleBranchUpdate(branchName?: string): void;
594
+ handleLoadSite(): Promise<void>;
595
+ handlePageUpdate(page: StencilClient.PageId, value: StencilClient.LocalisedContent): void;
596
+ handlePageUpdateRemove(pages: StencilClient.PageId[]): void;
597
+ handleLocaleFilter(locale?: StencilClient.LocaleId): void;
570
598
  }
571
599
  interface ContextType {
572
600
  session: Session;
573
601
  actions: Actions;
574
- service: HdesClient.Service;
602
+ service: StencilClient.Service;
603
+ }
604
+ interface ArticleView {
605
+ article: StencilClient.Article;
606
+ pages: PageView[];
607
+ canCreate: StencilClient.SiteLocale[];
608
+ links: LinkView[];
609
+ workflows: WorkflowView[];
610
+ children: Composer.ArticleView[];
611
+ displayOrder: number;
612
+ getPageById(pageId: StencilClient.PageId): PageView;
613
+ getPageByLocaleId(localeId: StencilClient.LocaleId): PageView;
614
+ findPageByLocaleId(localeId: StencilClient.LocaleId): PageView | undefined;
615
+ }
616
+ interface PageView {
617
+ title: string;
618
+ page: StencilClient.Page;
619
+ locale: StencilClient.SiteLocale;
620
+ }
621
+ interface LinkView {
622
+ link: StencilClient.Link;
623
+ labels: LabelView[];
624
+ }
625
+ interface WorkflowView {
626
+ workflow: StencilClient.Workflow;
627
+ labels: LabelView[];
628
+ }
629
+ interface LabelView {
630
+ label: StencilClient.LocaleLabel;
631
+ locale: StencilClient.SiteLocale;
575
632
  }
576
633
  }
577
634
 
@@ -579,32 +636,31 @@ declare namespace Composer {
579
636
  declare namespace Composer {
580
637
  const createTab: (props: {
581
638
  nav: Composer.Nav;
582
- page?: HdesClient.Entity<any>;
639
+ page?: StencilClient.Page;
583
640
  }) => ImmutableTabData;
584
641
  const ComposerContext: React.Context<ContextType>;
585
- const useUnsaved: (entity: HdesClient.Entity<any>) => boolean;
642
+ const useUnsaved: (article: StencilClient.Article) => boolean;
586
643
  const useComposer: () => {
587
644
  session: Session;
588
- service: HdesClient.Service;
645
+ service: StencilClient.Service;
589
646
  actions: Actions;
590
- site: HdesClient.Site;
591
- isArticleSaved: (entity: HdesClient.Entity<any>) => boolean;
647
+ site: StencilClient.Site;
648
+ isArticleSaved: (article: StencilClient.Article) => boolean;
592
649
  };
593
- const useSite: () => HdesClient.Site;
594
- const useBranchName: () => string | undefined;
650
+ const useSite: () => StencilClient.Site;
595
651
  const useSession: () => Session;
596
652
  const useNav: () => {
597
653
  handleInTab: (props: {
598
- article: HdesClient.Entity<any>;
654
+ article: StencilClient.Article;
655
+ type: Composer.NavType;
656
+ locale?: string | null;
657
+ secondary?: boolean;
599
658
  }) => void;
600
- findTab: (article: HdesClient.Entity<any>) => Composer.Tab | undefined;
601
- };
602
- const useDebug: () => {
603
- handleDebugInit: (selected: HdesClient.EntityId) => void;
659
+ findTab: (article: StencilClient.Article) => Composer.Tab | undefined;
604
660
  };
605
661
  const Provider: React.FC<{
606
662
  children: React.ReactNode;
607
- service: HdesClient.Service;
663
+ service: StencilClient.Service;
608
664
  }>;
609
665
  }
610
666
 
@@ -890,31 +946,8 @@ declare namespace StencilClient {
890
946
 
891
947
 
892
948
  declare namespace Composer {
893
- interface SearchData {
894
- values: readonly SearchDataEntry[];
895
- filterLinks(keyword: string): readonly SearchResult[];
896
- filterWorkflows(keyword: string): readonly SearchResult[];
897
- filterArticles(keyword: string): readonly SearchResult[];
898
- }
899
- interface SearchDataEntry {
900
- id: string;
901
- type: "ARTICLE" | "LINK" | "WORKFLOW";
902
- values: readonly SearchableValue[];
903
- }
904
- interface SearchResult {
905
- source: SearchDataEntry;
906
- matches: SearchableValue[];
907
- }
908
- interface SearchableValue {
909
- id: string;
910
- value: string;
911
- type: "ARTICLE_NAME" | "ARTICLE_PAGE" | "WORKFLOW_NAME" | "WORKFLOW_LABEL" | "LINK_VALUE" | "LINK_LABEL";
912
- }
913
- type NavType = "ARTICLE_LINKS" | "ARTICLE_WORKFLOWS" | "ARTICLE_PAGES";
914
949
  interface Nav {
915
- type: NavType;
916
950
  value?: string | null;
917
- value2?: string | null;
918
951
  }
919
952
  interface TabData {
920
953
  nav?: Nav;
@@ -922,87 +955,53 @@ declare namespace Composer {
922
955
  }
923
956
  interface Tab extends Burger.TabSession<TabData> {
924
957
  }
958
+ interface DebugSession {
959
+ error?: HdesClient.StoreError;
960
+ debug?: HdesClient.DebugResponse;
961
+ csv?: string;
962
+ json?: string;
963
+ selected: HdesClient.EntityId;
964
+ inputType: DebugInputType;
965
+ }
966
+ type DebugInputType = "CSV" | "JSON";
967
+ interface DebugSessions {
968
+ selected?: HdesClient.EntityId;
969
+ values: Record<HdesClient.EntityId, DebugSession>;
970
+ }
925
971
  interface PageUpdate {
926
972
  saved: boolean;
927
- origin: StencilClient.Page;
928
- value: StencilClient.LocalisedContent;
929
- withValue(value: StencilClient.LocalisedContent): PageUpdate;
930
- }
931
- interface SessionFilter {
932
- locale?: StencilClient.LocaleId;
933
- withLocale(locale?: StencilClient.LocaleId): SessionFilter;
973
+ origin: HdesClient.Entity<any>;
974
+ value: HdesClient.AstCommand[];
975
+ withValue(value: HdesClient.AstCommand[]): PageUpdate;
934
976
  }
935
977
  interface Session {
936
- site: StencilClient.Site;
937
- pages: Record<StencilClient.PageId, PageUpdate>;
938
- articles: ArticleView[];
939
- workflows: WorkflowView[];
940
- links: LinkView[];
941
- search: SearchData;
942
- filter: SessionFilter;
943
- getArticleName(articleId: StencilClient.ArticleId): {
944
- missing: boolean;
945
- name: string;
946
- };
947
- getArticleView(articleId: StencilClient.ArticleId): ArticleView;
948
- getLinkView(linkId: StencilClient.LinkId): LinkView;
949
- getLinkName(linkId: StencilClient.LinkId): {
950
- missing: boolean;
951
- name: string;
952
- };
953
- getWorkflowView(workflowId: StencilClient.WorkflowId): WorkflowView;
954
- getWorkflowName(workflowId: StencilClient.WorkflowId): {
955
- missing: boolean;
956
- name: string;
957
- };
958
- getArticlesForLocale(locale: StencilClient.LocaleId): StencilClient.Article[];
959
- getArticlesForLocales(locales: StencilClient.LocaleId[]): StencilClient.Article[];
960
- withPage(page: StencilClient.PageId): Session;
961
- withPageValue(page: StencilClient.PageId, value: StencilClient.LocalisedContent): Session;
962
- withoutPages(pages: StencilClient.PageId[]): Session;
963
- withLocaleFilter(locale?: StencilClient.LocaleId): Session;
964
- withSite(site: StencilClient.Site): Session;
978
+ site: HdesClient.Site;
979
+ pages: Record<HdesClient.EntityId, PageUpdate>;
980
+ debug: DebugSessions;
981
+ branchName?: string;
982
+ getDecision(decisionName: string): undefined | HdesClient.Entity<HdesClient.AstDecision>;
983
+ getFlow(flowName: string): undefined | HdesClient.Entity<HdesClient.AstFlow>;
984
+ getService(serviceName: string): undefined | HdesClient.Entity<HdesClient.AstService>;
985
+ getEntity(id: HdesClient.EntityId): undefined | HdesClient.Entity<any>;
986
+ withDebug(page: DebugSession): Session;
987
+ withPage(page: HdesClient.EntityId): Session;
988
+ withPageValue(page: HdesClient.EntityId, value: HdesClient.AstCommand[]): Session;
989
+ withoutPages(pages: HdesClient.EntityId[]): Session;
990
+ withBranch(branchName?: string): Session;
991
+ withSite(site: HdesClient.Site): Session;
965
992
  }
966
993
  interface Actions {
967
994
  handleLoad(): Promise<void>;
968
- handleLoadSite(): Promise<void>;
969
- handlePageUpdate(page: StencilClient.PageId, value: StencilClient.LocalisedContent): void;
970
- handlePageUpdateRemove(pages: StencilClient.PageId[]): void;
971
- handleLocaleFilter(locale?: StencilClient.LocaleId): void;
995
+ handleLoadSite(site?: HdesClient.Site): Promise<void>;
996
+ handleDebugUpdate(debug: DebugSession): void;
997
+ handlePageUpdate(page: HdesClient.EntityId, value: HdesClient.AstCommand[]): void;
998
+ handlePageUpdateRemove(pages: HdesClient.EntityId[]): void;
999
+ handleBranchUpdate(branchName?: string): void;
972
1000
  }
973
1001
  interface ContextType {
974
1002
  session: Session;
975
1003
  actions: Actions;
976
- service: StencilClient.Service;
977
- }
978
- interface ArticleView {
979
- article: StencilClient.Article;
980
- pages: PageView[];
981
- canCreate: StencilClient.SiteLocale[];
982
- links: LinkView[];
983
- workflows: WorkflowView[];
984
- children: Composer.ArticleView[];
985
- displayOrder: number;
986
- getPageById(pageId: StencilClient.PageId): PageView;
987
- getPageByLocaleId(localeId: StencilClient.LocaleId): PageView;
988
- findPageByLocaleId(localeId: StencilClient.LocaleId): PageView | undefined;
989
- }
990
- interface PageView {
991
- title: string;
992
- page: StencilClient.Page;
993
- locale: StencilClient.SiteLocale;
994
- }
995
- interface LinkView {
996
- link: StencilClient.Link;
997
- labels: LabelView[];
998
- }
999
- interface WorkflowView {
1000
- workflow: StencilClient.Workflow;
1001
- labels: LabelView[];
1002
- }
1003
- interface LabelView {
1004
- label: StencilClient.LocaleLabel;
1005
- locale: StencilClient.SiteLocale;
1004
+ service: HdesClient.Service;
1006
1005
  }
1007
1006
  }
1008
1007
 
@@ -1010,31 +1009,32 @@ declare namespace Composer {
1010
1009
  declare namespace Composer {
1011
1010
  const createTab: (props: {
1012
1011
  nav: Composer.Nav;
1013
- page?: StencilClient.Page;
1012
+ page?: HdesClient.Entity<any>;
1014
1013
  }) => ImmutableTabData;
1015
1014
  const ComposerContext: React.Context<ContextType>;
1016
- const useUnsaved: (article: StencilClient.Article) => boolean;
1015
+ const useUnsaved: (entity: HdesClient.Entity<any>) => boolean;
1017
1016
  const useComposer: () => {
1018
1017
  session: Session;
1019
- service: StencilClient.Service;
1018
+ service: HdesClient.Service;
1020
1019
  actions: Actions;
1021
- site: StencilClient.Site;
1022
- isArticleSaved: (article: StencilClient.Article) => boolean;
1020
+ site: HdesClient.Site;
1021
+ isArticleSaved: (entity: HdesClient.Entity<any>) => boolean;
1023
1022
  };
1024
- const useSite: () => StencilClient.Site;
1023
+ const useSite: () => HdesClient.Site;
1024
+ const useBranchName: () => string | undefined;
1025
1025
  const useSession: () => Session;
1026
1026
  const useNav: () => {
1027
1027
  handleInTab: (props: {
1028
- article: StencilClient.Article;
1029
- type: Composer.NavType;
1030
- locale?: string | null;
1031
- secondary?: boolean;
1028
+ article: HdesClient.Entity<any>;
1032
1029
  }) => void;
1033
- findTab: (article: StencilClient.Article) => Composer.Tab | undefined;
1030
+ findTab: (article: HdesClient.Entity<any>) => Composer.Tab | undefined;
1031
+ };
1032
+ const useDebug: () => {
1033
+ handleDebugInit: (selected: HdesClient.EntityId) => void;
1034
1034
  };
1035
1035
  const Provider: React.FC<{
1036
1036
  children: React.ReactNode;
1037
- service: StencilClient.Service;
1037
+ service: HdesClient.Service;
1038
1038
  }>;
1039
1039
  }
1040
1040
 
package/build/index.js CHANGED
@@ -92946,7 +92946,7 @@ const L7e = ({ site: e }) => {
92946
92946
  ] })
92947
92947
  }
92948
92948
  );
92949
- }, i0 = { tag: "eveli-ide-0.0.6", built: "10/10/2024" }, B7e = (e, t, n) => {
92949
+ }, i0 = { tag: "eveli-ide-0.0.7", built: "10/10/2024" }, B7e = (e, t, n) => {
92950
92950
  var r, i, s, o, a, l, u, d;
92951
92951
  return [
92952
92952
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxs-ts/eveli-ide",
3
- "version": "0.0.6",
3
+ "version": "0.0.7",
4
4
  "homepage": "https://github.com/digiexpress-io/digiexpress-parent",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",