document-model 1.0.16 → 1.0.18
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/browser/document/schema/zod.d.ts +24 -0
- package/dist/browser/document/types.d.ts +8 -7
- package/dist/browser/document/utils/base.d.ts +4 -4
- package/dist/browser/document-model/gen/header/object.d.ts +2 -2
- package/dist/browser/document-model/gen/module/object.d.ts +2 -2
- package/dist/browser/document-model/gen/object.d.ts +4 -4
- package/dist/browser/document-model/gen/operation/object.d.ts +2 -2
- package/dist/browser/document-model/gen/operation-error/object.d.ts +2 -2
- package/dist/browser/document-model/gen/operation-example/object.d.ts +2 -2
- package/dist/browser/document-model/gen/reducer.d.ts +2 -2
- package/dist/browser/document-model/gen/schema/types.d.ts +12 -5
- package/dist/browser/document-model/gen/schema/zod.d.ts +20 -1
- package/dist/browser/document-model/gen/state/object.d.ts +2 -2
- package/dist/browser/document-model/gen/types.d.ts +3 -3
- package/dist/browser/document-model/gen/utils.d.ts +4 -2
- package/dist/browser/document-model/gen/versioning/object.d.ts +2 -2
- package/dist/browser/document-model/index.d.ts +9 -9
- package/dist/browser/document-model.cjs +1 -1
- package/dist/browser/document-model.js +2 -2
- package/dist/browser/document.cjs +1 -1
- package/dist/browser/document.js +2 -2
- package/dist/browser/index.cjs +1 -1
- package/dist/browser/index.js +3 -3
- package/dist/browser/internal/{index-37753e74.js → index-10a12861.js} +520 -441
- package/dist/{node/internal/index-0e7af6c6.js → browser/internal/index-2aee8ea9.js} +1 -1
- package/dist/{node/internal/index-124bda95.js → browser/internal/index-a1282d5c.js} +1 -1
- package/dist/browser/internal/index-ec8cd58f.js +22 -0
- package/dist/browser/internal/object-24df9d92.js +6 -0
- package/dist/browser/internal/{object-17aee7a9.js → object-7e8eaff4.js} +377 -365
- package/dist/node/document/schema/zod.d.ts +24 -0
- package/dist/node/document/types.d.ts +8 -7
- package/dist/node/document/utils/base.d.ts +4 -4
- package/dist/node/document-model/gen/header/object.d.ts +2 -2
- package/dist/node/document-model/gen/module/object.d.ts +2 -2
- package/dist/node/document-model/gen/object.d.ts +4 -4
- package/dist/node/document-model/gen/operation/object.d.ts +2 -2
- package/dist/node/document-model/gen/operation-error/object.d.ts +2 -2
- package/dist/node/document-model/gen/operation-example/object.d.ts +2 -2
- package/dist/node/document-model/gen/reducer.d.ts +2 -2
- package/dist/node/document-model/gen/schema/types.d.ts +12 -5
- package/dist/node/document-model/gen/schema/zod.d.ts +20 -1
- package/dist/node/document-model/gen/state/object.d.ts +2 -2
- package/dist/node/document-model/gen/types.d.ts +3 -3
- package/dist/node/document-model/gen/utils.d.ts +4 -2
- package/dist/node/document-model/gen/versioning/object.d.ts +2 -2
- package/dist/node/document-model/index.d.ts +9 -9
- package/dist/node/document-model.cjs +1 -1
- package/dist/node/document-model.js +2 -2
- package/dist/node/document.cjs +1 -1
- package/dist/node/document.js +2 -2
- package/dist/node/index.cjs +1 -1
- package/dist/node/index.js +3 -3
- package/dist/node/internal/{index-9037f83a.js → index-09364517.js} +520 -441
- package/dist/node/internal/index-284511b8.js +22 -0
- package/dist/{browser/internal/index-f5587600.js → node/internal/index-2d4783d9.js} +1 -1
- package/dist/{browser/internal/index-9b4d67fc.js → node/internal/index-5ef0c6b0.js} +1 -1
- package/dist/node/internal/object-21f3d2ee.js +1 -0
- package/dist/node/internal/{object-f7cd4777.js → object-c32ea0a0.js} +154 -142
- package/package.json +1 -1
- package/dist/browser/internal/index-a5150e7e.js +0 -22
- package/dist/browser/internal/object-28a1a8bf.js +0 -6
- package/dist/node/internal/index-417115f1.js +0 -22
- package/dist/node/internal/object-f3dd289e.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var dt = Object.defineProperty;
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { c as
|
|
2
|
+
var ut = (t, e, o) => e in t ? dt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: o }) : t[e] = o;
|
|
3
|
+
var le = (t, e, o) => (ut(t, typeof e != "symbol" ? e + "" : e, o), o);
|
|
4
|
+
import { c as mt, i as Et, a as ht, b as Ot, s as gt, d as St, l as bt, e as ft, f as s, B as l, g as _t, h as It } from "./object-c32ea0a0.js";
|
|
5
5
|
import "json-stringify-deterministic";
|
|
6
6
|
import "immer";
|
|
7
7
|
import "crypto";
|
|
@@ -12,7 +12,7 @@ import "jszip";
|
|
|
12
12
|
import { z as r } from "zod";
|
|
13
13
|
const Tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
14
14
|
__proto__: null
|
|
15
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
15
|
+
}, Symbol.toStringTag, { value: "Module" })), ce = {
|
|
16
16
|
id: "powerhouse/document-model",
|
|
17
17
|
name: "DocumentModel",
|
|
18
18
|
extension: "phdm",
|
|
@@ -539,8 +539,9 @@ const Tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
539
539
|
}
|
|
540
540
|
],
|
|
541
541
|
state: {
|
|
542
|
-
|
|
543
|
-
|
|
542
|
+
global: {
|
|
543
|
+
schema: "",
|
|
544
|
+
initialValue: `{
|
|
544
545
|
"id": "",
|
|
545
546
|
"name": "",
|
|
546
547
|
"extension": "",
|
|
@@ -562,11 +563,17 @@ const Tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
562
563
|
}
|
|
563
564
|
]
|
|
564
565
|
}`,
|
|
565
|
-
|
|
566
|
+
examples: []
|
|
567
|
+
},
|
|
568
|
+
local: {
|
|
569
|
+
schema: "",
|
|
570
|
+
initialValue: "{}",
|
|
571
|
+
examples: []
|
|
572
|
+
}
|
|
566
573
|
}
|
|
567
574
|
}
|
|
568
575
|
]
|
|
569
|
-
}, de = (t) => t != null,
|
|
576
|
+
}, de = (t) => t != null, Rt = r.any().refine((t) => de(t));
|
|
570
577
|
function f() {
|
|
571
578
|
return r.object({
|
|
572
579
|
__typename: r.literal("AddChangeLogItemInput").optional(),
|
|
@@ -599,7 +606,7 @@ function T() {
|
|
|
599
606
|
operationId: r.string()
|
|
600
607
|
});
|
|
601
608
|
}
|
|
602
|
-
function
|
|
609
|
+
function R() {
|
|
603
610
|
return r.object({
|
|
604
611
|
description: r.string().nullish(),
|
|
605
612
|
id: r.string(),
|
|
@@ -611,21 +618,22 @@ function b() {
|
|
|
611
618
|
scope: r.literal("local").or(r.literal("global")).nullish()
|
|
612
619
|
});
|
|
613
620
|
}
|
|
614
|
-
function
|
|
621
|
+
function A() {
|
|
615
622
|
return r.object({
|
|
623
|
+
scope: r.string(),
|
|
616
624
|
example: r.string(),
|
|
617
625
|
id: r.string(),
|
|
618
626
|
insertBefore: r.string().nullish()
|
|
619
627
|
});
|
|
620
628
|
}
|
|
621
|
-
function
|
|
629
|
+
function ue() {
|
|
622
630
|
return r.object({
|
|
623
631
|
__typename: r.literal("Author").optional(),
|
|
624
632
|
name: r.string(),
|
|
625
633
|
website: r.string().nullable()
|
|
626
634
|
});
|
|
627
635
|
}
|
|
628
|
-
function
|
|
636
|
+
function x() {
|
|
629
637
|
return r.object({
|
|
630
638
|
__typename: r.literal("CodeExample").optional(),
|
|
631
639
|
id: r.string(),
|
|
@@ -638,11 +646,6 @@ function D() {
|
|
|
638
646
|
id: r.string()
|
|
639
647
|
});
|
|
640
648
|
}
|
|
641
|
-
function x() {
|
|
642
|
-
return r.object({
|
|
643
|
-
id: r.string()
|
|
644
|
-
});
|
|
645
|
-
}
|
|
646
649
|
function M() {
|
|
647
650
|
return r.object({
|
|
648
651
|
id: r.string()
|
|
@@ -663,16 +666,21 @@ function P() {
|
|
|
663
666
|
id: r.string()
|
|
664
667
|
});
|
|
665
668
|
}
|
|
666
|
-
function
|
|
669
|
+
function j() {
|
|
670
|
+
return r.object({
|
|
671
|
+
scope: r.string(),
|
|
672
|
+
id: r.string()
|
|
673
|
+
});
|
|
674
|
+
}
|
|
675
|
+
function At() {
|
|
667
676
|
return r.union([
|
|
668
677
|
f(),
|
|
669
678
|
_(),
|
|
670
679
|
I(),
|
|
671
680
|
T(),
|
|
672
|
-
b(),
|
|
673
681
|
R(),
|
|
682
|
+
A(),
|
|
674
683
|
D(),
|
|
675
|
-
x(),
|
|
676
684
|
M(),
|
|
677
685
|
N(),
|
|
678
686
|
L(),
|
|
@@ -682,15 +690,15 @@ function Rt() {
|
|
|
682
690
|
k(),
|
|
683
691
|
y(),
|
|
684
692
|
w(),
|
|
685
|
-
U(),
|
|
686
693
|
v(),
|
|
694
|
+
U(),
|
|
695
|
+
V(),
|
|
687
696
|
F(),
|
|
688
697
|
H(),
|
|
689
|
-
V(),
|
|
690
698
|
X(),
|
|
691
699
|
G(),
|
|
692
|
-
W(),
|
|
693
700
|
$(),
|
|
701
|
+
W(),
|
|
694
702
|
z(),
|
|
695
703
|
B(),
|
|
696
704
|
q(),
|
|
@@ -705,50 +713,51 @@ function Rt() {
|
|
|
705
713
|
oe(),
|
|
706
714
|
ne(),
|
|
707
715
|
ie(),
|
|
708
|
-
se()
|
|
716
|
+
se(),
|
|
717
|
+
ae()
|
|
709
718
|
]);
|
|
710
719
|
}
|
|
711
|
-
function
|
|
720
|
+
function xt() {
|
|
712
721
|
return r.object({
|
|
713
722
|
__typename: r.literal("DocumentModelState").optional(),
|
|
714
|
-
author:
|
|
723
|
+
author: ue(),
|
|
715
724
|
description: r.string(),
|
|
716
725
|
extension: r.string(),
|
|
717
726
|
id: r.string(),
|
|
718
727
|
name: r.string(),
|
|
719
|
-
specifications: r.array(
|
|
728
|
+
specifications: r.array(me())
|
|
720
729
|
});
|
|
721
730
|
}
|
|
722
|
-
function
|
|
731
|
+
function me() {
|
|
723
732
|
return r.object({
|
|
724
733
|
__typename: r.literal("DocumentSpecification").optional(),
|
|
725
734
|
changeLog: r.array(r.string()),
|
|
726
|
-
modules: r.array(
|
|
727
|
-
state:
|
|
735
|
+
modules: r.array(Ee()),
|
|
736
|
+
state: Se(),
|
|
728
737
|
version: r.number()
|
|
729
738
|
});
|
|
730
739
|
}
|
|
731
|
-
function
|
|
740
|
+
function Ee() {
|
|
732
741
|
return r.object({
|
|
733
742
|
__typename: r.literal("Module").optional(),
|
|
734
743
|
description: r.string().nullable(),
|
|
735
744
|
id: r.string(),
|
|
736
745
|
name: r.string(),
|
|
737
|
-
operations: r.array(
|
|
746
|
+
operations: r.array(he())
|
|
738
747
|
});
|
|
739
748
|
}
|
|
740
|
-
function
|
|
749
|
+
function C() {
|
|
741
750
|
return r.object({
|
|
742
751
|
newModuleId: r.string(),
|
|
743
752
|
operationId: r.string()
|
|
744
753
|
});
|
|
745
754
|
}
|
|
746
|
-
function
|
|
755
|
+
function he() {
|
|
747
756
|
return r.object({
|
|
748
757
|
__typename: r.literal("Operation").optional(),
|
|
749
758
|
description: r.string().nullable(),
|
|
750
|
-
errors: r.array(
|
|
751
|
-
examples: r.array(
|
|
759
|
+
errors: r.array(Oe()),
|
|
760
|
+
examples: r.array(x()),
|
|
752
761
|
id: r.string(),
|
|
753
762
|
name: r.string().nullable(),
|
|
754
763
|
reducer: r.string().nullable(),
|
|
@@ -757,7 +766,7 @@ function Ee() {
|
|
|
757
766
|
scope: r.literal("local").or(r.literal("global"))
|
|
758
767
|
});
|
|
759
768
|
}
|
|
760
|
-
function
|
|
769
|
+
function Oe() {
|
|
761
770
|
return r.object({
|
|
762
771
|
__typename: r.literal("OperationError").optional(),
|
|
763
772
|
code: r.string().nullable(),
|
|
@@ -767,24 +776,24 @@ function he() {
|
|
|
767
776
|
template: r.string().nullable()
|
|
768
777
|
});
|
|
769
778
|
}
|
|
770
|
-
function
|
|
779
|
+
function k() {
|
|
771
780
|
return r.object({
|
|
772
781
|
__typename: r.literal("ReorderChangeLogItemsInput").optional(),
|
|
773
782
|
order: r.array(r.string())
|
|
774
783
|
});
|
|
775
784
|
}
|
|
776
|
-
function
|
|
785
|
+
function y() {
|
|
777
786
|
return r.object({
|
|
778
787
|
moduleId: r.string(),
|
|
779
788
|
order: r.array(r.string())
|
|
780
789
|
});
|
|
781
790
|
}
|
|
782
|
-
function
|
|
791
|
+
function w() {
|
|
783
792
|
return r.object({
|
|
784
793
|
order: r.array(r.string())
|
|
785
794
|
});
|
|
786
795
|
}
|
|
787
|
-
function
|
|
796
|
+
function v() {
|
|
788
797
|
return r.object({
|
|
789
798
|
operationId: r.string(),
|
|
790
799
|
order: r.array(r.string())
|
|
@@ -796,8 +805,9 @@ function U() {
|
|
|
796
805
|
order: r.array(r.string())
|
|
797
806
|
});
|
|
798
807
|
}
|
|
799
|
-
function
|
|
808
|
+
function V() {
|
|
800
809
|
return r.object({
|
|
810
|
+
scope: r.string(),
|
|
801
811
|
order: r.array(r.string())
|
|
802
812
|
});
|
|
803
813
|
}
|
|
@@ -811,17 +821,18 @@ function H() {
|
|
|
811
821
|
authorWebsite: r.string()
|
|
812
822
|
});
|
|
813
823
|
}
|
|
814
|
-
function
|
|
824
|
+
function X() {
|
|
815
825
|
return r.object({
|
|
826
|
+
scope: r.string(),
|
|
816
827
|
initialValue: r.string()
|
|
817
828
|
});
|
|
818
829
|
}
|
|
819
|
-
function
|
|
830
|
+
function G() {
|
|
820
831
|
return r.object({
|
|
821
832
|
description: r.string()
|
|
822
833
|
});
|
|
823
834
|
}
|
|
824
|
-
function
|
|
835
|
+
function $() {
|
|
825
836
|
return r.object({
|
|
826
837
|
extension: r.string()
|
|
827
838
|
});
|
|
@@ -831,111 +842,119 @@ function W() {
|
|
|
831
842
|
id: r.string()
|
|
832
843
|
});
|
|
833
844
|
}
|
|
834
|
-
function
|
|
845
|
+
function z() {
|
|
835
846
|
return r.object({
|
|
836
847
|
name: r.string()
|
|
837
848
|
});
|
|
838
849
|
}
|
|
839
|
-
function
|
|
850
|
+
function B() {
|
|
840
851
|
return r.object({
|
|
841
852
|
description: r.string().nullish(),
|
|
842
853
|
id: r.string()
|
|
843
854
|
});
|
|
844
855
|
}
|
|
845
|
-
function
|
|
856
|
+
function q() {
|
|
846
857
|
return r.object({
|
|
847
858
|
id: r.string(),
|
|
848
859
|
name: r.string().nullish()
|
|
849
860
|
});
|
|
850
861
|
}
|
|
851
|
-
function
|
|
862
|
+
function J() {
|
|
852
863
|
return r.object({
|
|
853
864
|
description: r.string().nullish(),
|
|
854
865
|
id: r.string()
|
|
855
866
|
});
|
|
856
867
|
}
|
|
857
|
-
function
|
|
868
|
+
function K() {
|
|
858
869
|
return r.object({
|
|
859
870
|
errorCode: r.string().nullish(),
|
|
860
871
|
id: r.string()
|
|
861
872
|
});
|
|
862
873
|
}
|
|
863
|
-
function
|
|
874
|
+
function Q() {
|
|
864
875
|
return r.object({
|
|
865
876
|
errorDescription: r.string().nullish(),
|
|
866
877
|
id: r.string()
|
|
867
878
|
});
|
|
868
879
|
}
|
|
869
|
-
function
|
|
880
|
+
function Y() {
|
|
870
881
|
return r.object({
|
|
871
882
|
errorName: r.string().nullish(),
|
|
872
883
|
id: r.string()
|
|
873
884
|
});
|
|
874
885
|
}
|
|
875
|
-
function
|
|
886
|
+
function Z() {
|
|
876
887
|
return r.object({
|
|
877
888
|
errorTemplate: r.string().nullish(),
|
|
878
889
|
id: r.string()
|
|
879
890
|
});
|
|
880
891
|
}
|
|
881
|
-
function
|
|
892
|
+
function ee() {
|
|
882
893
|
return r.object({
|
|
883
894
|
id: r.string(),
|
|
884
895
|
name: r.string().nullish()
|
|
885
896
|
});
|
|
886
897
|
}
|
|
887
|
-
function
|
|
898
|
+
function ge() {
|
|
888
899
|
return r.object({
|
|
889
900
|
id: r.string(),
|
|
890
901
|
scope: r.literal("global").or(r.literal("local"))
|
|
891
902
|
});
|
|
892
903
|
}
|
|
893
|
-
function
|
|
904
|
+
function te() {
|
|
894
905
|
return r.object({
|
|
895
906
|
id: r.string(),
|
|
896
907
|
reducer: r.string().nullish()
|
|
897
908
|
});
|
|
898
909
|
}
|
|
899
|
-
function
|
|
910
|
+
function re() {
|
|
900
911
|
return r.object({
|
|
901
912
|
id: r.string(),
|
|
902
913
|
schema: r.string().nullish()
|
|
903
914
|
});
|
|
904
915
|
}
|
|
905
|
-
function
|
|
916
|
+
function oe() {
|
|
906
917
|
return r.object({
|
|
907
918
|
id: r.string(),
|
|
908
919
|
template: r.string().nullish()
|
|
909
920
|
});
|
|
910
921
|
}
|
|
911
|
-
function
|
|
922
|
+
function ne() {
|
|
912
923
|
return r.object({
|
|
924
|
+
scope: r.string(),
|
|
913
925
|
schema: r.string()
|
|
914
926
|
});
|
|
915
927
|
}
|
|
916
|
-
function
|
|
928
|
+
function b() {
|
|
917
929
|
return r.object({
|
|
918
930
|
__typename: r.literal("State").optional(),
|
|
919
|
-
examples: r.array(
|
|
931
|
+
examples: r.array(x()),
|
|
920
932
|
initialValue: r.string(),
|
|
921
933
|
schema: r.string()
|
|
922
934
|
});
|
|
923
935
|
}
|
|
924
|
-
function
|
|
936
|
+
function Se() {
|
|
937
|
+
return r.object({
|
|
938
|
+
global: b(),
|
|
939
|
+
local: b()
|
|
940
|
+
});
|
|
941
|
+
}
|
|
942
|
+
function ie() {
|
|
925
943
|
return r.object({
|
|
926
944
|
__typename: r.literal("UpdateChangeLogItemInput").optional(),
|
|
927
945
|
id: r.string(),
|
|
928
946
|
newContent: r.string()
|
|
929
947
|
});
|
|
930
948
|
}
|
|
931
|
-
function
|
|
949
|
+
function se() {
|
|
932
950
|
return r.object({
|
|
933
951
|
example: r.string(),
|
|
934
952
|
id: r.string()
|
|
935
953
|
});
|
|
936
954
|
}
|
|
937
|
-
function
|
|
955
|
+
function ae() {
|
|
938
956
|
return r.object({
|
|
957
|
+
scope: r.string(),
|
|
939
958
|
id: r.string(),
|
|
940
959
|
newExample: r.string()
|
|
941
960
|
});
|
|
@@ -946,56 +965,57 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
946
965
|
AddModuleInputSchema: _,
|
|
947
966
|
AddOperationErrorInputSchema: I,
|
|
948
967
|
AddOperationExampleInputSchema: T,
|
|
949
|
-
AddOperationInputSchema:
|
|
950
|
-
AddStateExampleInputSchema:
|
|
951
|
-
AuthorSchema:
|
|
952
|
-
CodeExampleSchema:
|
|
968
|
+
AddOperationInputSchema: R,
|
|
969
|
+
AddStateExampleInputSchema: A,
|
|
970
|
+
AuthorSchema: ue,
|
|
971
|
+
CodeExampleSchema: x,
|
|
953
972
|
DeleteChangeLogItemInputSchema: D,
|
|
954
|
-
DeleteModuleInputSchema:
|
|
955
|
-
DeleteOperationErrorInputSchema:
|
|
956
|
-
DeleteOperationExampleInputSchema:
|
|
957
|
-
DeleteOperationInputSchema:
|
|
958
|
-
DeleteStateExampleInputSchema:
|
|
959
|
-
DocumentModelInputSchema:
|
|
960
|
-
DocumentModelStateSchema:
|
|
961
|
-
DocumentSpecificationSchema:
|
|
962
|
-
ModuleSchema:
|
|
963
|
-
MoveOperationInputSchema:
|
|
964
|
-
OperationErrorSchema:
|
|
965
|
-
OperationSchema:
|
|
966
|
-
ReorderChangeLogItemsInputSchema:
|
|
967
|
-
ReorderModuleOperationsInputSchema:
|
|
968
|
-
ReorderModulesInputSchema:
|
|
969
|
-
ReorderOperationErrorsInputSchema:
|
|
973
|
+
DeleteModuleInputSchema: M,
|
|
974
|
+
DeleteOperationErrorInputSchema: N,
|
|
975
|
+
DeleteOperationExampleInputSchema: L,
|
|
976
|
+
DeleteOperationInputSchema: P,
|
|
977
|
+
DeleteStateExampleInputSchema: j,
|
|
978
|
+
DocumentModelInputSchema: At,
|
|
979
|
+
DocumentModelStateSchema: xt,
|
|
980
|
+
DocumentSpecificationSchema: me,
|
|
981
|
+
ModuleSchema: Ee,
|
|
982
|
+
MoveOperationInputSchema: C,
|
|
983
|
+
OperationErrorSchema: Oe,
|
|
984
|
+
OperationSchema: he,
|
|
985
|
+
ReorderChangeLogItemsInputSchema: k,
|
|
986
|
+
ReorderModuleOperationsInputSchema: y,
|
|
987
|
+
ReorderModulesInputSchema: w,
|
|
988
|
+
ReorderOperationErrorsInputSchema: v,
|
|
970
989
|
ReorderOperationExamplesInputSchema: U,
|
|
971
|
-
ReorderStateExamplesInputSchema:
|
|
990
|
+
ReorderStateExamplesInputSchema: V,
|
|
991
|
+
ScopeStateSchema: Se,
|
|
972
992
|
SetAuthorNameInputSchema: F,
|
|
973
993
|
SetAuthorWebsiteInputSchema: H,
|
|
974
|
-
SetInitialStateInputSchema:
|
|
975
|
-
SetModelDescriptionInputSchema:
|
|
976
|
-
SetModelExtensionInputSchema:
|
|
994
|
+
SetInitialStateInputSchema: X,
|
|
995
|
+
SetModelDescriptionInputSchema: G,
|
|
996
|
+
SetModelExtensionInputSchema: $,
|
|
977
997
|
SetModelIdInputSchema: W,
|
|
978
|
-
SetModelNameInputSchema:
|
|
979
|
-
SetModuleDescriptionInputSchema:
|
|
980
|
-
SetModuleNameInputSchema:
|
|
981
|
-
SetOperationDescriptionInputSchema:
|
|
982
|
-
SetOperationErrorCodeInputSchema:
|
|
983
|
-
SetOperationErrorDescriptionInputSchema:
|
|
984
|
-
SetOperationErrorNameInputSchema:
|
|
985
|
-
SetOperationErrorTemplateInputSchema:
|
|
986
|
-
SetOperationNameInputSchema:
|
|
987
|
-
SetOperationReducerInputSchema:
|
|
988
|
-
SetOperationSchemaInputSchema:
|
|
989
|
-
SetOperationScopeInputSchema:
|
|
990
|
-
SetOperationTemplateInputSchema:
|
|
991
|
-
SetStateSchemaInputSchema:
|
|
992
|
-
StateSchema:
|
|
993
|
-
UpdateChangeLogItemInputSchema:
|
|
994
|
-
UpdateOperationExampleInputSchema:
|
|
995
|
-
UpdateStateExampleInputSchema:
|
|
996
|
-
definedNonNullAnySchema:
|
|
998
|
+
SetModelNameInputSchema: z,
|
|
999
|
+
SetModuleDescriptionInputSchema: B,
|
|
1000
|
+
SetModuleNameInputSchema: q,
|
|
1001
|
+
SetOperationDescriptionInputSchema: J,
|
|
1002
|
+
SetOperationErrorCodeInputSchema: K,
|
|
1003
|
+
SetOperationErrorDescriptionInputSchema: Q,
|
|
1004
|
+
SetOperationErrorNameInputSchema: Y,
|
|
1005
|
+
SetOperationErrorTemplateInputSchema: Z,
|
|
1006
|
+
SetOperationNameInputSchema: ee,
|
|
1007
|
+
SetOperationReducerInputSchema: te,
|
|
1008
|
+
SetOperationSchemaInputSchema: re,
|
|
1009
|
+
SetOperationScopeInputSchema: ge,
|
|
1010
|
+
SetOperationTemplateInputSchema: oe,
|
|
1011
|
+
SetStateSchemaInputSchema: ne,
|
|
1012
|
+
StateSchema: b,
|
|
1013
|
+
UpdateChangeLogItemInputSchema: ie,
|
|
1014
|
+
UpdateOperationExampleInputSchema: se,
|
|
1015
|
+
UpdateStateExampleInputSchema: ae,
|
|
1016
|
+
definedNonNullAnySchema: Rt,
|
|
997
1017
|
isDefinedNonNullAny: de
|
|
998
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1018
|
+
}, Symbol.toStringTag, { value: "Module" })), d = {
|
|
999
1019
|
setModelNameOperation(t, e) {
|
|
1000
1020
|
t.name = e.input.name;
|
|
1001
1021
|
},
|
|
@@ -1030,9 +1050,9 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1030
1050
|
releaseNewVersionOperation(t, e) {
|
|
1031
1051
|
throw new Error('Reducer "releaseNewVersionOperation" not yet implemented');
|
|
1032
1052
|
}
|
|
1033
|
-
},
|
|
1053
|
+
}, Mt = (t) => {
|
|
1034
1054
|
const e = {};
|
|
1035
|
-
return t.forEach((
|
|
1055
|
+
return t.forEach((o, n) => e[o] = n), (o, n) => (e[n.id] || 999999) - (e[o.id] || 999999);
|
|
1036
1056
|
}, h = {
|
|
1037
1057
|
addModuleOperation(t, e) {
|
|
1038
1058
|
t.specifications[t.specifications.length - 1].modules.push({
|
|
@@ -1043,33 +1063,33 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1043
1063
|
});
|
|
1044
1064
|
},
|
|
1045
1065
|
setModuleNameOperation(t, e) {
|
|
1046
|
-
const
|
|
1047
|
-
for (let
|
|
1048
|
-
|
|
1066
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1067
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1068
|
+
o.modules[n].id === e.input.id && (o.modules[n].name = e.input.name || "");
|
|
1049
1069
|
},
|
|
1050
1070
|
setModuleDescriptionOperation(t, e) {
|
|
1051
|
-
const
|
|
1052
|
-
for (let
|
|
1053
|
-
|
|
1071
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1072
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1073
|
+
o.modules[n].id === e.input.id && (o.modules[n].description = e.input.description || "");
|
|
1054
1074
|
},
|
|
1055
1075
|
deleteModuleOperation(t, e) {
|
|
1056
|
-
const
|
|
1057
|
-
|
|
1058
|
-
(
|
|
1076
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1077
|
+
o.modules = o.modules.filter(
|
|
1078
|
+
(n) => n.id != e.input.id
|
|
1059
1079
|
);
|
|
1060
1080
|
},
|
|
1061
1081
|
reorderModulesOperation(t, e) {
|
|
1062
|
-
t.specifications[t.specifications.length - 1].modules.sort(
|
|
1082
|
+
t.specifications[t.specifications.length - 1].modules.sort(Mt(e.input.order));
|
|
1063
1083
|
}
|
|
1064
|
-
},
|
|
1084
|
+
}, Nt = (t) => {
|
|
1065
1085
|
const e = {};
|
|
1066
|
-
return t.forEach((
|
|
1067
|
-
},
|
|
1086
|
+
return t.forEach((o, n) => e[o] = n), (o, n) => (e[n.id] || 999999) - (e[o.id] || 999999);
|
|
1087
|
+
}, c = {
|
|
1068
1088
|
addOperationErrorOperation(t, e) {
|
|
1069
|
-
const
|
|
1070
|
-
for (let
|
|
1071
|
-
for (let i = 0; i <
|
|
1072
|
-
|
|
1089
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1090
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1091
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1092
|
+
o.modules[n].operations[i].id == e.input.operationId && o.modules[n].operations[i].errors.push({
|
|
1073
1093
|
id: e.input.id,
|
|
1074
1094
|
name: e.input.errorName || "",
|
|
1075
1095
|
code: e.input.errorCode || "",
|
|
@@ -1078,91 +1098,91 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1078
1098
|
});
|
|
1079
1099
|
},
|
|
1080
1100
|
setOperationErrorCodeOperation(t, e) {
|
|
1081
|
-
const
|
|
1082
|
-
for (let
|
|
1083
|
-
for (let i = 0; i <
|
|
1084
|
-
for (let a = 0; a <
|
|
1085
|
-
|
|
1101
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1102
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1103
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1104
|
+
for (let a = 0; a < o.modules[n].operations[i].errors.length; a++)
|
|
1105
|
+
o.modules[n].operations[i].errors[a].id == e.input.id && (o.modules[n].operations[i].errors[a].code = e.input.errorCode || "");
|
|
1086
1106
|
},
|
|
1087
1107
|
setOperationErrorNameOperation(t, e) {
|
|
1088
|
-
const
|
|
1089
|
-
for (let
|
|
1090
|
-
for (let i = 0; i <
|
|
1091
|
-
for (let a = 0; a <
|
|
1092
|
-
|
|
1108
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1109
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1110
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1111
|
+
for (let a = 0; a < o.modules[n].operations[i].errors.length; a++)
|
|
1112
|
+
o.modules[n].operations[i].errors[a].id == e.input.id && (o.modules[n].operations[i].errors[a].name = e.input.errorName || "");
|
|
1093
1113
|
},
|
|
1094
1114
|
setOperationErrorDescriptionOperation(t, e) {
|
|
1095
|
-
const
|
|
1096
|
-
for (let
|
|
1097
|
-
for (let i = 0; i <
|
|
1098
|
-
for (let a = 0; a <
|
|
1099
|
-
|
|
1115
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1116
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1117
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1118
|
+
for (let a = 0; a < o.modules[n].operations[i].errors.length; a++)
|
|
1119
|
+
o.modules[n].operations[i].errors[a].id == e.input.id && (o.modules[n].operations[i].errors[a].description = e.input.errorDescription || "");
|
|
1100
1120
|
},
|
|
1101
1121
|
setOperationErrorTemplateOperation(t, e) {
|
|
1102
|
-
const
|
|
1103
|
-
for (let
|
|
1104
|
-
for (let i = 0; i <
|
|
1105
|
-
for (let a = 0; a <
|
|
1106
|
-
|
|
1122
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1123
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1124
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1125
|
+
for (let a = 0; a < o.modules[n].operations[i].errors.length; a++)
|
|
1126
|
+
o.modules[n].operations[i].errors[a].id == e.input.id && (o.modules[n].operations[i].errors[a].template = e.input.errorTemplate || "");
|
|
1107
1127
|
},
|
|
1108
1128
|
deleteOperationErrorOperation(t, e) {
|
|
1109
|
-
const
|
|
1110
|
-
for (let
|
|
1111
|
-
for (let i = 0; i <
|
|
1112
|
-
|
|
1129
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1130
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1131
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1132
|
+
o.modules[n].operations[i].errors = o.modules[n].operations[i].errors.filter((a) => a.id != e.input.id);
|
|
1113
1133
|
},
|
|
1114
1134
|
reorderOperationErrorsOperation(t, e) {
|
|
1115
|
-
const
|
|
1116
|
-
for (let
|
|
1117
|
-
for (let i = 0; i <
|
|
1118
|
-
|
|
1119
|
-
|
|
1135
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1136
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1137
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1138
|
+
o.modules[n].operations[i].id == e.input.operationId && o.modules[n].operations[i].errors.sort(
|
|
1139
|
+
Nt(e.input.order)
|
|
1120
1140
|
);
|
|
1121
1141
|
}
|
|
1122
|
-
},
|
|
1142
|
+
}, Lt = (t) => {
|
|
1123
1143
|
const e = {};
|
|
1124
|
-
return t.forEach((
|
|
1144
|
+
return t.forEach((o, n) => e[o] = n), (o, n) => (e[n.id] || 999999) - (e[o.id] || 999999);
|
|
1125
1145
|
}, S = {
|
|
1126
1146
|
addOperationExampleOperation(t, e) {
|
|
1127
|
-
const
|
|
1128
|
-
for (let
|
|
1129
|
-
for (let i = 0; i <
|
|
1130
|
-
|
|
1147
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1148
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1149
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1150
|
+
o.modules[n].operations[i].id == e.input.operationId && o.modules[n].operations[i].examples.push({
|
|
1131
1151
|
id: e.input.id,
|
|
1132
1152
|
value: e.input.example
|
|
1133
1153
|
});
|
|
1134
1154
|
},
|
|
1135
1155
|
updateOperationExampleOperation(t, e) {
|
|
1136
|
-
const
|
|
1137
|
-
for (let
|
|
1138
|
-
for (let i = 0; i <
|
|
1139
|
-
for (let a = 0; a <
|
|
1140
|
-
|
|
1156
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1157
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1158
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1159
|
+
for (let a = 0; a < o.modules[n].operations[i].examples.length; a++)
|
|
1160
|
+
o.modules[n].operations[i].examples[a].id == e.input.id && (o.modules[n].operations[i].examples[a].value = e.input.example);
|
|
1141
1161
|
},
|
|
1142
1162
|
deleteOperationExampleOperation(t, e) {
|
|
1143
|
-
const
|
|
1144
|
-
for (let
|
|
1145
|
-
for (let i = 0; i <
|
|
1146
|
-
|
|
1163
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1164
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1165
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1166
|
+
o.modules[n].operations[i].examples = o.modules[n].operations[i].examples.filter(
|
|
1147
1167
|
(a) => a.id != e.input.id
|
|
1148
1168
|
);
|
|
1149
1169
|
},
|
|
1150
1170
|
reorderOperationExamplesOperation(t, e) {
|
|
1151
|
-
const
|
|
1152
|
-
for (let
|
|
1153
|
-
for (let i = 0; i <
|
|
1154
|
-
|
|
1155
|
-
|
|
1171
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1172
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1173
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1174
|
+
o.modules[n].operations[i].id == e.input.operationId && o.modules[n].operations[i].examples.sort(
|
|
1175
|
+
Lt(e.input.order)
|
|
1156
1176
|
);
|
|
1157
1177
|
}
|
|
1158
|
-
},
|
|
1178
|
+
}, Pt = (t) => {
|
|
1159
1179
|
const e = {};
|
|
1160
|
-
return t.forEach((
|
|
1180
|
+
return t.forEach((o, n) => e[o] = n), (o, n) => (e[n.id] || 999999) - (e[o.id] || 999999);
|
|
1161
1181
|
}, p = {
|
|
1162
1182
|
addOperationOperation(t, e) {
|
|
1163
|
-
const
|
|
1164
|
-
for (let
|
|
1165
|
-
|
|
1183
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1184
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1185
|
+
o.modules[n].id == e.input.moduleId && o.modules[n].operations.push({
|
|
1166
1186
|
id: e.input.id,
|
|
1167
1187
|
name: e.input.name,
|
|
1168
1188
|
description: e.input.description || "",
|
|
@@ -1175,253 +1195,302 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1175
1195
|
});
|
|
1176
1196
|
},
|
|
1177
1197
|
setOperationNameOperation(t, e) {
|
|
1178
|
-
const
|
|
1179
|
-
for (let
|
|
1180
|
-
for (let i = 0; i <
|
|
1181
|
-
|
|
1198
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1199
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1200
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1201
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].name = e.input.name || "");
|
|
1182
1202
|
},
|
|
1183
1203
|
setOperationScopeOperation(t, e) {
|
|
1184
|
-
const
|
|
1185
|
-
for (let
|
|
1186
|
-
for (let i = 0; i <
|
|
1187
|
-
|
|
1204
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1205
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1206
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1207
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].scope = e.input.scope || "global");
|
|
1188
1208
|
},
|
|
1189
1209
|
setOperationSchemaOperation(t, e) {
|
|
1190
|
-
const
|
|
1191
|
-
for (let
|
|
1192
|
-
for (let i = 0; i <
|
|
1193
|
-
|
|
1210
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1211
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1212
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1213
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].schema = e.input.schema || "");
|
|
1194
1214
|
},
|
|
1195
1215
|
setOperationDescriptionOperation(t, e) {
|
|
1196
|
-
const
|
|
1197
|
-
for (let
|
|
1198
|
-
for (let i = 0; i <
|
|
1199
|
-
|
|
1216
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1217
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1218
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1219
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].description = e.input.description || "");
|
|
1200
1220
|
},
|
|
1201
1221
|
setOperationTemplateOperation(t, e) {
|
|
1202
|
-
const
|
|
1203
|
-
for (let
|
|
1204
|
-
for (let i = 0; i <
|
|
1205
|
-
|
|
1222
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1223
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1224
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1225
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].template = e.input.template || "");
|
|
1206
1226
|
},
|
|
1207
1227
|
setOperationReducerOperation(t, e) {
|
|
1208
|
-
const
|
|
1209
|
-
for (let
|
|
1210
|
-
for (let i = 0; i <
|
|
1211
|
-
|
|
1228
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1229
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1230
|
+
for (let i = 0; i < o.modules[n].operations.length; i++)
|
|
1231
|
+
o.modules[n].operations[i].id == e.input.id && (o.modules[n].operations[i].reducer = e.input.reducer || "");
|
|
1212
1232
|
},
|
|
1213
1233
|
moveOperationOperation(t, e) {
|
|
1214
|
-
const
|
|
1215
|
-
for (let i = 0; i <
|
|
1216
|
-
|
|
1217
|
-
for (let i = 0; i <
|
|
1218
|
-
|
|
1234
|
+
const o = [], n = t.specifications[t.specifications.length - 1];
|
|
1235
|
+
for (let i = 0; i < n.modules.length; i++)
|
|
1236
|
+
n.modules[i].operations = n.modules[i].operations.filter((a) => a.id == e.input.operationId ? (o.push(a), !1) : !0);
|
|
1237
|
+
for (let i = 0; i < n.modules.length; i++)
|
|
1238
|
+
n.modules[i].id == e.input.newModuleId && n.modules[i].operations.push(...o);
|
|
1219
1239
|
},
|
|
1220
1240
|
deleteOperationOperation(t, e) {
|
|
1221
|
-
const
|
|
1222
|
-
for (let
|
|
1223
|
-
|
|
1241
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1242
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1243
|
+
o.modules[n].operations = o.modules[n].operations.filter((i) => i.id != e.input.id);
|
|
1224
1244
|
},
|
|
1225
1245
|
reorderModuleOperationsOperation(t, e) {
|
|
1226
|
-
const
|
|
1227
|
-
for (let
|
|
1228
|
-
|
|
1229
|
-
|
|
1246
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1247
|
+
for (let n = 0; n < o.modules.length; n++)
|
|
1248
|
+
o.modules[n].id == e.input.moduleId && o.modules[n].operations.sort(
|
|
1249
|
+
Pt(e.input.order)
|
|
1230
1250
|
);
|
|
1231
1251
|
}
|
|
1232
|
-
},
|
|
1252
|
+
}, jt = (t) => {
|
|
1233
1253
|
const e = {};
|
|
1234
|
-
return t.forEach((
|
|
1254
|
+
return t.forEach((o, n) => e[o] = n), (o, n) => (e[n.id] || 999999) - (e[o.id] || 999999);
|
|
1235
1255
|
}, u = {
|
|
1236
1256
|
setStateSchemaOperation(t, e) {
|
|
1237
|
-
const
|
|
1238
|
-
|
|
1257
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1258
|
+
if (Object.keys(o.state).includes(e.input.scope))
|
|
1259
|
+
o.state[e.input.scope].schema = e.input.schema;
|
|
1260
|
+
else
|
|
1261
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1239
1262
|
},
|
|
1240
1263
|
setInitialStateOperation(t, e) {
|
|
1241
|
-
const
|
|
1242
|
-
|
|
1264
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1265
|
+
if (Object.keys(o.state).includes(e.input.scope))
|
|
1266
|
+
o.state[e.input.scope].initialValue = e.input.initialValue;
|
|
1267
|
+
else
|
|
1268
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1243
1269
|
},
|
|
1244
1270
|
addStateExampleOperation(t, e) {
|
|
1245
|
-
t.specifications[t.specifications.length - 1]
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1271
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1272
|
+
if (Object.keys(o.state).includes(e.input.scope))
|
|
1273
|
+
o.state[e.input.scope].examples.push({
|
|
1274
|
+
id: e.input.id,
|
|
1275
|
+
value: e.input.example
|
|
1276
|
+
});
|
|
1277
|
+
else
|
|
1278
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1249
1279
|
},
|
|
1250
1280
|
updateStateExampleOperation(t, e) {
|
|
1251
|
-
const
|
|
1252
|
-
|
|
1253
|
-
|
|
1281
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1282
|
+
if (!Object.keys(o.state).includes(e.input.scope))
|
|
1283
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1284
|
+
const n = o.state[e.input.scope].examples;
|
|
1285
|
+
for (let i = 0; i < n.length; i++)
|
|
1286
|
+
n[i].id == e.input.id && (n[i].value = e.input.newExample);
|
|
1254
1287
|
},
|
|
1255
1288
|
deleteStateExampleOperation(t, e) {
|
|
1256
|
-
const
|
|
1257
|
-
|
|
1258
|
-
(
|
|
1259
|
-
|
|
1289
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1290
|
+
if (Object.keys(o.state).includes(e.input.scope))
|
|
1291
|
+
o.state[e.input.scope].examples = o.state[e.input.scope].examples.filter((n) => n.id != e.input.id);
|
|
1292
|
+
else
|
|
1293
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1260
1294
|
},
|
|
1261
1295
|
reorderStateExamplesOperation(t, e) {
|
|
1262
|
-
t.specifications[t.specifications.length - 1]
|
|
1296
|
+
const o = t.specifications[t.specifications.length - 1];
|
|
1297
|
+
if (Object.keys(o.state).includes(e.input.scope))
|
|
1298
|
+
o.state[e.input.scope].examples.sort(jt(e.input.order));
|
|
1299
|
+
else
|
|
1300
|
+
throw new Error(`Invalid scope: ${e.input.scope}`);
|
|
1263
1301
|
}
|
|
1264
|
-
},
|
|
1265
|
-
if (
|
|
1302
|
+
}, Ct = (t, e) => {
|
|
1303
|
+
if (Et(e))
|
|
1266
1304
|
return t;
|
|
1267
1305
|
switch (e.type) {
|
|
1268
1306
|
case "SET_MODEL_NAME":
|
|
1269
|
-
|
|
1307
|
+
z().parse(e.input), d.setModelNameOperation(t.global, e);
|
|
1270
1308
|
break;
|
|
1271
1309
|
case "SET_MODEL_ID":
|
|
1272
|
-
W().parse(e.input),
|
|
1310
|
+
W().parse(e.input), d.setModelIdOperation(t.global, e);
|
|
1273
1311
|
break;
|
|
1274
1312
|
case "SET_MODEL_EXTENSION":
|
|
1275
|
-
|
|
1313
|
+
$().parse(e.input), d.setModelExtensionOperation(t.global, e);
|
|
1276
1314
|
break;
|
|
1277
1315
|
case "SET_MODEL_DESCRIPTION":
|
|
1278
|
-
|
|
1316
|
+
G().parse(e.input), d.setModelDescriptionOperation(t.global, e);
|
|
1279
1317
|
break;
|
|
1280
1318
|
case "SET_AUTHOR_NAME":
|
|
1281
|
-
F().parse(e.input),
|
|
1319
|
+
F().parse(e.input), d.setAuthorNameOperation(t.global, e);
|
|
1282
1320
|
break;
|
|
1283
1321
|
case "SET_AUTHOR_WEBSITE":
|
|
1284
|
-
H().parse(e.input),
|
|
1322
|
+
H().parse(e.input), d.setAuthorWebsiteOperation(t.global, e);
|
|
1285
1323
|
break;
|
|
1286
1324
|
case "ADD_CHANGE_LOG_ITEM":
|
|
1287
|
-
f().parse(e.input), E.addChangeLogItemOperation(t, e);
|
|
1325
|
+
f().parse(e.input), E.addChangeLogItemOperation(t.global, e);
|
|
1288
1326
|
break;
|
|
1289
1327
|
case "UPDATE_CHANGE_LOG_ITEM":
|
|
1290
|
-
|
|
1328
|
+
ie().parse(e.input), E.updateChangeLogItemOperation(
|
|
1329
|
+
t.global,
|
|
1330
|
+
e
|
|
1331
|
+
);
|
|
1291
1332
|
break;
|
|
1292
1333
|
case "DELETE_CHANGE_LOG_ITEM":
|
|
1293
|
-
D().parse(e.input), E.deleteChangeLogItemOperation(
|
|
1334
|
+
D().parse(e.input), E.deleteChangeLogItemOperation(
|
|
1335
|
+
t.global,
|
|
1336
|
+
e
|
|
1337
|
+
);
|
|
1294
1338
|
break;
|
|
1295
1339
|
case "REORDER_CHANGE_LOG_ITEMS":
|
|
1296
|
-
|
|
1340
|
+
k().parse(e.input), E.reorderChangeLogItemsOperation(
|
|
1341
|
+
t.global,
|
|
1342
|
+
e
|
|
1343
|
+
);
|
|
1297
1344
|
break;
|
|
1298
1345
|
case "RELEASE_NEW_VERSION":
|
|
1299
1346
|
if (Object.keys(e.input).length > 0)
|
|
1300
1347
|
throw new Error(
|
|
1301
1348
|
"Expected empty input for action RELEASE_NEW_VERSION"
|
|
1302
1349
|
);
|
|
1303
|
-
E.releaseNewVersionOperation(t, e);
|
|
1350
|
+
E.releaseNewVersionOperation(t.global, e);
|
|
1304
1351
|
break;
|
|
1305
1352
|
case "ADD_MODULE":
|
|
1306
|
-
_().parse(e.input), h.addModuleOperation(t, e);
|
|
1353
|
+
_().parse(e.input), h.addModuleOperation(t.global, e);
|
|
1307
1354
|
break;
|
|
1308
1355
|
case "SET_MODULE_NAME":
|
|
1309
|
-
|
|
1356
|
+
q().parse(e.input), h.setModuleNameOperation(t.global, e);
|
|
1310
1357
|
break;
|
|
1311
1358
|
case "SET_MODULE_DESCRIPTION":
|
|
1312
|
-
|
|
1359
|
+
B().parse(e.input), h.setModuleDescriptionOperation(t.global, e);
|
|
1313
1360
|
break;
|
|
1314
1361
|
case "DELETE_MODULE":
|
|
1315
|
-
|
|
1362
|
+
M().parse(e.input), h.deleteModuleOperation(t.global, e);
|
|
1316
1363
|
break;
|
|
1317
1364
|
case "REORDER_MODULES":
|
|
1318
|
-
|
|
1365
|
+
w().parse(e.input), h.reorderModulesOperation(t.global, e);
|
|
1319
1366
|
break;
|
|
1320
1367
|
case "ADD_OPERATION_ERROR":
|
|
1321
|
-
I().parse(e.input),
|
|
1368
|
+
I().parse(e.input), c.addOperationErrorOperation(
|
|
1369
|
+
t.global,
|
|
1370
|
+
e
|
|
1371
|
+
);
|
|
1322
1372
|
break;
|
|
1323
1373
|
case "SET_OPERATION_ERROR_CODE":
|
|
1324
|
-
|
|
1374
|
+
K().parse(e.input), c.setOperationErrorCodeOperation(
|
|
1375
|
+
t.global,
|
|
1376
|
+
e
|
|
1377
|
+
);
|
|
1325
1378
|
break;
|
|
1326
1379
|
case "SET_OPERATION_ERROR_NAME":
|
|
1327
|
-
|
|
1380
|
+
Y().parse(e.input), c.setOperationErrorNameOperation(
|
|
1381
|
+
t.global,
|
|
1382
|
+
e
|
|
1383
|
+
);
|
|
1328
1384
|
break;
|
|
1329
1385
|
case "SET_OPERATION_ERROR_DESCRIPTION":
|
|
1330
|
-
|
|
1331
|
-
t,
|
|
1386
|
+
Q().parse(e.input), c.setOperationErrorDescriptionOperation(
|
|
1387
|
+
t.global,
|
|
1332
1388
|
e
|
|
1333
1389
|
);
|
|
1334
1390
|
break;
|
|
1335
1391
|
case "SET_OPERATION_ERROR_TEMPLATE":
|
|
1336
|
-
|
|
1337
|
-
t,
|
|
1392
|
+
Z().parse(e.input), c.setOperationErrorTemplateOperation(
|
|
1393
|
+
t.global,
|
|
1338
1394
|
e
|
|
1339
1395
|
);
|
|
1340
1396
|
break;
|
|
1341
1397
|
case "DELETE_OPERATION_ERROR":
|
|
1342
|
-
|
|
1398
|
+
N().parse(e.input), c.deleteOperationErrorOperation(
|
|
1399
|
+
t.global,
|
|
1400
|
+
e
|
|
1401
|
+
);
|
|
1343
1402
|
break;
|
|
1344
1403
|
case "REORDER_OPERATION_ERRORS":
|
|
1345
|
-
|
|
1346
|
-
t,
|
|
1404
|
+
v().parse(e.input), c.reorderOperationErrorsOperation(
|
|
1405
|
+
t.global,
|
|
1347
1406
|
e
|
|
1348
1407
|
);
|
|
1349
1408
|
break;
|
|
1350
1409
|
case "ADD_OPERATION_EXAMPLE":
|
|
1351
|
-
T().parse(e.input), S.addOperationExampleOperation(
|
|
1410
|
+
T().parse(e.input), S.addOperationExampleOperation(
|
|
1411
|
+
t.global,
|
|
1412
|
+
e
|
|
1413
|
+
);
|
|
1352
1414
|
break;
|
|
1353
1415
|
case "UPDATE_OPERATION_EXAMPLE":
|
|
1354
|
-
|
|
1355
|
-
t,
|
|
1416
|
+
se().parse(e.input), S.updateOperationExampleOperation(
|
|
1417
|
+
t.global,
|
|
1356
1418
|
e
|
|
1357
1419
|
);
|
|
1358
1420
|
break;
|
|
1359
1421
|
case "DELETE_OPERATION_EXAMPLE":
|
|
1360
|
-
|
|
1361
|
-
t,
|
|
1422
|
+
L().parse(e.input), S.deleteOperationExampleOperation(
|
|
1423
|
+
t.global,
|
|
1362
1424
|
e
|
|
1363
1425
|
);
|
|
1364
1426
|
break;
|
|
1365
1427
|
case "REORDER_OPERATION_EXAMPLES":
|
|
1366
1428
|
U().parse(e.input), S.reorderOperationExamplesOperation(
|
|
1367
|
-
t,
|
|
1429
|
+
t.global,
|
|
1368
1430
|
e
|
|
1369
1431
|
);
|
|
1370
1432
|
break;
|
|
1371
1433
|
case "ADD_OPERATION":
|
|
1372
|
-
|
|
1434
|
+
R().parse(e.input), p.addOperationOperation(t.global, e);
|
|
1373
1435
|
break;
|
|
1374
1436
|
case "SET_OPERATION_NAME":
|
|
1375
|
-
|
|
1437
|
+
ee().parse(e.input), p.setOperationNameOperation(t.global, e);
|
|
1376
1438
|
break;
|
|
1377
1439
|
case "SET_OPERATION_SCOPE":
|
|
1378
|
-
|
|
1440
|
+
ge().parse(e.input), p.setOperationScopeOperation(t.global, e);
|
|
1379
1441
|
break;
|
|
1380
1442
|
case "SET_OPERATION_SCHEMA":
|
|
1381
|
-
|
|
1443
|
+
re().parse(e.input), p.setOperationSchemaOperation(t.global, e);
|
|
1382
1444
|
break;
|
|
1383
1445
|
case "SET_OPERATION_DESCRIPTION":
|
|
1384
|
-
|
|
1446
|
+
J().parse(e.input), p.setOperationDescriptionOperation(
|
|
1447
|
+
t.global,
|
|
1448
|
+
e
|
|
1449
|
+
);
|
|
1385
1450
|
break;
|
|
1386
1451
|
case "SET_OPERATION_TEMPLATE":
|
|
1387
|
-
|
|
1452
|
+
oe().parse(e.input), p.setOperationTemplateOperation(
|
|
1453
|
+
t.global,
|
|
1454
|
+
e
|
|
1455
|
+
);
|
|
1388
1456
|
break;
|
|
1389
1457
|
case "SET_OPERATION_REDUCER":
|
|
1390
|
-
|
|
1458
|
+
te().parse(e.input), p.setOperationReducerOperation(t.global, e);
|
|
1391
1459
|
break;
|
|
1392
1460
|
case "MOVE_OPERATION":
|
|
1393
|
-
|
|
1461
|
+
C().parse(e.input), p.moveOperationOperation(t.global, e);
|
|
1394
1462
|
break;
|
|
1395
1463
|
case "DELETE_OPERATION":
|
|
1396
|
-
|
|
1464
|
+
P().parse(e.input), p.deleteOperationOperation(t.global, e);
|
|
1397
1465
|
break;
|
|
1398
1466
|
case "REORDER_MODULE_OPERATIONS":
|
|
1399
|
-
|
|
1467
|
+
y().parse(e.input), p.reorderModuleOperationsOperation(
|
|
1468
|
+
t.global,
|
|
1469
|
+
e
|
|
1470
|
+
);
|
|
1400
1471
|
break;
|
|
1401
1472
|
case "SET_STATE_SCHEMA":
|
|
1402
|
-
|
|
1473
|
+
ne().parse(e.input), u.setStateSchemaOperation(t.global, e);
|
|
1403
1474
|
break;
|
|
1404
1475
|
case "SET_INITIAL_STATE":
|
|
1405
|
-
|
|
1476
|
+
X().parse(e.input), u.setInitialStateOperation(t.global, e);
|
|
1406
1477
|
break;
|
|
1407
1478
|
case "ADD_STATE_EXAMPLE":
|
|
1408
|
-
|
|
1479
|
+
A().parse(e.input), u.addStateExampleOperation(t.global, e);
|
|
1409
1480
|
break;
|
|
1410
1481
|
case "UPDATE_STATE_EXAMPLE":
|
|
1411
|
-
|
|
1482
|
+
ae().parse(e.input), u.updateStateExampleOperation(t.global, e);
|
|
1412
1483
|
break;
|
|
1413
1484
|
case "DELETE_STATE_EXAMPLE":
|
|
1414
|
-
|
|
1485
|
+
j().parse(e.input), u.deleteStateExampleOperation(t.global, e);
|
|
1415
1486
|
break;
|
|
1416
1487
|
case "REORDER_STATE_EXAMPLES":
|
|
1417
|
-
|
|
1488
|
+
V().parse(e.input), u.reorderStateExamplesOperation(t.global, e);
|
|
1418
1489
|
break;
|
|
1419
1490
|
default:
|
|
1420
1491
|
return t;
|
|
1421
1492
|
}
|
|
1422
|
-
}, g =
|
|
1423
|
-
jt
|
|
1424
|
-
), Ct = {
|
|
1493
|
+
}, g = mt(Ct), kt = {
|
|
1425
1494
|
id: "",
|
|
1426
1495
|
name: "",
|
|
1427
1496
|
extension: "",
|
|
@@ -1435,43 +1504,53 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1435
1504
|
version: 1,
|
|
1436
1505
|
changeLog: [],
|
|
1437
1506
|
state: {
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1507
|
+
global: {
|
|
1508
|
+
schema: "",
|
|
1509
|
+
initialValue: "",
|
|
1510
|
+
examples: []
|
|
1511
|
+
},
|
|
1512
|
+
local: {
|
|
1513
|
+
schema: "",
|
|
1514
|
+
initialValue: "",
|
|
1515
|
+
examples: []
|
|
1516
|
+
}
|
|
1441
1517
|
},
|
|
1442
1518
|
modules: []
|
|
1443
1519
|
}
|
|
1444
1520
|
]
|
|
1445
|
-
}, O = {
|
|
1521
|
+
}, yt = {}, O = {
|
|
1446
1522
|
fileExtension: "phdm",
|
|
1447
1523
|
createState(t) {
|
|
1448
|
-
return {
|
|
1524
|
+
return {
|
|
1525
|
+
global: { ...kt, ...t == null ? void 0 : t.global },
|
|
1526
|
+
local: { ...yt, ...t == null ? void 0 : t.local }
|
|
1527
|
+
};
|
|
1449
1528
|
},
|
|
1450
1529
|
createExtendedState(t) {
|
|
1451
|
-
return
|
|
1530
|
+
return ht(
|
|
1452
1531
|
{ ...t, documentType: "powerhouse/document-model" },
|
|
1453
1532
|
O.createState
|
|
1454
1533
|
);
|
|
1455
1534
|
},
|
|
1456
1535
|
createDocument(t) {
|
|
1457
|
-
return
|
|
1536
|
+
return Ot(
|
|
1458
1537
|
O.createExtendedState(t),
|
|
1459
1538
|
O.createState
|
|
1460
1539
|
);
|
|
1461
1540
|
},
|
|
1462
|
-
saveToFile(t, e,
|
|
1463
|
-
return
|
|
1541
|
+
saveToFile(t, e, o) {
|
|
1542
|
+
return gt(t, e, "phdm", o);
|
|
1464
1543
|
},
|
|
1465
1544
|
saveToFileHandle(t, e) {
|
|
1466
|
-
return
|
|
1545
|
+
return St(t, e);
|
|
1467
1546
|
},
|
|
1468
1547
|
loadFromFile(t) {
|
|
1469
|
-
return
|
|
1548
|
+
return bt(t, g);
|
|
1470
1549
|
},
|
|
1471
1550
|
loadFromInput(t) {
|
|
1472
1551
|
return ft(t, g);
|
|
1473
1552
|
}
|
|
1474
|
-
},
|
|
1553
|
+
}, be = (t) => s(
|
|
1475
1554
|
"SET_MODEL_NAME",
|
|
1476
1555
|
{ ...t }
|
|
1477
1556
|
), fe = (t) => s(
|
|
@@ -1486,13 +1565,13 @@ const Dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1486
1565
|
), Te = (t) => s(
|
|
1487
1566
|
"SET_AUTHOR_NAME",
|
|
1488
1567
|
{ ...t }
|
|
1489
|
-
),
|
|
1568
|
+
), Re = (t) => s(
|
|
1490
1569
|
"SET_AUTHOR_WEBSITE",
|
|
1491
1570
|
{ ...t }
|
|
1492
1571
|
);
|
|
1493
|
-
class
|
|
1572
|
+
class wt extends l {
|
|
1494
1573
|
setModelName(e) {
|
|
1495
|
-
return this.dispatch(
|
|
1574
|
+
return this.dispatch(be(e));
|
|
1496
1575
|
}
|
|
1497
1576
|
setModelId(e) {
|
|
1498
1577
|
return this.dispatch(fe(e));
|
|
@@ -1507,85 +1586,85 @@ class kt extends l {
|
|
|
1507
1586
|
return this.dispatch(Te(e));
|
|
1508
1587
|
}
|
|
1509
1588
|
setAuthorWebsite(e) {
|
|
1510
|
-
return this.dispatch(
|
|
1589
|
+
return this.dispatch(Re(e));
|
|
1511
1590
|
}
|
|
1512
1591
|
}
|
|
1513
|
-
const
|
|
1592
|
+
const Ae = (t) => s(
|
|
1514
1593
|
"ADD_CHANGE_LOG_ITEM",
|
|
1515
1594
|
{ ...t }
|
|
1516
|
-
),
|
|
1595
|
+
), xe = (t) => s(
|
|
1517
1596
|
"UPDATE_CHANGE_LOG_ITEM",
|
|
1518
1597
|
{ ...t }
|
|
1519
1598
|
), De = (t) => s(
|
|
1520
1599
|
"DELETE_CHANGE_LOG_ITEM",
|
|
1521
1600
|
{ ...t }
|
|
1522
|
-
),
|
|
1601
|
+
), Me = (t) => s(
|
|
1523
1602
|
"REORDER_CHANGE_LOG_ITEMS",
|
|
1524
1603
|
{ ...t }
|
|
1525
|
-
),
|
|
1526
|
-
class
|
|
1604
|
+
), Ne = () => s("RELEASE_NEW_VERSION");
|
|
1605
|
+
class vt extends l {
|
|
1527
1606
|
addChangeLogItem(e) {
|
|
1528
|
-
return this.dispatch(
|
|
1607
|
+
return this.dispatch(Ae(e));
|
|
1529
1608
|
}
|
|
1530
1609
|
updateChangeLogItem(e) {
|
|
1531
|
-
return this.dispatch(
|
|
1610
|
+
return this.dispatch(xe(e));
|
|
1532
1611
|
}
|
|
1533
1612
|
deleteChangeLogItem(e) {
|
|
1534
1613
|
return this.dispatch(De(e));
|
|
1535
1614
|
}
|
|
1536
1615
|
reorderChangeLogItems(e) {
|
|
1537
|
-
return this.dispatch(
|
|
1616
|
+
return this.dispatch(Me(e));
|
|
1538
1617
|
}
|
|
1539
1618
|
releaseNewVersion() {
|
|
1540
|
-
return this.dispatch(
|
|
1619
|
+
return this.dispatch(Ne());
|
|
1541
1620
|
}
|
|
1542
1621
|
}
|
|
1543
|
-
const
|
|
1622
|
+
const Le = (t) => s(
|
|
1544
1623
|
"ADD_MODULE",
|
|
1545
1624
|
{ ...t }
|
|
1546
|
-
),
|
|
1625
|
+
), Pe = (t) => s(
|
|
1547
1626
|
"SET_MODULE_NAME",
|
|
1548
1627
|
{ ...t }
|
|
1549
|
-
),
|
|
1628
|
+
), je = (t) => s(
|
|
1550
1629
|
"SET_MODULE_DESCRIPTION",
|
|
1551
1630
|
{ ...t }
|
|
1552
|
-
),
|
|
1631
|
+
), Ce = (t) => s(
|
|
1553
1632
|
"DELETE_MODULE",
|
|
1554
1633
|
{ ...t }
|
|
1555
|
-
),
|
|
1634
|
+
), ke = (t) => s(
|
|
1556
1635
|
"REORDER_MODULES",
|
|
1557
1636
|
{ ...t }
|
|
1558
1637
|
);
|
|
1559
|
-
class
|
|
1638
|
+
class Ut extends l {
|
|
1560
1639
|
addModule(e) {
|
|
1561
|
-
return this.dispatch(
|
|
1640
|
+
return this.dispatch(Le(e));
|
|
1562
1641
|
}
|
|
1563
1642
|
setModuleName(e) {
|
|
1564
|
-
return this.dispatch(
|
|
1643
|
+
return this.dispatch(Pe(e));
|
|
1565
1644
|
}
|
|
1566
1645
|
setModuleDescription(e) {
|
|
1567
|
-
return this.dispatch(
|
|
1646
|
+
return this.dispatch(je(e));
|
|
1568
1647
|
}
|
|
1569
1648
|
deleteModule(e) {
|
|
1570
|
-
return this.dispatch(
|
|
1649
|
+
return this.dispatch(Ce(e));
|
|
1571
1650
|
}
|
|
1572
1651
|
reorderModules(e) {
|
|
1573
|
-
return this.dispatch(
|
|
1652
|
+
return this.dispatch(ke(e));
|
|
1574
1653
|
}
|
|
1575
1654
|
}
|
|
1576
|
-
const
|
|
1655
|
+
const ye = (t) => s(
|
|
1577
1656
|
"ADD_OPERATION_ERROR",
|
|
1578
1657
|
{ ...t }
|
|
1579
|
-
),
|
|
1658
|
+
), we = (t) => s(
|
|
1580
1659
|
"SET_OPERATION_ERROR_CODE",
|
|
1581
1660
|
{ ...t }
|
|
1582
|
-
),
|
|
1661
|
+
), ve = (t) => s(
|
|
1583
1662
|
"SET_OPERATION_ERROR_NAME",
|
|
1584
1663
|
{ ...t }
|
|
1585
1664
|
), Ue = (t) => s(
|
|
1586
1665
|
"SET_OPERATION_ERROR_DESCRIPTION",
|
|
1587
1666
|
{ ...t }
|
|
1588
|
-
),
|
|
1667
|
+
), Ve = (t) => s(
|
|
1589
1668
|
"SET_OPERATION_ERROR_TEMPLATE",
|
|
1590
1669
|
{ ...t }
|
|
1591
1670
|
), Fe = (t) => s(
|
|
@@ -1595,21 +1674,21 @@ const ke = (t) => s(
|
|
|
1595
1674
|
"REORDER_OPERATION_ERRORS",
|
|
1596
1675
|
{ ...t }
|
|
1597
1676
|
);
|
|
1598
|
-
class
|
|
1677
|
+
class Vt extends l {
|
|
1599
1678
|
addOperationError(e) {
|
|
1600
|
-
return this.dispatch(
|
|
1679
|
+
return this.dispatch(ye(e));
|
|
1601
1680
|
}
|
|
1602
1681
|
setOperationErrorCode(e) {
|
|
1603
|
-
return this.dispatch(
|
|
1682
|
+
return this.dispatch(we(e));
|
|
1604
1683
|
}
|
|
1605
1684
|
setOperationErrorName(e) {
|
|
1606
|
-
return this.dispatch(
|
|
1685
|
+
return this.dispatch(ve(e));
|
|
1607
1686
|
}
|
|
1608
1687
|
setOperationErrorDescription(e) {
|
|
1609
1688
|
return this.dispatch(Ue(e));
|
|
1610
1689
|
}
|
|
1611
1690
|
setOperationErrorTemplate(e) {
|
|
1612
|
-
return this.dispatch(
|
|
1691
|
+
return this.dispatch(Ve(e));
|
|
1613
1692
|
}
|
|
1614
1693
|
deleteOperationError(e) {
|
|
1615
1694
|
return this.dispatch(Fe(e));
|
|
@@ -1618,230 +1697,230 @@ class Ut extends l {
|
|
|
1618
1697
|
return this.dispatch(He(e));
|
|
1619
1698
|
}
|
|
1620
1699
|
}
|
|
1621
|
-
const
|
|
1700
|
+
const Xe = (t) => s(
|
|
1622
1701
|
"ADD_OPERATION_EXAMPLE",
|
|
1623
1702
|
{ ...t }
|
|
1624
|
-
),
|
|
1703
|
+
), Ge = (t) => s(
|
|
1625
1704
|
"UPDATE_OPERATION_EXAMPLE",
|
|
1626
1705
|
{ ...t }
|
|
1627
|
-
),
|
|
1706
|
+
), $e = (t) => s(
|
|
1628
1707
|
"DELETE_OPERATION_EXAMPLE",
|
|
1629
1708
|
{ ...t }
|
|
1630
1709
|
), We = (t) => s(
|
|
1631
1710
|
"REORDER_OPERATION_EXAMPLES",
|
|
1632
1711
|
{ ...t }
|
|
1633
1712
|
);
|
|
1634
|
-
class
|
|
1713
|
+
class Ft extends l {
|
|
1635
1714
|
addOperationExample(e) {
|
|
1636
|
-
return this.dispatch(
|
|
1715
|
+
return this.dispatch(Xe(e));
|
|
1637
1716
|
}
|
|
1638
1717
|
updateOperationExample(e) {
|
|
1639
|
-
return this.dispatch(
|
|
1718
|
+
return this.dispatch(Ge(e));
|
|
1640
1719
|
}
|
|
1641
1720
|
deleteOperationExample(e) {
|
|
1642
|
-
return this.dispatch(
|
|
1721
|
+
return this.dispatch($e(e));
|
|
1643
1722
|
}
|
|
1644
1723
|
reorderOperationExamples(e) {
|
|
1645
1724
|
return this.dispatch(We(e));
|
|
1646
1725
|
}
|
|
1647
1726
|
}
|
|
1648
|
-
const
|
|
1727
|
+
const ze = (t) => s(
|
|
1649
1728
|
"ADD_OPERATION",
|
|
1650
1729
|
{ ...t }
|
|
1651
|
-
),
|
|
1730
|
+
), Be = (t) => s(
|
|
1652
1731
|
"SET_OPERATION_NAME",
|
|
1653
1732
|
{ ...t }
|
|
1654
|
-
),
|
|
1733
|
+
), qe = (t) => s(
|
|
1655
1734
|
"SET_OPERATION_SCOPE",
|
|
1656
1735
|
{ ...t }
|
|
1657
|
-
),
|
|
1736
|
+
), Je = (t) => s(
|
|
1658
1737
|
"SET_OPERATION_SCHEMA",
|
|
1659
1738
|
{ ...t }
|
|
1660
|
-
),
|
|
1739
|
+
), Ke = (t) => s(
|
|
1661
1740
|
"SET_OPERATION_DESCRIPTION",
|
|
1662
1741
|
{ ...t }
|
|
1663
|
-
),
|
|
1742
|
+
), Qe = (t) => s(
|
|
1664
1743
|
"SET_OPERATION_TEMPLATE",
|
|
1665
1744
|
{ ...t }
|
|
1666
|
-
),
|
|
1745
|
+
), Ye = (t) => s(
|
|
1667
1746
|
"SET_OPERATION_REDUCER",
|
|
1668
1747
|
{ ...t }
|
|
1669
|
-
),
|
|
1748
|
+
), Ze = (t) => s(
|
|
1670
1749
|
"MOVE_OPERATION",
|
|
1671
1750
|
{ ...t }
|
|
1672
|
-
),
|
|
1751
|
+
), et = (t) => s(
|
|
1673
1752
|
"DELETE_OPERATION",
|
|
1674
1753
|
{ ...t }
|
|
1675
|
-
),
|
|
1754
|
+
), tt = (t) => s(
|
|
1676
1755
|
"REORDER_MODULE_OPERATIONS",
|
|
1677
1756
|
{ ...t }
|
|
1678
1757
|
);
|
|
1679
|
-
class
|
|
1758
|
+
class Ht extends l {
|
|
1680
1759
|
addOperation(e) {
|
|
1681
|
-
return this.dispatch(
|
|
1760
|
+
return this.dispatch(ze(e));
|
|
1682
1761
|
}
|
|
1683
1762
|
setOperationName(e) {
|
|
1684
|
-
return this.dispatch(
|
|
1763
|
+
return this.dispatch(Be(e));
|
|
1685
1764
|
}
|
|
1686
1765
|
setOperationScope(e) {
|
|
1687
|
-
return this.dispatch(
|
|
1766
|
+
return this.dispatch(qe(e));
|
|
1688
1767
|
}
|
|
1689
1768
|
setOperationSchema(e) {
|
|
1690
|
-
return this.dispatch(
|
|
1769
|
+
return this.dispatch(Je(e));
|
|
1691
1770
|
}
|
|
1692
1771
|
setOperationDescription(e) {
|
|
1693
|
-
return this.dispatch(
|
|
1772
|
+
return this.dispatch(Ke(e));
|
|
1694
1773
|
}
|
|
1695
1774
|
setOperationTemplate(e) {
|
|
1696
|
-
return this.dispatch(
|
|
1775
|
+
return this.dispatch(Qe(e));
|
|
1697
1776
|
}
|
|
1698
1777
|
setOperationReducer(e) {
|
|
1699
|
-
return this.dispatch(
|
|
1778
|
+
return this.dispatch(Ye(e));
|
|
1700
1779
|
}
|
|
1701
1780
|
moveOperation(e) {
|
|
1702
|
-
return this.dispatch(
|
|
1781
|
+
return this.dispatch(Ze(e));
|
|
1703
1782
|
}
|
|
1704
1783
|
deleteOperation(e) {
|
|
1705
|
-
return this.dispatch(
|
|
1784
|
+
return this.dispatch(et(e));
|
|
1706
1785
|
}
|
|
1707
1786
|
reorderModuleOperations(e) {
|
|
1708
|
-
return this.dispatch(
|
|
1787
|
+
return this.dispatch(tt(e));
|
|
1709
1788
|
}
|
|
1710
1789
|
}
|
|
1711
|
-
const
|
|
1790
|
+
const rt = (t) => s(
|
|
1712
1791
|
"SET_STATE_SCHEMA",
|
|
1713
1792
|
{ ...t }
|
|
1714
|
-
),
|
|
1793
|
+
), ot = (t) => s(
|
|
1715
1794
|
"SET_INITIAL_STATE",
|
|
1716
1795
|
{ ...t }
|
|
1717
|
-
),
|
|
1796
|
+
), nt = (t) => s(
|
|
1718
1797
|
"ADD_STATE_EXAMPLE",
|
|
1719
1798
|
{ ...t }
|
|
1720
|
-
),
|
|
1799
|
+
), it = (t) => s(
|
|
1721
1800
|
"UPDATE_STATE_EXAMPLE",
|
|
1722
1801
|
{ ...t }
|
|
1723
|
-
),
|
|
1802
|
+
), st = (t) => s(
|
|
1724
1803
|
"DELETE_STATE_EXAMPLE",
|
|
1725
1804
|
{ ...t }
|
|
1726
|
-
),
|
|
1805
|
+
), at = (t) => s(
|
|
1727
1806
|
"REORDER_STATE_EXAMPLES",
|
|
1728
1807
|
{ ...t }
|
|
1729
1808
|
);
|
|
1730
|
-
class
|
|
1809
|
+
class Xt extends l {
|
|
1731
1810
|
setStateSchema(e) {
|
|
1732
|
-
return this.dispatch(
|
|
1811
|
+
return this.dispatch(rt(e));
|
|
1733
1812
|
}
|
|
1734
1813
|
setInitialState(e) {
|
|
1735
|
-
return this.dispatch(
|
|
1814
|
+
return this.dispatch(ot(e));
|
|
1736
1815
|
}
|
|
1737
1816
|
addStateExample(e) {
|
|
1738
|
-
return this.dispatch(
|
|
1817
|
+
return this.dispatch(nt(e));
|
|
1739
1818
|
}
|
|
1740
1819
|
updateStateExample(e) {
|
|
1741
|
-
return this.dispatch(
|
|
1820
|
+
return this.dispatch(it(e));
|
|
1742
1821
|
}
|
|
1743
1822
|
deleteStateExample(e) {
|
|
1744
|
-
return this.dispatch(
|
|
1823
|
+
return this.dispatch(st(e));
|
|
1745
1824
|
}
|
|
1746
1825
|
reorderStateExamples(e) {
|
|
1747
|
-
return this.dispatch(
|
|
1826
|
+
return this.dispatch(at(e));
|
|
1748
1827
|
}
|
|
1749
1828
|
}
|
|
1750
1829
|
var m;
|
|
1751
|
-
let
|
|
1752
|
-
constructor(e,
|
|
1753
|
-
super(g, O.createDocument(e),
|
|
1830
|
+
let pe = (m = class extends l {
|
|
1831
|
+
constructor(e, o) {
|
|
1832
|
+
super(g, O.createDocument(e), o);
|
|
1754
1833
|
}
|
|
1755
|
-
saveToFile(e,
|
|
1756
|
-
return super.saveToFile(e, m.fileExtension,
|
|
1834
|
+
saveToFile(e, o) {
|
|
1835
|
+
return super.saveToFile(e, m.fileExtension, o);
|
|
1757
1836
|
}
|
|
1758
1837
|
loadFromFile(e) {
|
|
1759
1838
|
return super.loadFromFile(e);
|
|
1760
1839
|
}
|
|
1761
1840
|
static async fromFile(e) {
|
|
1762
|
-
const
|
|
1763
|
-
return await
|
|
1841
|
+
const o = new this();
|
|
1842
|
+
return await o.loadFromFile(e), o;
|
|
1764
1843
|
}
|
|
1765
|
-
},
|
|
1766
|
-
_t(
|
|
1767
|
-
kt,
|
|
1768
|
-
yt,
|
|
1844
|
+
}, le(m, "fileExtension", "phdm"), m);
|
|
1845
|
+
_t(pe, [
|
|
1769
1846
|
wt,
|
|
1770
|
-
Ut,
|
|
1771
1847
|
vt,
|
|
1848
|
+
Ut,
|
|
1849
|
+
Vt,
|
|
1772
1850
|
Ft,
|
|
1773
|
-
Ht
|
|
1851
|
+
Ht,
|
|
1852
|
+
Xt
|
|
1774
1853
|
]);
|
|
1775
|
-
const
|
|
1854
|
+
const Gt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1776
1855
|
__proto__: null,
|
|
1777
|
-
addChangeLogItem:
|
|
1778
|
-
addModule:
|
|
1779
|
-
addOperation:
|
|
1780
|
-
addOperationError:
|
|
1781
|
-
addOperationExample:
|
|
1782
|
-
addStateExample:
|
|
1856
|
+
addChangeLogItem: Ae,
|
|
1857
|
+
addModule: Le,
|
|
1858
|
+
addOperation: ze,
|
|
1859
|
+
addOperationError: ye,
|
|
1860
|
+
addOperationExample: Xe,
|
|
1861
|
+
addStateExample: nt,
|
|
1783
1862
|
deleteChangeLogItem: De,
|
|
1784
|
-
deleteModule:
|
|
1785
|
-
deleteOperation:
|
|
1863
|
+
deleteModule: Ce,
|
|
1864
|
+
deleteOperation: et,
|
|
1786
1865
|
deleteOperationError: Fe,
|
|
1787
|
-
deleteOperationExample:
|
|
1788
|
-
deleteStateExample:
|
|
1789
|
-
moveOperation:
|
|
1790
|
-
releaseNewVersion:
|
|
1791
|
-
reorderChangeLogItems:
|
|
1792
|
-
reorderModuleOperations:
|
|
1793
|
-
reorderModules:
|
|
1866
|
+
deleteOperationExample: $e,
|
|
1867
|
+
deleteStateExample: st,
|
|
1868
|
+
moveOperation: Ze,
|
|
1869
|
+
releaseNewVersion: Ne,
|
|
1870
|
+
reorderChangeLogItems: Me,
|
|
1871
|
+
reorderModuleOperations: tt,
|
|
1872
|
+
reorderModules: ke,
|
|
1794
1873
|
reorderOperationErrors: He,
|
|
1795
1874
|
reorderOperationExamples: We,
|
|
1796
|
-
reorderStateExamples:
|
|
1875
|
+
reorderStateExamples: at,
|
|
1797
1876
|
setAuthorName: Te,
|
|
1798
|
-
setAuthorWebsite:
|
|
1799
|
-
setInitialState:
|
|
1877
|
+
setAuthorWebsite: Re,
|
|
1878
|
+
setInitialState: ot,
|
|
1800
1879
|
setModelDescription: Ie,
|
|
1801
1880
|
setModelExtension: _e,
|
|
1802
1881
|
setModelId: fe,
|
|
1803
|
-
setModelName:
|
|
1804
|
-
setModuleDescription:
|
|
1805
|
-
setModuleName:
|
|
1806
|
-
setOperationDescription:
|
|
1807
|
-
setOperationErrorCode:
|
|
1882
|
+
setModelName: be,
|
|
1883
|
+
setModuleDescription: je,
|
|
1884
|
+
setModuleName: Pe,
|
|
1885
|
+
setOperationDescription: Ke,
|
|
1886
|
+
setOperationErrorCode: we,
|
|
1808
1887
|
setOperationErrorDescription: Ue,
|
|
1809
|
-
setOperationErrorName:
|
|
1810
|
-
setOperationErrorTemplate:
|
|
1811
|
-
setOperationName:
|
|
1812
|
-
setOperationReducer:
|
|
1813
|
-
setOperationSchema:
|
|
1814
|
-
setOperationScope:
|
|
1815
|
-
setOperationTemplate:
|
|
1816
|
-
setStateSchema:
|
|
1817
|
-
updateChangeLogItem:
|
|
1818
|
-
updateOperationExample:
|
|
1819
|
-
updateStateExample:
|
|
1820
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1821
|
-
Document:
|
|
1888
|
+
setOperationErrorName: ve,
|
|
1889
|
+
setOperationErrorTemplate: Ve,
|
|
1890
|
+
setOperationName: Be,
|
|
1891
|
+
setOperationReducer: Ye,
|
|
1892
|
+
setOperationSchema: Je,
|
|
1893
|
+
setOperationScope: qe,
|
|
1894
|
+
setOperationTemplate: Qe,
|
|
1895
|
+
setStateSchema: rt,
|
|
1896
|
+
updateChangeLogItem: xe,
|
|
1897
|
+
updateOperationExample: Ge,
|
|
1898
|
+
updateStateExample: it
|
|
1899
|
+
}, Symbol.toStringTag, { value: "Module" })), pt = pe, lt = { ...O, ...Tt }, ct = { ...It, ...Gt }, $t = {
|
|
1900
|
+
Document: pt,
|
|
1822
1901
|
reducer: g,
|
|
1823
|
-
actions:
|
|
1824
|
-
utils:
|
|
1825
|
-
documentModel:
|
|
1826
|
-
},
|
|
1902
|
+
actions: ct,
|
|
1903
|
+
utils: lt,
|
|
1904
|
+
documentModel: ce
|
|
1905
|
+
}, tr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1827
1906
|
__proto__: null,
|
|
1828
|
-
Document:
|
|
1829
|
-
DocumentModel:
|
|
1830
|
-
actions:
|
|
1831
|
-
documentModel:
|
|
1832
|
-
module:
|
|
1907
|
+
Document: pt,
|
|
1908
|
+
DocumentModel: pe,
|
|
1909
|
+
actions: ct,
|
|
1910
|
+
documentModel: ce,
|
|
1911
|
+
module: $t,
|
|
1833
1912
|
reducer: g,
|
|
1834
|
-
utils:
|
|
1913
|
+
utils: lt,
|
|
1835
1914
|
z: Dt
|
|
1836
1915
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
1837
1916
|
export {
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1917
|
+
tr as D,
|
|
1918
|
+
pe as a,
|
|
1919
|
+
pt as b,
|
|
1920
|
+
ct as c,
|
|
1921
|
+
ce as d,
|
|
1922
|
+
$t as m,
|
|
1844
1923
|
g as r,
|
|
1845
|
-
|
|
1924
|
+
lt as u,
|
|
1846
1925
|
Dt as z
|
|
1847
1926
|
};
|