@wibetter/json-utils 5.3.1 → 6.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +0 -1349
- package/dist/index.esm.min.js +917 -1728
- package/dist/index.js +370 -1202
- package/dist/index.js.LICENSE.txt +2 -2
- package/package.json +1 -1
package/dist/index.esm.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { cloneDeep as e, isEqual as t, truncate as r } from 'lodash';
|
|
2
2
|
import n from 'qs';
|
|
3
|
-
var
|
|
4
|
-
|
|
3
|
+
var o,
|
|
4
|
+
i = {
|
|
5
5
|
type: 'event',
|
|
6
6
|
title: '事件',
|
|
7
7
|
isContainer: !1,
|
|
@@ -64,10 +64,10 @@ var i,
|
|
|
64
64
|
propertyOrder: ['type', 'data', 'filter'],
|
|
65
65
|
},
|
|
66
66
|
s =
|
|
67
|
-
(((
|
|
68
|
-
(
|
|
69
|
-
(
|
|
70
|
-
(
|
|
67
|
+
(((o = { type: 'object' }).type = 'datasource'),
|
|
68
|
+
(o.title = '数据源'),
|
|
69
|
+
(o.isContainer = !1),
|
|
70
|
+
(o.properties = {
|
|
71
71
|
type: {
|
|
72
72
|
type: 'select',
|
|
73
73
|
default: 'remote',
|
|
@@ -93,15 +93,15 @@ var i,
|
|
|
93
93
|
isRequired: !0,
|
|
94
94
|
},
|
|
95
95
|
}),
|
|
96
|
-
(
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
(o.propertyOrder = ['type', 'data', 'filter']),
|
|
97
|
+
o),
|
|
98
|
+
u = {
|
|
99
99
|
type: 'local',
|
|
100
100
|
config: { dataName: '', body: {}, filter: 'return data;' },
|
|
101
101
|
data: '{}',
|
|
102
102
|
localFilter: 'return data;',
|
|
103
103
|
},
|
|
104
|
-
|
|
104
|
+
c = {
|
|
105
105
|
jsonschema: {
|
|
106
106
|
type: 'object',
|
|
107
107
|
title: 'jsonSchemaObject',
|
|
@@ -510,813 +510,7 @@ var i,
|
|
|
510
510
|
propertyOrder: ['type', 'config', 'data', 'localFilter'],
|
|
511
511
|
},
|
|
512
512
|
datasource: a,
|
|
513
|
-
event:
|
|
514
|
-
'dynamic-config': {
|
|
515
|
-
type: 'dynamic-config',
|
|
516
|
-
title: '动态配置',
|
|
517
|
-
description: '',
|
|
518
|
-
isContainer: !1,
|
|
519
|
-
properties: {
|
|
520
|
-
type: {
|
|
521
|
-
type: 'select',
|
|
522
|
-
title: '数据来源',
|
|
523
|
-
options: [
|
|
524
|
-
{ label: '模板直接设置', value: 'DevDefaults' },
|
|
525
|
-
{ label: 'mp后台配置', value: 'ContentStaticConfig' },
|
|
526
|
-
{ label: '内容Meta数据', value: 'Content' },
|
|
527
|
-
{ label: '全局配置数据', value: 'RuntimeConst' },
|
|
528
|
-
{ label: '资源中心配置', value: 'ResourceCenter' },
|
|
529
|
-
],
|
|
530
|
-
default: 'DevDefaults',
|
|
531
|
-
isConditionProp: !0,
|
|
532
|
-
description:
|
|
533
|
-
'目前支持的数据来源包括: 1)模版直接设置:在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置:选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据:支持内容meta数据的获取,页面meta数据。 4)全局配置数据:目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
|
|
534
|
-
},
|
|
535
|
-
value: {
|
|
536
|
-
title: '数据值',
|
|
537
|
-
type: 'input',
|
|
538
|
-
default: '',
|
|
539
|
-
description: '',
|
|
540
|
-
placeholder: '',
|
|
541
|
-
onShow:
|
|
542
|
-
'type === "DevDefaults" || type === "Content" || type === "RuntimeConst"',
|
|
543
|
-
},
|
|
544
|
-
description: {
|
|
545
|
-
title: '属性名称',
|
|
546
|
-
type: 'input',
|
|
547
|
-
default: '',
|
|
548
|
-
description: '',
|
|
549
|
-
placeholder: '',
|
|
550
|
-
onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
|
|
551
|
-
},
|
|
552
|
-
valueType: {
|
|
553
|
-
type: 'radio',
|
|
554
|
-
title: '配置方式',
|
|
555
|
-
options: [
|
|
556
|
-
{ label: '填写', value: 'string' },
|
|
557
|
-
{ label: '选择', value: 'select' },
|
|
558
|
-
],
|
|
559
|
-
default: 'string',
|
|
560
|
-
isConditionProp: !0,
|
|
561
|
-
description: '在MP后台或资源中心配置时的交互方式,推荐使用"选择"',
|
|
562
|
-
onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
|
|
563
|
-
},
|
|
564
|
-
range: {
|
|
565
|
-
type: 'select',
|
|
566
|
-
title: '可选项',
|
|
567
|
-
multiple: !0,
|
|
568
|
-
options: [],
|
|
569
|
-
onShow:
|
|
570
|
-
'(type === "ContentStaticConfig" || type === "ResourceCenter") && valueType === "select"',
|
|
571
|
-
description: '这里会使用value中的配置选项作为options',
|
|
572
|
-
},
|
|
573
|
-
},
|
|
574
|
-
propertyOrder: ['type', 'value', 'description', 'valueType', 'range'],
|
|
575
|
-
showCodeViewBtn: !1,
|
|
576
|
-
},
|
|
577
|
-
'dynamic-object': {
|
|
578
|
-
type: 'dynamic-object',
|
|
579
|
-
title: '动态配置',
|
|
580
|
-
description: '',
|
|
581
|
-
isContainer: !1,
|
|
582
|
-
properties: {
|
|
583
|
-
type: {
|
|
584
|
-
type: 'select',
|
|
585
|
-
title: '数据来源',
|
|
586
|
-
options: [
|
|
587
|
-
{ label: '模板直接设置', value: 'DevDefaults' },
|
|
588
|
-
{ label: 'mp后台配置', value: 'ContentStaticConfig' },
|
|
589
|
-
{ label: '内容Meta数据', value: 'Content' },
|
|
590
|
-
{ label: '全局配置数据', value: 'RuntimeConst' },
|
|
591
|
-
{ label: '资源中心配置', value: 'ResourceCenter' },
|
|
592
|
-
],
|
|
593
|
-
default: 'DevDefaults',
|
|
594
|
-
isConditionProp: !0,
|
|
595
|
-
description:
|
|
596
|
-
'目前支持的数据来源包括: 1)模版直接设置: 在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置: 选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据: 支持内容meta数据的获取,页面meta数据。 4)全局配置数据: 目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
|
|
597
|
-
},
|
|
598
|
-
value: {
|
|
599
|
-
title: '数据值',
|
|
600
|
-
type: 'input',
|
|
601
|
-
default: '',
|
|
602
|
-
description: '',
|
|
603
|
-
placeholder: '',
|
|
604
|
-
onShow: 'type === "Content" || type === "RuntimeConst"',
|
|
605
|
-
},
|
|
606
|
-
description: {
|
|
607
|
-
title: '自定义配置名称',
|
|
608
|
-
type: 'input',
|
|
609
|
-
default: '主题包配置',
|
|
610
|
-
description: '',
|
|
611
|
-
placeholder: '',
|
|
612
|
-
onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
|
|
613
|
-
},
|
|
614
|
-
attrs: {
|
|
615
|
-
type: 'array',
|
|
616
|
-
title: '属性列表',
|
|
617
|
-
description: 'Tab需要配置的属性',
|
|
618
|
-
items: {
|
|
619
|
-
type: 'object',
|
|
620
|
-
title: '数组项',
|
|
621
|
-
description: '',
|
|
622
|
-
properties: {
|
|
623
|
-
attr: {
|
|
624
|
-
type: 'input',
|
|
625
|
-
title: '属性Key',
|
|
626
|
-
default: '',
|
|
627
|
-
description: '',
|
|
628
|
-
placeholder: '',
|
|
629
|
-
},
|
|
630
|
-
description: {
|
|
631
|
-
title: '描述',
|
|
632
|
-
type: 'input',
|
|
633
|
-
default: '',
|
|
634
|
-
description: '',
|
|
635
|
-
placeholder: '',
|
|
636
|
-
},
|
|
637
|
-
value: {
|
|
638
|
-
title: '数值',
|
|
639
|
-
typeOn:
|
|
640
|
-
"type === 'image' ? 'input-image' : type === 'number' ? 'number' : 'input'",
|
|
641
|
-
default: '',
|
|
642
|
-
description: '',
|
|
643
|
-
placeholder: '',
|
|
644
|
-
},
|
|
645
|
-
type: {
|
|
646
|
-
type: 'select',
|
|
647
|
-
title: '属性类型',
|
|
648
|
-
options: [
|
|
649
|
-
{ label: '图片类型', value: 'image' },
|
|
650
|
-
{ label: '字符串', value: 'string' },
|
|
651
|
-
{ label: '数字', value: 'number' },
|
|
652
|
-
],
|
|
653
|
-
default: 'string',
|
|
654
|
-
description: '',
|
|
655
|
-
},
|
|
656
|
-
},
|
|
657
|
-
propertyOrder: ['attr', 'description', 'type', 'value'],
|
|
658
|
-
},
|
|
659
|
-
'minimum-child': 1,
|
|
660
|
-
showCodeViewBtn: !1,
|
|
661
|
-
onShow:
|
|
662
|
-
'type === "DevDefaults" || type === "ContentStaticConfig" || type === "ResourceCenter"',
|
|
663
|
-
},
|
|
664
|
-
},
|
|
665
|
-
propertyOrder: ['type', 'description', 'attrs', 'value'],
|
|
666
|
-
showCodeViewBtn: !1,
|
|
667
|
-
showKey: !0,
|
|
668
|
-
},
|
|
669
|
-
'dynamic-array': {
|
|
670
|
-
type: 'dynamic-array',
|
|
671
|
-
title: '动态数组',
|
|
672
|
-
description: '',
|
|
673
|
-
isContainer: !1,
|
|
674
|
-
properties: {
|
|
675
|
-
type: {
|
|
676
|
-
type: 'select',
|
|
677
|
-
title: '数据来源',
|
|
678
|
-
options: [
|
|
679
|
-
{ label: '模板直接设置', value: 'DevDefaults' },
|
|
680
|
-
{ label: 'mp后台配置', value: 'ContentStaticConfig' },
|
|
681
|
-
{ label: '资源中心配置', value: 'ResourceCenter' },
|
|
682
|
-
],
|
|
683
|
-
default: 'DevDefaults',
|
|
684
|
-
isConditionProp: !0,
|
|
685
|
-
description:
|
|
686
|
-
'目前支持的数据来源包括: 1)模版直接设置:在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置:选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据:支持内容meta数据的获取,页面meta数据。 4)全局配置数据:目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
|
|
687
|
-
},
|
|
688
|
-
description: {
|
|
689
|
-
title: '自定义配置名称',
|
|
690
|
-
type: 'input',
|
|
691
|
-
default: 'Tab全局配置',
|
|
692
|
-
description: '',
|
|
693
|
-
placeholder: '',
|
|
694
|
-
onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
|
|
695
|
-
},
|
|
696
|
-
tabNums: {
|
|
697
|
-
title: 'Tab配置数',
|
|
698
|
-
type: 'number',
|
|
699
|
-
default: 1,
|
|
700
|
-
description: '需要配置的Tab数量',
|
|
701
|
-
placeholder: '',
|
|
702
|
-
onShow: "type === 'ContentStaticConfig' || type === 'ResourceCenter'",
|
|
703
|
-
},
|
|
704
|
-
attrs: {
|
|
705
|
-
type: 'array',
|
|
706
|
-
title: 'Tab属性',
|
|
707
|
-
description: 'Tab需要配置的属性',
|
|
708
|
-
items: {
|
|
709
|
-
type: 'object',
|
|
710
|
-
title: '数组项',
|
|
711
|
-
description: '',
|
|
712
|
-
properties: {
|
|
713
|
-
attr: {
|
|
714
|
-
type: 'input',
|
|
715
|
-
title: '属性Key',
|
|
716
|
-
default: '',
|
|
717
|
-
description: '',
|
|
718
|
-
placeholder: '',
|
|
719
|
-
},
|
|
720
|
-
description: {
|
|
721
|
-
title: '描述',
|
|
722
|
-
type: 'input',
|
|
723
|
-
default: '',
|
|
724
|
-
description: '',
|
|
725
|
-
placeholder: '',
|
|
726
|
-
},
|
|
727
|
-
tipText: {
|
|
728
|
-
title: '提示说明',
|
|
729
|
-
type: 'textarea',
|
|
730
|
-
default: '',
|
|
731
|
-
description: '',
|
|
732
|
-
placeholder: '',
|
|
733
|
-
},
|
|
734
|
-
},
|
|
735
|
-
propertyOrder: ['attr', 'description', 'tipText'],
|
|
736
|
-
},
|
|
737
|
-
'minimum-child': 1,
|
|
738
|
-
onShow: "type === 'ContentStaticConfig' || type === 'ResourceCenter'",
|
|
739
|
-
showCodeViewBtn: !1,
|
|
740
|
-
},
|
|
741
|
-
value: {
|
|
742
|
-
type: 'array',
|
|
743
|
-
title: 'Tab配置',
|
|
744
|
-
description: '',
|
|
745
|
-
items: {
|
|
746
|
-
type: 'object',
|
|
747
|
-
title: '数组项',
|
|
748
|
-
description: '',
|
|
749
|
-
properties: {
|
|
750
|
-
title: {
|
|
751
|
-
type: 'input',
|
|
752
|
-
title: '名称',
|
|
753
|
-
default: '',
|
|
754
|
-
description: '',
|
|
755
|
-
placeholder: '',
|
|
756
|
-
},
|
|
757
|
-
id: {
|
|
758
|
-
title: 'id',
|
|
759
|
-
type: 'input',
|
|
760
|
-
default: '',
|
|
761
|
-
description: '',
|
|
762
|
-
placeholder: '',
|
|
763
|
-
},
|
|
764
|
-
value: {
|
|
765
|
-
title: '数值',
|
|
766
|
-
type: 'input',
|
|
767
|
-
default: '',
|
|
768
|
-
description: '',
|
|
769
|
-
placeholder: '',
|
|
770
|
-
},
|
|
771
|
-
},
|
|
772
|
-
propertyOrder: ['title', 'value', 'id'],
|
|
773
|
-
},
|
|
774
|
-
'minimum-child': 1,
|
|
775
|
-
onShow: "type === 'DevDefaults'",
|
|
776
|
-
showCodeViewBtn: !1,
|
|
777
|
-
},
|
|
778
|
-
},
|
|
779
|
-
propertyOrder: ['type', 'value', 'description', 'tabNums', 'attrs'],
|
|
780
|
-
showCodeViewBtn: !1,
|
|
781
|
-
showKey: !0,
|
|
782
|
-
},
|
|
783
|
-
'sohu-source': {
|
|
784
|
-
type: 'sohu-source',
|
|
785
|
-
title: '数据源',
|
|
786
|
-
description: '',
|
|
787
|
-
isContainer: !1,
|
|
788
|
-
properties: {
|
|
789
|
-
mainConfig: {
|
|
790
|
-
type: 'object',
|
|
791
|
-
title: '主要配置',
|
|
792
|
-
description: '',
|
|
793
|
-
isContainer: !1,
|
|
794
|
-
properties: {
|
|
795
|
-
type: {
|
|
796
|
-
type: 'select',
|
|
797
|
-
title: '数据来源',
|
|
798
|
-
isConditionProp: !0,
|
|
799
|
-
options: [
|
|
800
|
-
{ label: '模板自定义数据源', value: 'RuntimeDataSelfDefine' },
|
|
801
|
-
{ label: 'mp后台配置', value: 'ContentStaticConfig' },
|
|
802
|
-
{ label: '请求当前页面数据', value: 'RuntimeDataSelfContent' },
|
|
803
|
-
{ label: '资源中心配置', value: 'ResourceCenter' },
|
|
804
|
-
],
|
|
805
|
-
default: 'RuntimeDataSelfDefine',
|
|
806
|
-
description: '',
|
|
807
|
-
},
|
|
808
|
-
description: {
|
|
809
|
-
title: '数据源名称',
|
|
810
|
-
type: 'input',
|
|
811
|
-
description: '',
|
|
812
|
-
placeholder: '',
|
|
813
|
-
onShow: 'type === "ContentStaticConfig"',
|
|
814
|
-
},
|
|
815
|
-
dataType: {
|
|
816
|
-
type: 'radio',
|
|
817
|
-
title: '请求方式',
|
|
818
|
-
default: !1,
|
|
819
|
-
options: [
|
|
820
|
-
{ label: '批量请求', value: 'FROMCIS' },
|
|
821
|
-
{ label: '组件内部请求', value: 'FROMCOMPCIS' },
|
|
822
|
-
{ label: '不请求', value: !1 },
|
|
823
|
-
],
|
|
824
|
-
description: '',
|
|
825
|
-
},
|
|
826
|
-
CONTENTID: {
|
|
827
|
-
title: '数据源ID',
|
|
828
|
-
type: 'input',
|
|
829
|
-
description: '',
|
|
830
|
-
placeholder: '',
|
|
831
|
-
onShow: 'type === "RuntimeDataSelfDefine"',
|
|
832
|
-
},
|
|
833
|
-
CONTENTTYPE: {
|
|
834
|
-
type: 'select',
|
|
835
|
-
title: '数据源类型',
|
|
836
|
-
options: [
|
|
837
|
-
{ label: 'channel', value: 13 },
|
|
838
|
-
{ label: 'topic', value: 15 },
|
|
839
|
-
{ label: 'block', value: 14 },
|
|
840
|
-
],
|
|
841
|
-
description: '',
|
|
842
|
-
onShow: 'type === "RuntimeDataSelfDefine"',
|
|
843
|
-
},
|
|
844
|
-
},
|
|
845
|
-
propertyOrder: [
|
|
846
|
-
'type',
|
|
847
|
-
'description',
|
|
848
|
-
'dataType',
|
|
849
|
-
'CONTENTID',
|
|
850
|
-
'CONTENTTYPE',
|
|
851
|
-
],
|
|
852
|
-
showCodeViewBtn: !1,
|
|
853
|
-
},
|
|
854
|
-
outConfig: {
|
|
855
|
-
type: 'object',
|
|
856
|
-
title: '出流配置',
|
|
857
|
-
description: '',
|
|
858
|
-
isContainer: !1,
|
|
859
|
-
properties: {
|
|
860
|
-
PRO: {
|
|
861
|
-
type: 'select',
|
|
862
|
-
title: '内容类型',
|
|
863
|
-
options: [
|
|
864
|
-
{ label: '置顶+加精', value: '4' },
|
|
865
|
-
{ label: '长效置顶', value: '5' },
|
|
866
|
-
],
|
|
867
|
-
description: '',
|
|
868
|
-
},
|
|
869
|
-
FEEDTYPE: {
|
|
870
|
-
type: 'select',
|
|
871
|
-
title: '排序类型',
|
|
872
|
-
options: [
|
|
873
|
-
{ label: '综合', value: 'XTOPIC_SYNTHETICAL' },
|
|
874
|
-
{ label: '最新', value: 'XTOPIC_LATEST' },
|
|
875
|
-
{ label: '相关', value: 'XTOPIC_RELATED' },
|
|
876
|
-
],
|
|
877
|
-
description: '',
|
|
878
|
-
},
|
|
879
|
-
VIEW: {
|
|
880
|
-
type: 'select',
|
|
881
|
-
title: '数据裁剪',
|
|
882
|
-
options: [
|
|
883
|
-
{ label: '相关推荐模式', value: 'articleFeedMode' },
|
|
884
|
-
{ label: '文字链裁剪方式', value: 'textMode' },
|
|
885
|
-
{ label: '短内容摘录方式', value: 'excerptMode' },
|
|
886
|
-
{ label: '互动(点赞/评论)裁剪方式', value: 'interactMode' },
|
|
887
|
-
{ label: '评论文字链裁剪方式', value: 'commentTextMode' },
|
|
888
|
-
{ label: '摘录方式(无点赞)', value: 'excerptCommentMode' },
|
|
889
|
-
{ label: '无限流卡片模式', value: 'dynamicFeedMode' },
|
|
890
|
-
{ label: '时间线模式', value: 'timeLineMode' },
|
|
891
|
-
{ label: '复合内容流模式', value: 'multiFeedMode' },
|
|
892
|
-
{ label: '搜狐号推荐模式', value: 'recommendFeedMode' },
|
|
893
|
-
{ label: '作者页内容流模式', value: 'operateFeedMode' },
|
|
894
|
-
{ label: '标签内容流模式', value: 'tagsFeedMode' },
|
|
895
|
-
{ label: '评论链裁剪方式', value: 'commentMode' },
|
|
896
|
-
{ label: '标签摘录方式', value: 'excerptTagsMode' },
|
|
897
|
-
{ label: '内容流模式', value: 'feedMode' },
|
|
898
|
-
],
|
|
899
|
-
description: '',
|
|
900
|
-
},
|
|
901
|
-
CONTENTCONTEXT: {
|
|
902
|
-
type: 'select',
|
|
903
|
-
title: 'mKey参数',
|
|
904
|
-
options: [
|
|
905
|
-
{
|
|
906
|
-
label: '作者ID+栏目ID',
|
|
907
|
-
value: 'authorColumnId_${#authorColumnId}',
|
|
908
|
-
},
|
|
909
|
-
{
|
|
910
|
-
label: '账号ID',
|
|
911
|
-
value: 'accountId_${#contentData_account_id}',
|
|
912
|
-
},
|
|
913
|
-
{ label: 'mkeyID', value: 'mid_${#mkeyConst_mid}' },
|
|
914
|
-
{ label: 'mkey名称', value: 'mname_${#mkeyConst_mname}' },
|
|
915
|
-
{
|
|
916
|
-
label: '城市Code码',
|
|
917
|
-
value: 'cityCode_${#cityInfo_cityCode}',
|
|
918
|
-
},
|
|
919
|
-
{ label: '城市名称', value: 'cityName_${#cityInfo_cityName}' },
|
|
920
|
-
{
|
|
921
|
-
label: '焦点城市Code码',
|
|
922
|
-
value: 'focusCityCode_${#focusCityInfo_cityCode}',
|
|
923
|
-
},
|
|
924
|
-
],
|
|
925
|
-
description: '',
|
|
926
|
-
},
|
|
927
|
-
CONTENTPARAMS: {
|
|
928
|
-
title: '动态参数',
|
|
929
|
-
type: 'json',
|
|
930
|
-
description: '请填写JSON格式的参数',
|
|
931
|
-
placeholder: '',
|
|
932
|
-
},
|
|
933
|
-
},
|
|
934
|
-
propertyOrder: [
|
|
935
|
-
'PRO',
|
|
936
|
-
'FEEDTYPE',
|
|
937
|
-
'VIEW',
|
|
938
|
-
'CONTENTCONTEXT',
|
|
939
|
-
'CONTENTPARAMS',
|
|
940
|
-
],
|
|
941
|
-
showCodeViewBtn: !1,
|
|
942
|
-
},
|
|
943
|
-
otherConfig: {
|
|
944
|
-
type: 'object',
|
|
945
|
-
title: '选配内容',
|
|
946
|
-
description: '',
|
|
947
|
-
isContainer: !1,
|
|
948
|
-
properties: {
|
|
949
|
-
SIZE: {
|
|
950
|
-
type: 'number',
|
|
951
|
-
title: '容量',
|
|
952
|
-
minimum: 0,
|
|
953
|
-
maximum: 1e3,
|
|
954
|
-
description: '该位置区块需要的内容条数',
|
|
955
|
-
},
|
|
956
|
-
TITLE: {
|
|
957
|
-
title: '标题',
|
|
958
|
-
type: 'input',
|
|
959
|
-
description: '',
|
|
960
|
-
placeholder: '',
|
|
961
|
-
},
|
|
962
|
-
URL: {
|
|
963
|
-
type: 'url',
|
|
964
|
-
title: '更多跳转链接',
|
|
965
|
-
description: '该区块下点击“更多或箭头图标”后的跳转链接',
|
|
966
|
-
placeholder: '',
|
|
967
|
-
},
|
|
968
|
-
CODE: {
|
|
969
|
-
title: 'Code参数',
|
|
970
|
-
type: 'input',
|
|
971
|
-
description: '',
|
|
972
|
-
placeholder: '',
|
|
973
|
-
onShow: !1,
|
|
974
|
-
},
|
|
975
|
-
},
|
|
976
|
-
propertyOrder: ['SIZE', 'TITLE', 'URL', 'CODE'],
|
|
977
|
-
showCodeViewBtn: !1,
|
|
978
|
-
},
|
|
979
|
-
},
|
|
980
|
-
propertyOrder: ['mainConfig', 'otherConfig', 'outConfig'],
|
|
981
|
-
showCodeViewBtn: !1,
|
|
982
|
-
},
|
|
983
|
-
'sohu-event': {
|
|
984
|
-
type: 'sohu-event',
|
|
985
|
-
title: 'sohu组件事件',
|
|
986
|
-
showCodeViewBtn: !1,
|
|
987
|
-
isContainer: !1,
|
|
988
|
-
properties: {
|
|
989
|
-
globalEventMap: {
|
|
990
|
-
type: 'object',
|
|
991
|
-
title: '全局事件Map',
|
|
992
|
-
description: '',
|
|
993
|
-
properties: {
|
|
994
|
-
eventCode: {
|
|
995
|
-
type: 'input',
|
|
996
|
-
title: '事件名称',
|
|
997
|
-
default: '',
|
|
998
|
-
description: '',
|
|
999
|
-
placeholder: '',
|
|
1000
|
-
readOnly: !0,
|
|
1001
|
-
},
|
|
1002
|
-
},
|
|
1003
|
-
propertyOrder: ['eventCode'],
|
|
1004
|
-
showCodeViewBtn: !1,
|
|
1005
|
-
},
|
|
1006
|
-
event: {
|
|
1007
|
-
type: 'array',
|
|
1008
|
-
title: '监听事件',
|
|
1009
|
-
description: '当前组件监听事件列表',
|
|
1010
|
-
default: [],
|
|
1011
|
-
items: {
|
|
1012
|
-
type: 'object',
|
|
1013
|
-
title: '数组项',
|
|
1014
|
-
description: '',
|
|
1015
|
-
properties: {
|
|
1016
|
-
name: {
|
|
1017
|
-
type: 'input',
|
|
1018
|
-
title: '事件',
|
|
1019
|
-
default: '',
|
|
1020
|
-
description: '',
|
|
1021
|
-
placeholder: '',
|
|
1022
|
-
},
|
|
1023
|
-
code: {
|
|
1024
|
-
title: '事件code',
|
|
1025
|
-
type: 'input',
|
|
1026
|
-
default: '',
|
|
1027
|
-
description: '',
|
|
1028
|
-
placeholder: '',
|
|
1029
|
-
},
|
|
1030
|
-
listenName: {
|
|
1031
|
-
title: '事件名称',
|
|
1032
|
-
type: 'input',
|
|
1033
|
-
default: '',
|
|
1034
|
-
description: '',
|
|
1035
|
-
placeholder: '',
|
|
1036
|
-
},
|
|
1037
|
-
desc: {
|
|
1038
|
-
title: '事件描述',
|
|
1039
|
-
type: 'input',
|
|
1040
|
-
default: '',
|
|
1041
|
-
description: '',
|
|
1042
|
-
placeholder: '',
|
|
1043
|
-
},
|
|
1044
|
-
},
|
|
1045
|
-
propertyOrder: ['name', 'code', 'listenName', 'desc'],
|
|
1046
|
-
},
|
|
1047
|
-
showCodeViewBtn: !1,
|
|
1048
|
-
},
|
|
1049
|
-
},
|
|
1050
|
-
propertyOrder: ['globalEventMap', 'event'],
|
|
1051
|
-
},
|
|
1052
|
-
'sohu-ad': {
|
|
1053
|
-
type: 'object',
|
|
1054
|
-
title: '广告配置',
|
|
1055
|
-
description: '',
|
|
1056
|
-
properties: {
|
|
1057
|
-
type: {
|
|
1058
|
-
type: 'select',
|
|
1059
|
-
title: '数据源类型',
|
|
1060
|
-
isConditionProp: !0,
|
|
1061
|
-
options: [
|
|
1062
|
-
{ label: '模板直接设置', value: 'DevDefaults' },
|
|
1063
|
-
{ label: '资源中心配置', value: 'ResourceCenter' },
|
|
1064
|
-
],
|
|
1065
|
-
description: '',
|
|
1066
|
-
},
|
|
1067
|
-
value: {
|
|
1068
|
-
type: 'object',
|
|
1069
|
-
title: '广告规则',
|
|
1070
|
-
description: '',
|
|
1071
|
-
onShow: 'type === "DevDefaults"',
|
|
1072
|
-
properties: {
|
|
1073
|
-
id: {
|
|
1074
|
-
title: '广告ID',
|
|
1075
|
-
type: 'number',
|
|
1076
|
-
description: '',
|
|
1077
|
-
placeholder: '',
|
|
1078
|
-
},
|
|
1079
|
-
rule: {
|
|
1080
|
-
type: 'radio',
|
|
1081
|
-
title: '规则类型',
|
|
1082
|
-
isConditionProp: !0,
|
|
1083
|
-
options: [
|
|
1084
|
-
{ label: '固定位置', value: 1 },
|
|
1085
|
-
{ label: '隔几出几', value: 2 },
|
|
1086
|
-
{ label: '固定位置隔几出几', value: 3 },
|
|
1087
|
-
],
|
|
1088
|
-
description: '',
|
|
1089
|
-
},
|
|
1090
|
-
fixArray: {
|
|
1091
|
-
type: 'select',
|
|
1092
|
-
title: '固定位置',
|
|
1093
|
-
description: '',
|
|
1094
|
-
multiple: !0,
|
|
1095
|
-
onShow: 'rule === 1 || rule === 3',
|
|
1096
|
-
options: [
|
|
1097
|
-
{ label: '1', value: 1 },
|
|
1098
|
-
{ label: '2', value: 2 },
|
|
1099
|
-
{ label: '3', value: 3 },
|
|
1100
|
-
{ label: '4', value: 4 },
|
|
1101
|
-
{ label: '5', value: 5 },
|
|
1102
|
-
{ label: '6', value: 6 },
|
|
1103
|
-
{ label: '7', value: 7 },
|
|
1104
|
-
{ label: '8', value: 8 },
|
|
1105
|
-
{ label: '9', value: 9 },
|
|
1106
|
-
{ label: '10', value: 10 },
|
|
1107
|
-
{ label: '11', value: 11 },
|
|
1108
|
-
{ label: '12', value: 12 },
|
|
1109
|
-
{ label: '13', value: 13 },
|
|
1110
|
-
{ label: '14', value: 14 },
|
|
1111
|
-
{ label: '15', value: 15 },
|
|
1112
|
-
{ label: '16', value: 16 },
|
|
1113
|
-
{ label: '17', value: 17 },
|
|
1114
|
-
{ label: '18', value: 18 },
|
|
1115
|
-
{ label: '19', value: 19 },
|
|
1116
|
-
{ label: '20', value: 20 },
|
|
1117
|
-
{ label: '21', value: 21 },
|
|
1118
|
-
{ label: '22', value: 22 },
|
|
1119
|
-
{ label: '23', value: 23 },
|
|
1120
|
-
{ label: '24', value: 24 },
|
|
1121
|
-
{ label: '25', value: 25 },
|
|
1122
|
-
{ label: '26', value: 26 },
|
|
1123
|
-
{ label: '27', value: 27 },
|
|
1124
|
-
{ label: '28', value: 28 },
|
|
1125
|
-
{ label: '29', value: 29 },
|
|
1126
|
-
{ label: '30', value: 30 },
|
|
1127
|
-
{ label: '31', value: 31 },
|
|
1128
|
-
{ label: '32', value: 32 },
|
|
1129
|
-
{ label: '33', value: 33 },
|
|
1130
|
-
{ label: '34', value: 34 },
|
|
1131
|
-
{ label: '35', value: 35 },
|
|
1132
|
-
{ label: '36', value: 36 },
|
|
1133
|
-
{ label: '37', value: 37 },
|
|
1134
|
-
{ label: '38', value: 38 },
|
|
1135
|
-
{ label: '39', value: 39 },
|
|
1136
|
-
{ label: '40', value: 40 },
|
|
1137
|
-
{ label: '41', value: 41 },
|
|
1138
|
-
{ label: '42', value: 42 },
|
|
1139
|
-
{ label: '43', value: 43 },
|
|
1140
|
-
{ label: '44', value: 44 },
|
|
1141
|
-
{ label: '45', value: 45 },
|
|
1142
|
-
{ label: '46', value: 46 },
|
|
1143
|
-
{ label: '47', value: 47 },
|
|
1144
|
-
{ label: '48', value: 48 },
|
|
1145
|
-
{ label: '49', value: 49 },
|
|
1146
|
-
{ label: '50', value: 50 },
|
|
1147
|
-
],
|
|
1148
|
-
},
|
|
1149
|
-
begin: {
|
|
1150
|
-
type: 'number',
|
|
1151
|
-
title: '开始位置',
|
|
1152
|
-
minimum: '1',
|
|
1153
|
-
maximum: '50',
|
|
1154
|
-
description: '',
|
|
1155
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1156
|
-
},
|
|
1157
|
-
turn: {
|
|
1158
|
-
type: 'number',
|
|
1159
|
-
title: '间隔/隔',
|
|
1160
|
-
minimum: '1',
|
|
1161
|
-
maximum: '50',
|
|
1162
|
-
description: '',
|
|
1163
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1164
|
-
},
|
|
1165
|
-
number: {
|
|
1166
|
-
type: 'number',
|
|
1167
|
-
title: '间隔/出',
|
|
1168
|
-
minimum: '1',
|
|
1169
|
-
maximum: '50',
|
|
1170
|
-
description: '',
|
|
1171
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1172
|
-
},
|
|
1173
|
-
mergeType: {
|
|
1174
|
-
type: 'radio',
|
|
1175
|
-
title: '插入规则',
|
|
1176
|
-
options: [
|
|
1177
|
-
{ label: '覆盖', value: 0 },
|
|
1178
|
-
{ label: '插入', value: 1 },
|
|
1179
|
-
],
|
|
1180
|
-
description: '',
|
|
1181
|
-
},
|
|
1182
|
-
},
|
|
1183
|
-
propertyOrder: [
|
|
1184
|
-
'id',
|
|
1185
|
-
'rule',
|
|
1186
|
-
'fixArray',
|
|
1187
|
-
'begin',
|
|
1188
|
-
'turn',
|
|
1189
|
-
'number',
|
|
1190
|
-
'mergeType',
|
|
1191
|
-
],
|
|
1192
|
-
},
|
|
1193
|
-
range: {
|
|
1194
|
-
type: 'array',
|
|
1195
|
-
title: '广告规则列表',
|
|
1196
|
-
description: '',
|
|
1197
|
-
onShow: 'type === "ResourceCenter"',
|
|
1198
|
-
items: {
|
|
1199
|
-
type: 'object',
|
|
1200
|
-
title: '数组项',
|
|
1201
|
-
description: '',
|
|
1202
|
-
properties: {
|
|
1203
|
-
rule: {
|
|
1204
|
-
type: 'radio',
|
|
1205
|
-
title: '规则类型',
|
|
1206
|
-
isConditionProp: !0,
|
|
1207
|
-
options: [
|
|
1208
|
-
{ label: '固定位置', value: 1 },
|
|
1209
|
-
{ label: '隔几出几', value: 2 },
|
|
1210
|
-
{ label: '固定位置隔几出几', value: 3 },
|
|
1211
|
-
],
|
|
1212
|
-
description: '',
|
|
1213
|
-
},
|
|
1214
|
-
fixArray: {
|
|
1215
|
-
type: 'select',
|
|
1216
|
-
title: '固定位置',
|
|
1217
|
-
description: '',
|
|
1218
|
-
onShow: 'rule === 1 || rule === 3',
|
|
1219
|
-
multiple: !0,
|
|
1220
|
-
options: [
|
|
1221
|
-
{ label: '1', value: 1 },
|
|
1222
|
-
{ label: '2', value: 2 },
|
|
1223
|
-
{ label: '3', value: 3 },
|
|
1224
|
-
{ label: '4', value: 4 },
|
|
1225
|
-
{ label: '5', value: 5 },
|
|
1226
|
-
{ label: '6', value: 6 },
|
|
1227
|
-
{ label: '7', value: 7 },
|
|
1228
|
-
{ label: '8', value: 8 },
|
|
1229
|
-
{ label: '9', value: 9 },
|
|
1230
|
-
{ label: '10', value: 10 },
|
|
1231
|
-
{ label: '11', value: 11 },
|
|
1232
|
-
{ label: '12', value: 12 },
|
|
1233
|
-
{ label: '13', value: 13 },
|
|
1234
|
-
{ label: '14', value: 14 },
|
|
1235
|
-
{ label: '15', value: 15 },
|
|
1236
|
-
{ label: '16', value: 16 },
|
|
1237
|
-
{ label: '17', value: 17 },
|
|
1238
|
-
{ label: '18', value: 18 },
|
|
1239
|
-
{ label: '19', value: 19 },
|
|
1240
|
-
{ label: '20', value: 20 },
|
|
1241
|
-
{ label: '21', value: 21 },
|
|
1242
|
-
{ label: '22', value: 22 },
|
|
1243
|
-
{ label: '23', value: 23 },
|
|
1244
|
-
{ label: '24', value: 24 },
|
|
1245
|
-
{ label: '25', value: 25 },
|
|
1246
|
-
{ label: '26', value: 26 },
|
|
1247
|
-
{ label: '27', value: 27 },
|
|
1248
|
-
{ label: '28', value: 28 },
|
|
1249
|
-
{ label: '29', value: 29 },
|
|
1250
|
-
{ label: '30', value: 30 },
|
|
1251
|
-
{ label: '31', value: 31 },
|
|
1252
|
-
{ label: '32', value: 32 },
|
|
1253
|
-
{ label: '33', value: 33 },
|
|
1254
|
-
{ label: '34', value: 34 },
|
|
1255
|
-
{ label: '35', value: 35 },
|
|
1256
|
-
{ label: '36', value: 36 },
|
|
1257
|
-
{ label: '37', value: 37 },
|
|
1258
|
-
{ label: '38', value: 38 },
|
|
1259
|
-
{ label: '39', value: 39 },
|
|
1260
|
-
{ label: '40', value: 40 },
|
|
1261
|
-
{ label: '41', value: 41 },
|
|
1262
|
-
{ label: '42', value: 42 },
|
|
1263
|
-
{ label: '43', value: 43 },
|
|
1264
|
-
{ label: '44', value: 44 },
|
|
1265
|
-
{ label: '45', value: 45 },
|
|
1266
|
-
{ label: '46', value: 46 },
|
|
1267
|
-
{ label: '47', value: 47 },
|
|
1268
|
-
{ label: '48', value: 48 },
|
|
1269
|
-
{ label: '49', value: 49 },
|
|
1270
|
-
{ label: '50', value: 50 },
|
|
1271
|
-
],
|
|
1272
|
-
},
|
|
1273
|
-
begin: {
|
|
1274
|
-
type: 'number',
|
|
1275
|
-
title: '开始位置',
|
|
1276
|
-
minimum: '1',
|
|
1277
|
-
maximum: '50',
|
|
1278
|
-
description: '',
|
|
1279
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1280
|
-
},
|
|
1281
|
-
turn: {
|
|
1282
|
-
type: 'number',
|
|
1283
|
-
title: '间隔/隔',
|
|
1284
|
-
minimum: '1',
|
|
1285
|
-
maximum: '50',
|
|
1286
|
-
description: '',
|
|
1287
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1288
|
-
},
|
|
1289
|
-
number: {
|
|
1290
|
-
type: 'number',
|
|
1291
|
-
title: '间隔/出',
|
|
1292
|
-
minimum: '1',
|
|
1293
|
-
maximum: '50',
|
|
1294
|
-
description: '',
|
|
1295
|
-
onShow: 'rule === 2 || rule === 3',
|
|
1296
|
-
},
|
|
1297
|
-
mergeType: {
|
|
1298
|
-
type: 'radio',
|
|
1299
|
-
title: '插入规则',
|
|
1300
|
-
options: [
|
|
1301
|
-
{ label: '覆盖', value: 0 },
|
|
1302
|
-
{ label: '插入', value: 1 },
|
|
1303
|
-
],
|
|
1304
|
-
description: '',
|
|
1305
|
-
},
|
|
1306
|
-
},
|
|
1307
|
-
propertyOrder: [
|
|
1308
|
-
'rule',
|
|
1309
|
-
'fixArray',
|
|
1310
|
-
'begin',
|
|
1311
|
-
'turn',
|
|
1312
|
-
'number',
|
|
1313
|
-
'mergeType',
|
|
1314
|
-
],
|
|
1315
|
-
},
|
|
1316
|
-
},
|
|
1317
|
-
},
|
|
1318
|
-
propertyOrder: ['type', 'value', 'range'],
|
|
1319
|
-
},
|
|
513
|
+
event: i,
|
|
1320
514
|
},
|
|
1321
515
|
p = {
|
|
1322
516
|
on: {
|
|
@@ -1349,25 +543,25 @@ var i,
|
|
|
1349
543
|
},
|
|
1350
544
|
propertyOrder: ['type', 'register', 'actionFunc'],
|
|
1351
545
|
},
|
|
1352
|
-
emit:
|
|
546
|
+
emit: i,
|
|
1353
547
|
},
|
|
1354
|
-
|
|
548
|
+
l = { local: a, remote: s };
|
|
1355
549
|
function d(e) {
|
|
1356
550
|
return /^http[s]?:\/\/.*/.test(e);
|
|
1357
551
|
}
|
|
1358
552
|
function f(e) {
|
|
1359
553
|
return 'String' === Object.prototype.toString.call(e).slice(8, -1);
|
|
1360
554
|
}
|
|
1361
|
-
function
|
|
555
|
+
function h(e) {
|
|
1362
556
|
return (
|
|
1363
557
|
'number' == typeof e ||
|
|
1364
558
|
'[object Number]' === Object.prototype.toString.call(e)
|
|
1365
559
|
);
|
|
1366
560
|
}
|
|
1367
|
-
function
|
|
561
|
+
function v(e) {
|
|
1368
562
|
return 'Boolean' === Object.prototype.toString.call(e).slice(8, -1);
|
|
1369
563
|
}
|
|
1370
|
-
function
|
|
564
|
+
function y(e) {
|
|
1371
565
|
return /^\d{4}-\d{2}-\d{2}$/.test(e);
|
|
1372
566
|
}
|
|
1373
567
|
function b(e) {
|
|
@@ -1392,17 +586,17 @@ function O(e) {
|
|
|
1392
586
|
}
|
|
1393
587
|
return !0;
|
|
1394
588
|
}
|
|
1395
|
-
function
|
|
589
|
+
function E(e) {
|
|
1396
590
|
var t = !1;
|
|
1397
591
|
return (
|
|
1398
592
|
'Object' === Object.prototype.toString.call(e).slice(8, -1) && (t = !0), t
|
|
1399
593
|
);
|
|
1400
594
|
}
|
|
1401
|
-
function
|
|
595
|
+
function N(e) {
|
|
1402
596
|
var t = !1;
|
|
1403
|
-
return
|
|
597
|
+
return c.quantity.properties.quantity.enum.indexOf(e) >= 0 && (t = !0), t;
|
|
1404
598
|
}
|
|
1405
|
-
function
|
|
599
|
+
function w(e) {
|
|
1406
600
|
return /^#[0-9a-f]{6}$/.test(e) || /^#[0-9a-f]{3}$/.test(e);
|
|
1407
601
|
}
|
|
1408
602
|
function _(e) {
|
|
@@ -1415,82 +609,82 @@ function j() {
|
|
|
1415
609
|
var e = {};
|
|
1416
610
|
return location.search && (e = n.parse(location.search.substring(1))), e;
|
|
1417
611
|
}
|
|
1418
|
-
function
|
|
612
|
+
function x(e) {
|
|
1419
613
|
var t = '';
|
|
1420
614
|
return url && (t = n.stringify(e)), t;
|
|
1421
615
|
}
|
|
1422
|
-
function
|
|
616
|
+
function S(t) {
|
|
1423
617
|
return e(t);
|
|
1424
618
|
}
|
|
1425
|
-
function
|
|
1426
|
-
if ((
|
|
1427
|
-
if (
|
|
619
|
+
function D(e, r) {
|
|
620
|
+
if ((V(e) && !V(r)) || (!V(e) && V(r)) || typeof e != typeof r) return !1;
|
|
621
|
+
if (E(e) && (e.id !== r.id || e.lastUpdateTime !== r.lastUpdateTime))
|
|
1428
622
|
return !1;
|
|
1429
623
|
var n = new Date().getTime();
|
|
1430
624
|
return (
|
|
1431
625
|
!!(
|
|
1432
|
-
|
|
626
|
+
E(e) &&
|
|
1433
627
|
e.lastUpdateTime &&
|
|
1434
628
|
e.lastUpdateTime === r.lastUpdateTime &&
|
|
1435
629
|
n - e.lastUpdateTime < 500
|
|
1436
630
|
) || t(e, r)
|
|
1437
631
|
);
|
|
1438
632
|
}
|
|
1439
|
-
function
|
|
1440
|
-
if ((
|
|
1441
|
-
if (
|
|
633
|
+
function A(e, r) {
|
|
634
|
+
if ((V(e) && !V(r)) || (!V(e) && V(r)) || typeof e != typeof r) return !1;
|
|
635
|
+
if (E(e) && (e.id !== r.id || e.lastUpdateTime !== r.lastUpdateTime))
|
|
1442
636
|
return !1;
|
|
1443
637
|
var n = new Date().getTime();
|
|
1444
638
|
return (
|
|
1445
639
|
!!(
|
|
1446
|
-
|
|
640
|
+
E(e) &&
|
|
1447
641
|
e.lastUpdateTime &&
|
|
1448
642
|
e.lastUpdateTime === r.lastUpdateTime &&
|
|
1449
643
|
n - e.lastUpdateTime < 500
|
|
1450
644
|
) ||
|
|
1451
645
|
!(
|
|
1452
|
-
!
|
|
646
|
+
!E(e) ||
|
|
1453
647
|
!(
|
|
1454
|
-
(
|
|
1455
|
-
(
|
|
648
|
+
(V(e.id) && e.id === r.id) ||
|
|
649
|
+
(V(e.lastUpdateTime) && e.lastUpdateTime === r.lastUpdateTime)
|
|
1456
650
|
)
|
|
1457
651
|
) ||
|
|
1458
652
|
t(e, r)
|
|
1459
653
|
);
|
|
1460
654
|
}
|
|
1461
|
-
function
|
|
655
|
+
function V(e) {
|
|
1462
656
|
var t = !1;
|
|
1463
657
|
return null != e && (t = !0), t;
|
|
1464
658
|
}
|
|
1465
659
|
function T(e, t) {
|
|
1466
660
|
return r(e, t);
|
|
1467
661
|
}
|
|
1468
|
-
function
|
|
662
|
+
function k(e, t) {
|
|
1469
663
|
var r = t || {};
|
|
1470
664
|
if (!e) return !1;
|
|
1471
665
|
var n = new Function('data', 'with(data) { return (' + e + ');}'),
|
|
1472
|
-
|
|
666
|
+
o = '';
|
|
1473
667
|
try {
|
|
1474
|
-
|
|
668
|
+
o = n(r);
|
|
1475
669
|
} catch (t) {
|
|
1476
|
-
return console.warn('表达式运算出错: ' + e + ',报错信息:', t),
|
|
670
|
+
return console.warn('表达式运算出错: ' + e + ',报错信息:', t), o;
|
|
1477
671
|
}
|
|
1478
|
-
return
|
|
672
|
+
return o;
|
|
1479
673
|
}
|
|
1480
|
-
function
|
|
674
|
+
function C(e, t, r) {
|
|
1481
675
|
var n = t;
|
|
1482
|
-
if ((r && (n =
|
|
1483
|
-
for (var
|
|
1484
|
-
var s = i
|
|
676
|
+
if ((r && (n = S(t)), e))
|
|
677
|
+
for (var o = e.split('-'), i = 0, a = o.length; i < a; i++) {
|
|
678
|
+
var s = o[i];
|
|
1485
679
|
s && (n = n && n[s]);
|
|
1486
680
|
}
|
|
1487
681
|
return n;
|
|
1488
682
|
}
|
|
1489
|
-
function
|
|
683
|
+
function R(e, t, r) {
|
|
1490
684
|
var n = t;
|
|
1491
|
-
if ((r && (n =
|
|
1492
|
-
for (var
|
|
1493
|
-
var s = i
|
|
685
|
+
if ((r && (n = S(t)), e))
|
|
686
|
+
for (var o = e.split('-'), i = 0, a = o.length; i < a; i++) {
|
|
687
|
+
var s = o[i];
|
|
1494
688
|
if (
|
|
1495
689
|
'0' !== s ||
|
|
1496
690
|
('array' !== n.type &&
|
|
@@ -1500,12 +694,12 @@ function k(e, t, r) {
|
|
|
1500
694
|
(!n.options && !n.items)
|
|
1501
695
|
) {
|
|
1502
696
|
if (s) {
|
|
1503
|
-
var
|
|
1504
|
-
if (n.propertyOrder)
|
|
697
|
+
var u = '0';
|
|
698
|
+
if (n.propertyOrder) u = n.propertyOrder[s];
|
|
1505
699
|
else if (n.properties) {
|
|
1506
|
-
|
|
700
|
+
u = Object.keys(n.properties)[s];
|
|
1507
701
|
}
|
|
1508
|
-
n = n.properties[
|
|
702
|
+
n = n.properties[u];
|
|
1509
703
|
}
|
|
1510
704
|
} else n = n.options || n.items;
|
|
1511
705
|
}
|
|
@@ -1513,69 +707,69 @@ function k(e, t, r) {
|
|
|
1513
707
|
}
|
|
1514
708
|
function P(e, t, r) {
|
|
1515
709
|
var n = t;
|
|
1516
|
-
if ((r && (n =
|
|
1517
|
-
for (var
|
|
1518
|
-
var s = i
|
|
710
|
+
if ((r && (n = S(t)), e && n))
|
|
711
|
+
for (var o = e.split('-'), i = 0, a = o.length; i < a; i++) {
|
|
712
|
+
var s = o[i];
|
|
1519
713
|
s && n.properties && (n = n.properties[s]);
|
|
1520
714
|
}
|
|
1521
715
|
return n;
|
|
1522
716
|
}
|
|
1523
|
-
function
|
|
1524
|
-
for (var r = t, n = '',
|
|
1525
|
-
var s = i
|
|
717
|
+
function U(e, t) {
|
|
718
|
+
for (var r = t, n = '', o = e.split('-'), i = 0, a = o.length; i < a; i++) {
|
|
719
|
+
var s = o[i];
|
|
1526
720
|
if ('0' === s && r.items) (r = r.items), (n = n ? n + '-items' : 'items');
|
|
1527
721
|
else if ('0' === s && r.options)
|
|
1528
722
|
(r = r.options), (n = n ? n + '-options' : 'options');
|
|
1529
723
|
else if (s) {
|
|
1530
|
-
var
|
|
1531
|
-
if (r.propertyOrder)
|
|
724
|
+
var u = '0';
|
|
725
|
+
if (r.propertyOrder) u = r.propertyOrder[s];
|
|
1532
726
|
else if (r.properties) {
|
|
1533
|
-
|
|
727
|
+
u = Object.keys(r.properties)[s];
|
|
1534
728
|
}
|
|
1535
|
-
(r = r.properties[
|
|
729
|
+
(r = r.properties[u]), (n = n ? n + '-' + u : u);
|
|
1536
730
|
}
|
|
1537
731
|
}
|
|
1538
732
|
return n;
|
|
1539
733
|
}
|
|
1540
|
-
function
|
|
1541
|
-
for (var r = t, n = '',
|
|
1542
|
-
var s = i
|
|
734
|
+
function q(e, t) {
|
|
735
|
+
for (var r = t, n = '', o = e.split('-'), i = 0, a = o.length; i < a; i++) {
|
|
736
|
+
var s = o[i];
|
|
1543
737
|
if (s) {
|
|
1544
|
-
var
|
|
738
|
+
var u = -1;
|
|
1545
739
|
if (r.propertyOrder)
|
|
1546
|
-
(
|
|
740
|
+
(u = r.propertyOrder.indexOf(s)), (r = r.properties[s]);
|
|
1547
741
|
else if (r.properties) {
|
|
1548
|
-
(
|
|
742
|
+
(u = Object.keys(r.properties).indexOf(s)), (r = r.properties[s]);
|
|
1549
743
|
} else
|
|
1550
744
|
r.items
|
|
1551
|
-
? ((
|
|
1552
|
-
: r.options && ((
|
|
1553
|
-
n = n ? n + '-' +
|
|
745
|
+
? ((u = 0), (r = r.items))
|
|
746
|
+
: r.options && ((u = 0), (r = r.options));
|
|
747
|
+
n = n ? n + '-' + u : u.toString();
|
|
1554
748
|
}
|
|
1555
749
|
}
|
|
1556
750
|
return n;
|
|
1557
751
|
}
|
|
1558
|
-
function
|
|
752
|
+
function L(e) {
|
|
1559
753
|
var t = {};
|
|
1560
754
|
return (
|
|
1561
755
|
(t =
|
|
1562
|
-
e &&
|
|
756
|
+
e && E(e)
|
|
1563
757
|
? (function (e) {
|
|
1564
758
|
var t;
|
|
1565
|
-
if (
|
|
759
|
+
if (E(e)) {
|
|
1566
760
|
var r = Object.keys(e);
|
|
1567
761
|
e.data && e.filter && 2 === r.length
|
|
1568
|
-
? (t = g(e.data) ||
|
|
762
|
+
? (t = g(e.data) || E(e.data) ? S(l.local) : S(l.remote))
|
|
1569
763
|
: e.trigger && e.eventData && 2 === r.length
|
|
1570
|
-
? (t =
|
|
764
|
+
? (t = S(p.emit))
|
|
1571
765
|
: e.register && e.actionFunc && 2 === r.length
|
|
1572
|
-
? (t =
|
|
1573
|
-
: e.quantity &&
|
|
1574
|
-
? (t =
|
|
1575
|
-
: ((t =
|
|
766
|
+
? (t = S(p.on))
|
|
767
|
+
: e.quantity && N(e.quantity) && 2 === r.length
|
|
768
|
+
? (t = S(c.quantity))
|
|
769
|
+
: ((t = S(c['empty-object'])),
|
|
1576
770
|
Object.keys(e).map(function (r) {
|
|
1577
771
|
var n = e[r];
|
|
1578
|
-
t.properties[r] =
|
|
772
|
+
t.properties[r] = L(n);
|
|
1579
773
|
}));
|
|
1580
774
|
}
|
|
1581
775
|
return t;
|
|
@@ -1585,69 +779,69 @@ function B(e) {
|
|
|
1585
779
|
var t;
|
|
1586
780
|
if (e && g(e))
|
|
1587
781
|
if (O(e)) {
|
|
1588
|
-
(t =
|
|
782
|
+
(t = S(c.select)).items.enum = e;
|
|
1589
783
|
var r = t.items.enumextra.length,
|
|
1590
784
|
n = e.length;
|
|
1591
785
|
if (n > r)
|
|
1592
|
-
for (var
|
|
1593
|
-
t.items.enumextra.push('选项' + e(
|
|
786
|
+
for (var o = r, i = n; o < i; o++)
|
|
787
|
+
t.items.enumextra.push('选项' + e(o));
|
|
1594
788
|
} else {
|
|
1595
|
-
t =
|
|
1596
|
-
var a =
|
|
789
|
+
t = S(c['empty-array']);
|
|
790
|
+
var a = L(e[0]);
|
|
1597
791
|
t.items.properties = a.properties;
|
|
1598
792
|
}
|
|
1599
793
|
return t;
|
|
1600
794
|
})(e)
|
|
1601
795
|
: (function (e) {
|
|
1602
796
|
var t = '';
|
|
1603
|
-
if (
|
|
1604
|
-
else if (
|
|
1605
|
-
else if (d(e)) t =
|
|
1606
|
-
else if (
|
|
1607
|
-
else if (b(e)) t =
|
|
1608
|
-
else if (m(e)) t =
|
|
1609
|
-
else if (
|
|
797
|
+
if (v(e)) t = S(c.boolean);
|
|
798
|
+
else if (h(e)) t = S(c.number);
|
|
799
|
+
else if (d(e)) t = S(c.url);
|
|
800
|
+
else if (y(e)) t = S(c.date);
|
|
801
|
+
else if (b(e)) t = S(c['date-time']);
|
|
802
|
+
else if (m(e)) t = S(c.time);
|
|
803
|
+
else if (w(e)) t = S(c.color);
|
|
1610
804
|
else
|
|
1611
805
|
try {
|
|
1612
|
-
t =
|
|
806
|
+
t = h(JSON.parse(e)) ? S(c.input) : S(c.json);
|
|
1613
807
|
} catch (r) {
|
|
1614
|
-
t = e && e.length > 30 ?
|
|
808
|
+
t = e && e.length > 30 ? S(c.textarea) : S(c.input);
|
|
1615
809
|
}
|
|
1616
810
|
return t;
|
|
1617
811
|
})(e)),
|
|
1618
812
|
t
|
|
1619
813
|
);
|
|
1620
814
|
}
|
|
1621
|
-
function
|
|
815
|
+
function B(e, t) {
|
|
1622
816
|
var r = t || {};
|
|
1623
|
-
if (
|
|
817
|
+
if (E(e) && 'object' === getExpectType(e.type) && e.properties) {
|
|
1624
818
|
(e.propertyOrder ? e.propertyOrder : Object.keys(e.properties)).map(
|
|
1625
819
|
function (t) {
|
|
1626
820
|
var n = e.properties[t];
|
|
1627
|
-
r =
|
|
821
|
+
r = I(n, r);
|
|
1628
822
|
},
|
|
1629
823
|
);
|
|
1630
824
|
}
|
|
1631
825
|
return r;
|
|
1632
826
|
}
|
|
1633
|
-
function
|
|
827
|
+
function I(e, t) {
|
|
1634
828
|
var r = !t,
|
|
1635
829
|
n = t || {};
|
|
1636
830
|
if (e && '{}' !== JSON.stringify(e)) {
|
|
1637
|
-
var
|
|
1638
|
-
'object' ===
|
|
1639
|
-
? (!r && n.object ? (n.object += 1) : r || (n.object = 1), (n =
|
|
1640
|
-
: 'array' ===
|
|
831
|
+
var o = e.type;
|
|
832
|
+
'object' === o || 'func' === o || 'style' === o || 'data' === o
|
|
833
|
+
? (!r && n.object ? (n.object += 1) : r || (n.object = 1), (n = B(e, n)))
|
|
834
|
+
: 'array' === o
|
|
1641
835
|
? (!r && n.array ? (n.array += 1) : r || (n.array = 1),
|
|
1642
|
-
(n =
|
|
1643
|
-
: !r && n[
|
|
1644
|
-
? (n[
|
|
1645
|
-
: r || (n[
|
|
836
|
+
(n = B((e = e.items), n)))
|
|
837
|
+
: !r && n[o]
|
|
838
|
+
? (n[o] += 1)
|
|
839
|
+
: r || (n[o] = 1);
|
|
1646
840
|
}
|
|
1647
841
|
return n;
|
|
1648
842
|
}
|
|
1649
|
-
function
|
|
1650
|
-
var t =
|
|
843
|
+
function M(e) {
|
|
844
|
+
var t = S(e);
|
|
1651
845
|
if (
|
|
1652
846
|
(!t.title && t.description && (t.title = t.description),
|
|
1653
847
|
t.type || (t.type = t.format),
|
|
@@ -1656,7 +850,7 @@ function q(e) {
|
|
|
1656
850
|
'datasource' !== t.type &&
|
|
1657
851
|
'event' !== t.type &&
|
|
1658
852
|
'object' !== t.type) ||
|
|
1659
|
-
!
|
|
853
|
+
!V(t.default) ||
|
|
1660
854
|
delete t.default,
|
|
1661
855
|
'radio' === t.type &&
|
|
1662
856
|
((t.type = 'string'),
|
|
@@ -1664,60 +858,60 @@ function q(e) {
|
|
|
1664
858
|
t.enumextra &&
|
|
1665
859
|
((t.items = {
|
|
1666
860
|
type: 'string',
|
|
1667
|
-
enum:
|
|
1668
|
-
enumextra:
|
|
861
|
+
enum: S(t.enum),
|
|
862
|
+
enumextra: S(t.enumextra),
|
|
1669
863
|
}),
|
|
1670
864
|
delete t.enum,
|
|
1671
865
|
delete t.enumextra)),
|
|
1672
866
|
'quantity' === t.type)
|
|
1673
867
|
) {
|
|
1674
868
|
var r = t.properties,
|
|
1675
|
-
n =
|
|
1676
|
-
if (r.quantity &&
|
|
1677
|
-
var
|
|
1678
|
-
n.properties.quantity.default = 'percent' ===
|
|
869
|
+
n = S(c.quantity);
|
|
870
|
+
if (r.quantity && E(r.quantity) && r.quantity.default) {
|
|
871
|
+
var o = r.quantity.default;
|
|
872
|
+
n.properties.quantity.default = 'percent' === o ? '%' : o;
|
|
1679
873
|
}
|
|
1680
874
|
t = n;
|
|
1681
875
|
}
|
|
1682
876
|
if ('datasource' === t.type) {
|
|
1683
|
-
var
|
|
1684
|
-
a =
|
|
1685
|
-
s =
|
|
1686
|
-
|
|
877
|
+
var i = t.properties,
|
|
878
|
+
a = i.type && i.type.default,
|
|
879
|
+
s = i.data && i.data.default,
|
|
880
|
+
u = i.filter && i.filter.default;
|
|
1687
881
|
'local' === a
|
|
1688
|
-
? ((t =
|
|
1689
|
-
: ((t =
|
|
1690
|
-
(t.properties.filter.default =
|
|
882
|
+
? ((t = S(l.local)).properties.data.default = s ? S(s) : '{}')
|
|
883
|
+
: ((t = S(l.remote)).properties.data.default = s ? S(s) : 'http://xxx'),
|
|
884
|
+
(t.properties.filter.default = u ? S(u) : '() => {}');
|
|
1691
885
|
}
|
|
1692
886
|
if ('event' === t.type) {
|
|
1693
887
|
var d = t.properties,
|
|
1694
888
|
f = d.type && d.type.default;
|
|
1695
889
|
if ('in' === f || 'on' === f) {
|
|
1696
|
-
var
|
|
1697
|
-
(t =
|
|
890
|
+
var h = (d.filter && d.filter.default) || '() => {}';
|
|
891
|
+
(t = S(p.on)),
|
|
1698
892
|
d.actionFunc &&
|
|
1699
|
-
|
|
1700
|
-
(t.properties.actionFunc.default = d.actionFunc.default ||
|
|
893
|
+
E(d.actionFunc) &&
|
|
894
|
+
(t.properties.actionFunc.default = d.actionFunc.default || S(h));
|
|
1701
895
|
} else {
|
|
1702
|
-
var
|
|
1703
|
-
(t =
|
|
896
|
+
var v = (d.filter && d.filter.default) || '{}';
|
|
897
|
+
(t = S(p.emit)),
|
|
1704
898
|
d.eventData &&
|
|
1705
|
-
|
|
1706
|
-
(t.properties.eventData.default = d.eventData.default ||
|
|
899
|
+
E(d.eventData) &&
|
|
900
|
+
(t.properties.eventData.default = d.eventData.default || S(v));
|
|
1707
901
|
}
|
|
1708
902
|
}
|
|
1709
903
|
return (
|
|
1710
904
|
t.properties &&
|
|
1711
905
|
(t.propertyOrder || (t.propertyOrder = Object.keys(t.properties)),
|
|
1712
906
|
t.propertyOrder.map(function (e) {
|
|
1713
|
-
t.properties[e] =
|
|
907
|
+
t.properties[e] = G(t.properties[e]);
|
|
1714
908
|
})),
|
|
1715
|
-
t.items && (t.items =
|
|
909
|
+
t.items && (t.items = G(t.items)),
|
|
1716
910
|
t
|
|
1717
911
|
);
|
|
1718
912
|
}
|
|
1719
|
-
function
|
|
1720
|
-
var t =
|
|
913
|
+
function G(e) {
|
|
914
|
+
var t = S(e);
|
|
1721
915
|
return (
|
|
1722
916
|
t.required || delete t.required,
|
|
1723
917
|
t.type && t.type && (t.type = t.type),
|
|
@@ -1726,7 +920,7 @@ function F(e) {
|
|
|
1726
920
|
'datasource' !== t.type &&
|
|
1727
921
|
'event' !== t.type &&
|
|
1728
922
|
'object' !== t.type) ||
|
|
1729
|
-
!
|
|
923
|
+
!V(t.default) ||
|
|
1730
924
|
delete t.default,
|
|
1731
925
|
('radio' !== t.type && 'checkboxes' !== t.type && 'select' !== t.type) ||
|
|
1732
926
|
(t.items &&
|
|
@@ -1740,16 +934,16 @@ function F(e) {
|
|
|
1740
934
|
t.properties &&
|
|
1741
935
|
(t.propertyOrder || (t.propertyOrder = Object.keys(t.properties)),
|
|
1742
936
|
t.propertyOrder.map(function (e) {
|
|
1743
|
-
t.properties[e] =
|
|
937
|
+
t.properties[e] = G(t.properties[e]);
|
|
1744
938
|
})),
|
|
1745
|
-
'array' === t.type && t.items && (t.items =
|
|
939
|
+
'array' === t.type && t.items && (t.items = G(t.items)),
|
|
1746
940
|
t
|
|
1747
941
|
);
|
|
1748
942
|
}
|
|
1749
|
-
var
|
|
1750
|
-
Object.freeze(
|
|
943
|
+
var z = [];
|
|
944
|
+
Object.freeze(z);
|
|
1751
945
|
var K = {};
|
|
1752
|
-
function
|
|
946
|
+
function F() {
|
|
1753
947
|
return ++ft.mobxGuid;
|
|
1754
948
|
}
|
|
1755
949
|
function J(e) {
|
|
@@ -1770,8 +964,8 @@ function W(e) {
|
|
|
1770
964
|
};
|
|
1771
965
|
}
|
|
1772
966
|
Object.freeze(K);
|
|
1773
|
-
var
|
|
1774
|
-
function
|
|
967
|
+
var X = function () {};
|
|
968
|
+
function $(e) {
|
|
1775
969
|
return null !== e && 'object' == typeof e;
|
|
1776
970
|
}
|
|
1777
971
|
function Y(e) {
|
|
@@ -1796,7 +990,7 @@ function ee(e, t) {
|
|
|
1796
990
|
return (
|
|
1797
991
|
(t.prototype[r] = !0),
|
|
1798
992
|
function (e) {
|
|
1799
|
-
return
|
|
993
|
+
return $(e) && !0 === e[r];
|
|
1800
994
|
}
|
|
1801
995
|
);
|
|
1802
996
|
}
|
|
@@ -1816,10 +1010,10 @@ function ne(e) {
|
|
|
1816
1010
|
Array.from(t)
|
|
1817
1011
|
);
|
|
1818
1012
|
}
|
|
1819
|
-
function
|
|
1013
|
+
function oe(e) {
|
|
1820
1014
|
return e && e.toString ? e.toString() : new String(e).toString();
|
|
1821
1015
|
}
|
|
1822
|
-
function
|
|
1016
|
+
function ie(e) {
|
|
1823
1017
|
return null === e ? null : 'object' == typeof e ? '' + e : e;
|
|
1824
1018
|
}
|
|
1825
1019
|
var ae =
|
|
@@ -1833,16 +1027,16 @@ var ae =
|
|
|
1833
1027
|
}
|
|
1834
1028
|
: Object.getOwnPropertyNames,
|
|
1835
1029
|
se = Symbol('mobx administration'),
|
|
1836
|
-
|
|
1030
|
+
ue = (function () {
|
|
1837
1031
|
function e(e) {
|
|
1838
|
-
void 0 === e && (e = 'Atom@' +
|
|
1032
|
+
void 0 === e && (e = 'Atom@' + F()),
|
|
1839
1033
|
(this.name = e),
|
|
1840
1034
|
(this.isPendingUnobservation = !1),
|
|
1841
1035
|
(this.isBeingObserved = !1),
|
|
1842
1036
|
(this.observers = new Set()),
|
|
1843
1037
|
(this.diffValue = 0),
|
|
1844
1038
|
(this.lastAccessedBy = 0),
|
|
1845
|
-
(this.lowestObserverState =
|
|
1039
|
+
(this.lowestObserverState = Le.NOT_TRACKING);
|
|
1846
1040
|
}
|
|
1847
1041
|
return (
|
|
1848
1042
|
(e.prototype.onBecomeObserved = function () {
|
|
@@ -1863,12 +1057,12 @@ var ae =
|
|
|
1863
1057
|
(e.prototype.reportChanged = function () {
|
|
1864
1058
|
bt(),
|
|
1865
1059
|
(function (e) {
|
|
1866
|
-
if (e.lowestObserverState ===
|
|
1867
|
-
(e.lowestObserverState =
|
|
1060
|
+
if (e.lowestObserverState === Le.STALE) return;
|
|
1061
|
+
(e.lowestObserverState = Le.STALE),
|
|
1868
1062
|
e.observers.forEach(function (t) {
|
|
1869
|
-
t.dependenciesState ===
|
|
1870
|
-
(t.isTracing !==
|
|
1871
|
-
(t.dependenciesState =
|
|
1063
|
+
t.dependenciesState === Le.UP_TO_DATE &&
|
|
1064
|
+
(t.isTracing !== Be.NONE && Ot(t, e), t.onBecomeStale()),
|
|
1065
|
+
(t.dependenciesState = Le.STALE);
|
|
1872
1066
|
});
|
|
1873
1067
|
})(this),
|
|
1874
1068
|
mt();
|
|
@@ -1879,14 +1073,14 @@ var ae =
|
|
|
1879
1073
|
e
|
|
1880
1074
|
);
|
|
1881
1075
|
})(),
|
|
1882
|
-
|
|
1076
|
+
ce = ee('Atom', ue);
|
|
1883
1077
|
function pe(e, t, r) {
|
|
1884
|
-
void 0 === t && (t =
|
|
1078
|
+
void 0 === t && (t = X), void 0 === r && (r = X);
|
|
1885
1079
|
var n,
|
|
1886
|
-
|
|
1887
|
-
return t !==
|
|
1080
|
+
o = new ue(e);
|
|
1081
|
+
return t !== X && Pt('onBecomeObserved', o, t, n), r !== X && Rt(o, r), o;
|
|
1888
1082
|
}
|
|
1889
|
-
var
|
|
1083
|
+
var le = {
|
|
1890
1084
|
identity: function (e, t) {
|
|
1891
1085
|
return e === t;
|
|
1892
1086
|
},
|
|
@@ -1934,14 +1128,14 @@ and limitations under the License.
|
|
|
1934
1128
|
Object.assign ||
|
|
1935
1129
|
function (e) {
|
|
1936
1130
|
for (var t, r = 1, n = arguments.length; r < n; r++)
|
|
1937
|
-
for (var
|
|
1938
|
-
Object.prototype.hasOwnProperty.call(t,
|
|
1131
|
+
for (var o in (t = arguments[r]))
|
|
1132
|
+
Object.prototype.hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
1939
1133
|
return e;
|
|
1940
1134
|
}),
|
|
1941
1135
|
fe.apply(this, arguments)
|
|
1942
1136
|
);
|
|
1943
1137
|
};
|
|
1944
|
-
function
|
|
1138
|
+
function he(e) {
|
|
1945
1139
|
var t = 'function' == typeof Symbol && e[Symbol.iterator],
|
|
1946
1140
|
r = 0;
|
|
1947
1141
|
return t
|
|
@@ -1954,44 +1148,44 @@ function ve(e) {
|
|
|
1954
1148
|
},
|
|
1955
1149
|
};
|
|
1956
1150
|
}
|
|
1957
|
-
function
|
|
1151
|
+
function ve(e, t) {
|
|
1958
1152
|
var r = 'function' == typeof Symbol && e[Symbol.iterator];
|
|
1959
1153
|
if (!r) return e;
|
|
1960
1154
|
var n,
|
|
1961
|
-
|
|
1962
|
-
|
|
1155
|
+
o,
|
|
1156
|
+
i = r.call(e),
|
|
1963
1157
|
a = [];
|
|
1964
1158
|
try {
|
|
1965
|
-
for (; (void 0 === t || t-- > 0) && !(n =
|
|
1159
|
+
for (; (void 0 === t || t-- > 0) && !(n = i.next()).done; ) a.push(n.value);
|
|
1966
1160
|
} catch (e) {
|
|
1967
|
-
|
|
1161
|
+
o = { error: e };
|
|
1968
1162
|
} finally {
|
|
1969
1163
|
try {
|
|
1970
|
-
n && !n.done && (r =
|
|
1164
|
+
n && !n.done && (r = i.return) && r.call(i);
|
|
1971
1165
|
} finally {
|
|
1972
|
-
if (
|
|
1166
|
+
if (o) throw o.error;
|
|
1973
1167
|
}
|
|
1974
1168
|
}
|
|
1975
1169
|
return a;
|
|
1976
1170
|
}
|
|
1977
|
-
function
|
|
1171
|
+
function ye() {
|
|
1978
1172
|
for (var e = [], t = 0; t < arguments.length; t++)
|
|
1979
|
-
e = e.concat(
|
|
1173
|
+
e = e.concat(ve(arguments[t]));
|
|
1980
1174
|
return e;
|
|
1981
1175
|
}
|
|
1982
1176
|
var be = Symbol('mobx did run lazy initializers'),
|
|
1983
1177
|
me = Symbol('mobx pending decorators'),
|
|
1984
1178
|
ge = {},
|
|
1985
1179
|
Oe = {};
|
|
1986
|
-
function
|
|
1180
|
+
function Ee(e) {
|
|
1987
1181
|
var t, r;
|
|
1988
1182
|
if (!0 !== e[be]) {
|
|
1989
1183
|
var n = e[me];
|
|
1990
1184
|
if (n) {
|
|
1991
1185
|
Z(e, be, !0);
|
|
1992
|
-
var
|
|
1186
|
+
var o = ye(Object.getOwnPropertySymbols(n), Object.keys(n));
|
|
1993
1187
|
try {
|
|
1994
|
-
for (var
|
|
1188
|
+
for (var i = he(o), a = i.next(); !a.done; a = i.next()) {
|
|
1995
1189
|
var s = n[a.value];
|
|
1996
1190
|
s.propertyCreator(
|
|
1997
1191
|
e,
|
|
@@ -2005,7 +1199,7 @@ function we(e) {
|
|
|
2005
1199
|
t = { error: e };
|
|
2006
1200
|
} finally {
|
|
2007
1201
|
try {
|
|
2008
|
-
a && !a.done && (r =
|
|
1202
|
+
a && !a.done && (r = i.return) && r.call(i);
|
|
2009
1203
|
} finally {
|
|
2010
1204
|
if (t) throw t.error;
|
|
2011
1205
|
}
|
|
@@ -2013,14 +1207,14 @@ function we(e) {
|
|
|
2013
1207
|
}
|
|
2014
1208
|
}
|
|
2015
1209
|
}
|
|
2016
|
-
function
|
|
1210
|
+
function Ne(e, t) {
|
|
2017
1211
|
return function () {
|
|
2018
1212
|
var r,
|
|
2019
|
-
n = function (n,
|
|
2020
|
-
if (!0 === a) return t(n,
|
|
1213
|
+
n = function (n, o, i, a) {
|
|
1214
|
+
if (!0 === a) return t(n, o, i, n, r), null;
|
|
2021
1215
|
if (
|
|
2022
1216
|
('production' === process.env.NODE_ENV ||
|
|
2023
|
-
|
|
1217
|
+
we(arguments) ||
|
|
2024
1218
|
J(
|
|
2025
1219
|
"This function is a decorator, but it wasn't invoked like a decorator",
|
|
2026
1220
|
),
|
|
@@ -2030,10 +1224,10 @@ function Ee(e, t) {
|
|
|
2030
1224
|
Z(n, me, fe({}, s));
|
|
2031
1225
|
}
|
|
2032
1226
|
return (
|
|
2033
|
-
(n[me][
|
|
2034
|
-
prop:
|
|
1227
|
+
(n[me][o] = {
|
|
1228
|
+
prop: o,
|
|
2035
1229
|
propertyCreator: t,
|
|
2036
|
-
descriptor:
|
|
1230
|
+
descriptor: i,
|
|
2037
1231
|
decoratorTarget: n,
|
|
2038
1232
|
decoratorArguments: r,
|
|
2039
1233
|
}),
|
|
@@ -2045,22 +1239,22 @@ function Ee(e, t) {
|
|
|
2045
1239
|
configurable: !0,
|
|
2046
1240
|
enumerable: t,
|
|
2047
1241
|
get: function () {
|
|
2048
|
-
return
|
|
1242
|
+
return Ee(this), this[e];
|
|
2049
1243
|
},
|
|
2050
1244
|
set: function (t) {
|
|
2051
|
-
|
|
1245
|
+
Ee(this), (this[e] = t);
|
|
2052
1246
|
},
|
|
2053
1247
|
})
|
|
2054
1248
|
);
|
|
2055
|
-
})(
|
|
1249
|
+
})(o, e)
|
|
2056
1250
|
);
|
|
2057
1251
|
};
|
|
2058
|
-
return
|
|
2059
|
-
? ((r =
|
|
1252
|
+
return we(arguments)
|
|
1253
|
+
? ((r = z), n.apply(null, arguments))
|
|
2060
1254
|
: ((r = Array.prototype.slice.call(arguments)), n);
|
|
2061
1255
|
};
|
|
2062
1256
|
}
|
|
2063
|
-
function
|
|
1257
|
+
function we(e) {
|
|
2064
1258
|
return (
|
|
2065
1259
|
((2 === e.length || 3 === e.length) &&
|
|
2066
1260
|
('string' == typeof e[1] || 'symbol' == typeof e[1])) ||
|
|
@@ -2068,29 +1262,29 @@ function Ne(e) {
|
|
|
2068
1262
|
);
|
|
2069
1263
|
}
|
|
2070
1264
|
function _e(e, t, r) {
|
|
2071
|
-
return
|
|
1265
|
+
return Mt(e)
|
|
2072
1266
|
? e
|
|
2073
1267
|
: Array.isArray(e)
|
|
2074
|
-
?
|
|
1268
|
+
? Ue.array(e, { name: r })
|
|
2075
1269
|
: Y(e)
|
|
2076
|
-
?
|
|
1270
|
+
? Ue.object(e, void 0, { name: r })
|
|
2077
1271
|
: te(e)
|
|
2078
|
-
?
|
|
1272
|
+
? Ue.map(e, { name: r })
|
|
2079
1273
|
: re(e)
|
|
2080
|
-
?
|
|
1274
|
+
? Ue.set(e, { name: r })
|
|
2081
1275
|
: e;
|
|
2082
1276
|
}
|
|
2083
1277
|
function je(e) {
|
|
2084
1278
|
return e;
|
|
2085
1279
|
}
|
|
2086
|
-
function
|
|
1280
|
+
function xe(e) {
|
|
2087
1281
|
H(e);
|
|
2088
|
-
var t =
|
|
1282
|
+
var t = Ne(!0, function (t, r, n, o, i) {
|
|
2089
1283
|
'production' !== process.env.NODE_ENV &&
|
|
2090
1284
|
H(
|
|
2091
1285
|
!n || !n.get,
|
|
2092
1286
|
'@observable cannot be used on getter (property "' +
|
|
2093
|
-
|
|
1287
|
+
oe(r) +
|
|
2094
1288
|
'"), use @computed instead.',
|
|
2095
1289
|
);
|
|
2096
1290
|
var a = n ? (n.initializer ? n.initializer.call(t) : n.value) : void 0;
|
|
@@ -2110,45 +1304,45 @@ function Se(e) {
|
|
|
2110
1304
|
: t;
|
|
2111
1305
|
return (r.enhancer = e), r;
|
|
2112
1306
|
}
|
|
2113
|
-
var
|
|
2114
|
-
function
|
|
1307
|
+
var Se = { deep: !0, name: void 0, defaultDecorator: void 0, proxy: !0 };
|
|
1308
|
+
function De(e) {
|
|
2115
1309
|
/^(deep|name|equals|defaultDecorator|proxy)$/.test(e) ||
|
|
2116
1310
|
J('invalid option for (extend)observable: ' + e);
|
|
2117
1311
|
}
|
|
2118
|
-
function
|
|
2119
|
-
if (null == e) return
|
|
1312
|
+
function Ae(e) {
|
|
1313
|
+
if (null == e) return Se;
|
|
2120
1314
|
if ('string' == typeof e) return { name: e, deep: !0, proxy: !0 };
|
|
2121
1315
|
if ('production' !== process.env.NODE_ENV) {
|
|
2122
1316
|
if ('object' != typeof e) return J('expected options object');
|
|
2123
|
-
Object.keys(e).forEach(
|
|
1317
|
+
Object.keys(e).forEach(De);
|
|
2124
1318
|
}
|
|
2125
1319
|
return e;
|
|
2126
1320
|
}
|
|
2127
|
-
Object.freeze(
|
|
2128
|
-
var
|
|
2129
|
-
Te =
|
|
2130
|
-
return null == e || mr(e) ||
|
|
1321
|
+
Object.freeze(Se);
|
|
1322
|
+
var Ve = xe(_e),
|
|
1323
|
+
Te = xe(function (e, t, r) {
|
|
1324
|
+
return null == e || mr(e) || or(e) || ur(e) || lr(e)
|
|
2131
1325
|
? e
|
|
2132
1326
|
: Array.isArray(e)
|
|
2133
|
-
?
|
|
1327
|
+
? Ue.array(e, { name: r, deep: !1 })
|
|
2134
1328
|
: Y(e)
|
|
2135
|
-
?
|
|
1329
|
+
? Ue.object(e, void 0, { name: r, deep: !1 })
|
|
2136
1330
|
: te(e)
|
|
2137
|
-
?
|
|
1331
|
+
? Ue.map(e, { name: r, deep: !1 })
|
|
2138
1332
|
: re(e)
|
|
2139
|
-
?
|
|
1333
|
+
? Ue.set(e, { name: r, deep: !1 })
|
|
2140
1334
|
: J(
|
|
2141
1335
|
'production' !== process.env.NODE_ENV &&
|
|
2142
1336
|
'The shallow modifier / decorator can only used in combination with arrays, objects, maps and sets',
|
|
2143
1337
|
);
|
|
2144
1338
|
}),
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
if ('production' !== process.env.NODE_ENV &&
|
|
1339
|
+
ke = xe(je),
|
|
1340
|
+
Ce = xe(function (e, t, r) {
|
|
1341
|
+
if ('production' !== process.env.NODE_ENV && Mt(e))
|
|
2148
1342
|
throw 'observable.struct should not be used with observable values';
|
|
2149
1343
|
return _r(e, t) ? t : e;
|
|
2150
1344
|
});
|
|
2151
|
-
function
|
|
1345
|
+
function Re(e) {
|
|
2152
1346
|
return e.defaultDecorator
|
|
2153
1347
|
? e.defaultDecorator.enhancer
|
|
2154
1348
|
: !1 === e.deep
|
|
@@ -2157,73 +1351,73 @@ function ke(e) {
|
|
|
2157
1351
|
}
|
|
2158
1352
|
var Pe = {
|
|
2159
1353
|
box: function (e, t) {
|
|
2160
|
-
arguments.length > 2 &&
|
|
2161
|
-
var r =
|
|
2162
|
-
return new at(e,
|
|
1354
|
+
arguments.length > 2 && qe('box');
|
|
1355
|
+
var r = Ae(t);
|
|
1356
|
+
return new at(e, Re(r), r.name, !0, r.equals);
|
|
2163
1357
|
},
|
|
2164
1358
|
array: function (e, t) {
|
|
2165
|
-
arguments.length > 2 &&
|
|
2166
|
-
var r =
|
|
1359
|
+
arguments.length > 2 && qe('array');
|
|
1360
|
+
var r = Ae(t);
|
|
2167
1361
|
return (function (e, t, r, n) {
|
|
2168
|
-
void 0 === r && (r = 'ObservableArray@' +
|
|
1362
|
+
void 0 === r && (r = 'ObservableArray@' + F());
|
|
2169
1363
|
void 0 === n && (n = !1);
|
|
2170
|
-
var
|
|
2171
|
-
(
|
|
1364
|
+
var o = new er(r, t, n);
|
|
1365
|
+
(i = o.values),
|
|
2172
1366
|
(a = se),
|
|
2173
|
-
(s =
|
|
2174
|
-
Object.defineProperty(
|
|
1367
|
+
(s = o),
|
|
1368
|
+
Object.defineProperty(i, a, {
|
|
2175
1369
|
enumerable: !1,
|
|
2176
1370
|
writable: !1,
|
|
2177
1371
|
configurable: !0,
|
|
2178
1372
|
value: s,
|
|
2179
1373
|
});
|
|
2180
|
-
var
|
|
2181
|
-
var
|
|
2182
|
-
if (((
|
|
2183
|
-
var
|
|
2184
|
-
|
|
1374
|
+
var i, a, s;
|
|
1375
|
+
var u = new Proxy(o.values, Qt);
|
|
1376
|
+
if (((o.proxy = u), e && e.length)) {
|
|
1377
|
+
var c = ot(!0);
|
|
1378
|
+
o.spliceWithArray(0, 0, e), it(c);
|
|
2185
1379
|
}
|
|
2186
|
-
return
|
|
2187
|
-
})(e,
|
|
1380
|
+
return u;
|
|
1381
|
+
})(e, Re(r), r.name);
|
|
2188
1382
|
},
|
|
2189
1383
|
map: function (e, t) {
|
|
2190
|
-
arguments.length > 2 &&
|
|
2191
|
-
var r =
|
|
2192
|
-
return new sr(e,
|
|
1384
|
+
arguments.length > 2 && qe('map');
|
|
1385
|
+
var r = Ae(t);
|
|
1386
|
+
return new sr(e, Re(r), r.name);
|
|
2193
1387
|
},
|
|
2194
1388
|
set: function (e, t) {
|
|
2195
|
-
arguments.length > 2 &&
|
|
2196
|
-
var r =
|
|
2197
|
-
return new pr(e,
|
|
1389
|
+
arguments.length > 2 && qe('set');
|
|
1390
|
+
var r = Ae(t);
|
|
1391
|
+
return new pr(e, Re(r), r.name);
|
|
2198
1392
|
},
|
|
2199
1393
|
object: function (e, t, r) {
|
|
2200
|
-
'string' == typeof arguments[1] &&
|
|
2201
|
-
var n =
|
|
2202
|
-
if (!1 === n.proxy) return
|
|
2203
|
-
var
|
|
2204
|
-
|
|
1394
|
+
'string' == typeof arguments[1] && qe('object');
|
|
1395
|
+
var n = Ae(r);
|
|
1396
|
+
if (!1 === n.proxy) return Ut({}, e, t, n);
|
|
1397
|
+
var o = qt(n),
|
|
1398
|
+
i = (function (e) {
|
|
2205
1399
|
var t = new Proxy(e, Jt);
|
|
2206
1400
|
return (e[se].proxy = t), t;
|
|
2207
|
-
})(
|
|
2208
|
-
return
|
|
1401
|
+
})(Ut({}, void 0, void 0, n));
|
|
1402
|
+
return Lt(i, e, t, o), i;
|
|
2209
1403
|
},
|
|
2210
|
-
ref:
|
|
1404
|
+
ref: ke,
|
|
2211
1405
|
shallow: Te,
|
|
2212
|
-
deep:
|
|
2213
|
-
struct:
|
|
1406
|
+
deep: Ve,
|
|
1407
|
+
struct: Ce,
|
|
2214
1408
|
},
|
|
2215
|
-
|
|
1409
|
+
Ue = function (e, t, r) {
|
|
2216
1410
|
if ('string' == typeof arguments[1] || 'symbol' == typeof arguments[1])
|
|
2217
|
-
return
|
|
2218
|
-
if (
|
|
1411
|
+
return Ve.apply(null, arguments);
|
|
1412
|
+
if (Mt(e)) return e;
|
|
2219
1413
|
var n = Y(e)
|
|
2220
|
-
?
|
|
1414
|
+
? Ue.object(e, t, r)
|
|
2221
1415
|
: Array.isArray(e)
|
|
2222
|
-
?
|
|
1416
|
+
? Ue.array(e, t)
|
|
2223
1417
|
: te(e)
|
|
2224
|
-
?
|
|
1418
|
+
? Ue.map(e, t)
|
|
2225
1419
|
: re(e)
|
|
2226
|
-
?
|
|
1420
|
+
? Ue.set(e, t)
|
|
2227
1421
|
: e;
|
|
2228
1422
|
if (n !== e) return n;
|
|
2229
1423
|
J(
|
|
@@ -2231,7 +1425,7 @@ var Pe = {
|
|
|
2231
1425
|
"The provided value could not be converted into an observable. If you want just create an observable reference to the object use 'observable.box(value)'",
|
|
2232
1426
|
);
|
|
2233
1427
|
};
|
|
2234
|
-
function
|
|
1428
|
+
function qe(e) {
|
|
2235
1429
|
J(
|
|
2236
1430
|
'Expected one or two arguments to observable.' +
|
|
2237
1431
|
e +
|
|
@@ -2241,67 +1435,67 @@ function Me(e) {
|
|
|
2241
1435
|
);
|
|
2242
1436
|
}
|
|
2243
1437
|
Object.keys(Pe).forEach(function (e) {
|
|
2244
|
-
return (
|
|
1438
|
+
return (Ue[e] = Pe[e]);
|
|
2245
1439
|
});
|
|
2246
|
-
var
|
|
2247
|
-
|
|
2248
|
-
|
|
1440
|
+
var Le,
|
|
1441
|
+
Be,
|
|
1442
|
+
Ie = Ne(!1, function (e, t, r, n, o) {
|
|
2249
1443
|
'production' !== process.env.NODE_ENV &&
|
|
2250
1444
|
H(
|
|
2251
1445
|
r && r.get,
|
|
2252
1446
|
"Trying to declare a computed value for unspecified getter '" +
|
|
2253
|
-
|
|
1447
|
+
oe(t) +
|
|
2254
1448
|
"'",
|
|
2255
1449
|
);
|
|
2256
|
-
var
|
|
1450
|
+
var i = r.get,
|
|
2257
1451
|
a = r.set,
|
|
2258
|
-
s =
|
|
2259
|
-
fr(e).addComputedProp(e, t, fe({ get:
|
|
1452
|
+
s = o[0] || {};
|
|
1453
|
+
fr(e).addComputedProp(e, t, fe({ get: i, set: a, context: e }, s));
|
|
2260
1454
|
});
|
|
2261
|
-
|
|
1455
|
+
Ie({ equals: le.structural }),
|
|
2262
1456
|
(function (e) {
|
|
2263
1457
|
(e[(e.NOT_TRACKING = -1)] = 'NOT_TRACKING'),
|
|
2264
1458
|
(e[(e.UP_TO_DATE = 0)] = 'UP_TO_DATE'),
|
|
2265
1459
|
(e[(e.POSSIBLY_STALE = 1)] = 'POSSIBLY_STALE'),
|
|
2266
1460
|
(e[(e.STALE = 2)] = 'STALE');
|
|
2267
|
-
})(
|
|
1461
|
+
})(Le || (Le = {})),
|
|
2268
1462
|
(function (e) {
|
|
2269
1463
|
(e[(e.NONE = 0)] = 'NONE'),
|
|
2270
1464
|
(e[(e.LOG = 1)] = 'LOG'),
|
|
2271
1465
|
(e[(e.BREAK = 2)] = 'BREAK');
|
|
2272
|
-
})(
|
|
2273
|
-
var
|
|
1466
|
+
})(Be || (Be = {}));
|
|
1467
|
+
var Me = function (e) {
|
|
2274
1468
|
this.cause = e;
|
|
2275
1469
|
};
|
|
2276
|
-
function Fe(e) {
|
|
2277
|
-
return e instanceof qe;
|
|
2278
|
-
}
|
|
2279
1470
|
function Ge(e) {
|
|
1471
|
+
return e instanceof Me;
|
|
1472
|
+
}
|
|
1473
|
+
function ze(e) {
|
|
2280
1474
|
switch (e.dependenciesState) {
|
|
2281
|
-
case
|
|
1475
|
+
case Le.UP_TO_DATE:
|
|
2282
1476
|
return !1;
|
|
2283
|
-
case
|
|
2284
|
-
case
|
|
1477
|
+
case Le.NOT_TRACKING:
|
|
1478
|
+
case Le.STALE:
|
|
2285
1479
|
return !0;
|
|
2286
|
-
case
|
|
1480
|
+
case Le.POSSIBLY_STALE:
|
|
2287
1481
|
for (
|
|
2288
|
-
var t =
|
|
2289
|
-
|
|
2290
|
-
|
|
1482
|
+
var t = $e(!0), r = We(), n = e.observing, o = n.length, i = 0;
|
|
1483
|
+
i < o;
|
|
1484
|
+
i++
|
|
2291
1485
|
) {
|
|
2292
|
-
var a = n[
|
|
2293
|
-
if (
|
|
1486
|
+
var a = n[i];
|
|
1487
|
+
if (ut(a)) {
|
|
2294
1488
|
if (ft.disableErrorBoundaries) a.get();
|
|
2295
1489
|
else
|
|
2296
1490
|
try {
|
|
2297
1491
|
a.get();
|
|
2298
1492
|
} catch (e) {
|
|
2299
|
-
return
|
|
1493
|
+
return Xe(r), Ye(t), !0;
|
|
2300
1494
|
}
|
|
2301
|
-
if (e.dependenciesState ===
|
|
1495
|
+
if (e.dependenciesState === Le.STALE) return Xe(r), Ye(t), !0;
|
|
2302
1496
|
}
|
|
2303
1497
|
}
|
|
2304
|
-
return Ze(e),
|
|
1498
|
+
return Ze(e), Xe(r), Ye(t), !1;
|
|
2305
1499
|
}
|
|
2306
1500
|
}
|
|
2307
1501
|
function Ke(e) {
|
|
@@ -2323,48 +1517,48 @@ function Ke(e) {
|
|
|
2323
1517
|
e.name,
|
|
2324
1518
|
);
|
|
2325
1519
|
}
|
|
2326
|
-
function
|
|
2327
|
-
var n =
|
|
1520
|
+
function Fe(e, t, r) {
|
|
1521
|
+
var n = $e(!0);
|
|
2328
1522
|
Ze(e),
|
|
2329
1523
|
(e.newObserving = new Array(e.observing.length + 100)),
|
|
2330
1524
|
(e.unboundDepsCount = 0),
|
|
2331
1525
|
(e.runId = ++ft.runId);
|
|
2332
|
-
var
|
|
2333
|
-
|
|
1526
|
+
var o,
|
|
1527
|
+
i = ft.trackingDerivation;
|
|
2334
1528
|
if (((ft.trackingDerivation = e), !0 === ft.disableErrorBoundaries))
|
|
2335
|
-
|
|
1529
|
+
o = t.call(r);
|
|
2336
1530
|
else
|
|
2337
1531
|
try {
|
|
2338
|
-
|
|
1532
|
+
o = t.call(r);
|
|
2339
1533
|
} catch (e) {
|
|
2340
|
-
|
|
1534
|
+
o = new Me(e);
|
|
2341
1535
|
}
|
|
2342
1536
|
return (
|
|
2343
|
-
(ft.trackingDerivation =
|
|
1537
|
+
(ft.trackingDerivation = i),
|
|
2344
1538
|
(function (e) {
|
|
2345
1539
|
for (
|
|
2346
1540
|
var t = e.observing,
|
|
2347
1541
|
r = (e.observing = e.newObserving),
|
|
2348
|
-
n =
|
|
2349
|
-
|
|
2350
|
-
|
|
1542
|
+
n = Le.UP_TO_DATE,
|
|
1543
|
+
o = 0,
|
|
1544
|
+
i = e.unboundDepsCount,
|
|
2351
1545
|
a = 0;
|
|
2352
|
-
a <
|
|
1546
|
+
a < i;
|
|
2353
1547
|
a++
|
|
2354
1548
|
) {
|
|
2355
1549
|
0 === (s = r[a]).diffValue &&
|
|
2356
|
-
((s.diffValue = 1),
|
|
1550
|
+
((s.diffValue = 1), o !== a && (r[o] = s), o++),
|
|
2357
1551
|
s.dependenciesState > n && (n = s.dependenciesState);
|
|
2358
1552
|
}
|
|
2359
|
-
(r.length =
|
|
2360
|
-
for (; o--; ) {
|
|
2361
|
-
0 === (s = t[o]).diffValue && yt(s, e), (s.diffValue = 0);
|
|
2362
|
-
}
|
|
1553
|
+
(r.length = o), (e.newObserving = null), (i = t.length);
|
|
2363
1554
|
for (; i--; ) {
|
|
1555
|
+
0 === (s = t[i]).diffValue && vt(s, e), (s.diffValue = 0);
|
|
1556
|
+
}
|
|
1557
|
+
for (; o--; ) {
|
|
2364
1558
|
var s;
|
|
2365
|
-
1 === (s = r[
|
|
1559
|
+
1 === (s = r[o]).diffValue && ((s.diffValue = 0), ht(s, e));
|
|
2366
1560
|
}
|
|
2367
|
-
n !==
|
|
1561
|
+
n !== Le.UP_TO_DATE && ((e.dependenciesState = n), e.onBecomeStale());
|
|
2368
1562
|
})(e),
|
|
2369
1563
|
(function (e) {
|
|
2370
1564
|
if ('production' === process.env.NODE_ENV) return;
|
|
@@ -2377,31 +1571,31 @@ function ze(e, t, r) {
|
|
|
2377
1571
|
);
|
|
2378
1572
|
})(e),
|
|
2379
1573
|
Ye(n),
|
|
2380
|
-
|
|
1574
|
+
o
|
|
2381
1575
|
);
|
|
2382
1576
|
}
|
|
2383
1577
|
function Je(e) {
|
|
2384
1578
|
var t = e.observing;
|
|
2385
1579
|
e.observing = [];
|
|
2386
|
-
for (var r = t.length; r--; )
|
|
2387
|
-
e.dependenciesState =
|
|
1580
|
+
for (var r = t.length; r--; ) vt(t[r], e);
|
|
1581
|
+
e.dependenciesState = Le.NOT_TRACKING;
|
|
2388
1582
|
}
|
|
2389
1583
|
function He(e) {
|
|
2390
1584
|
var t = We();
|
|
2391
1585
|
try {
|
|
2392
1586
|
return e();
|
|
2393
1587
|
} finally {
|
|
2394
|
-
|
|
1588
|
+
Xe(t);
|
|
2395
1589
|
}
|
|
2396
1590
|
}
|
|
2397
1591
|
function We() {
|
|
2398
1592
|
var e = ft.trackingDerivation;
|
|
2399
1593
|
return (ft.trackingDerivation = null), e;
|
|
2400
1594
|
}
|
|
2401
|
-
function
|
|
1595
|
+
function Xe(e) {
|
|
2402
1596
|
ft.trackingDerivation = e;
|
|
2403
1597
|
}
|
|
2404
|
-
function
|
|
1598
|
+
function $e(e) {
|
|
2405
1599
|
var t = ft.allowStateReads;
|
|
2406
1600
|
return (ft.allowStateReads = e), t;
|
|
2407
1601
|
}
|
|
@@ -2409,10 +1603,10 @@ function Ye(e) {
|
|
|
2409
1603
|
ft.allowStateReads = e;
|
|
2410
1604
|
}
|
|
2411
1605
|
function Ze(e) {
|
|
2412
|
-
if (e.dependenciesState !==
|
|
2413
|
-
e.dependenciesState =
|
|
1606
|
+
if (e.dependenciesState !== Le.UP_TO_DATE) {
|
|
1607
|
+
e.dependenciesState = Le.UP_TO_DATE;
|
|
2414
1608
|
for (var t = e.observing, r = t.length; r--; )
|
|
2415
|
-
t[r].lowestObserverState =
|
|
1609
|
+
t[r].lowestObserverState = Le.UP_TO_DATE;
|
|
2416
1610
|
}
|
|
2417
1611
|
}
|
|
2418
1612
|
var Qe = 0,
|
|
@@ -2426,50 +1620,50 @@ function nt(e, t, r) {
|
|
|
2426
1620
|
J("actions should have valid names, got: '" + e + "'"));
|
|
2427
1621
|
var n = function () {
|
|
2428
1622
|
return (function (e, t, r, n) {
|
|
2429
|
-
var
|
|
2430
|
-
var n =
|
|
2431
|
-
|
|
1623
|
+
var o = (function (e, t, r) {
|
|
1624
|
+
var n = Dt() && !!e,
|
|
1625
|
+
o = 0;
|
|
2432
1626
|
if (n && 'production' !== process.env.NODE_ENV) {
|
|
2433
|
-
|
|
2434
|
-
var
|
|
2435
|
-
a = new Array(
|
|
2436
|
-
if (
|
|
2437
|
-
|
|
1627
|
+
o = Date.now();
|
|
1628
|
+
var i = (r && r.length) || 0,
|
|
1629
|
+
a = new Array(i);
|
|
1630
|
+
if (i > 0) for (var s = 0; s < i; s++) a[s] = r[s];
|
|
1631
|
+
Vt({ type: 'action', name: e, object: t, arguments: a });
|
|
2438
1632
|
}
|
|
2439
|
-
var
|
|
1633
|
+
var u = We();
|
|
2440
1634
|
bt();
|
|
2441
|
-
var
|
|
2442
|
-
p =
|
|
2443
|
-
|
|
2444
|
-
prevDerivation:
|
|
2445
|
-
prevAllowStateChanges:
|
|
1635
|
+
var c = ot(!0),
|
|
1636
|
+
p = $e(!0),
|
|
1637
|
+
l = {
|
|
1638
|
+
prevDerivation: u,
|
|
1639
|
+
prevAllowStateChanges: c,
|
|
2446
1640
|
prevAllowStateReads: p,
|
|
2447
1641
|
notifySpy: n,
|
|
2448
|
-
startTime:
|
|
1642
|
+
startTime: o,
|
|
2449
1643
|
actionId: et++,
|
|
2450
1644
|
parentActionId: Qe,
|
|
2451
1645
|
};
|
|
2452
|
-
return (Qe =
|
|
1646
|
+
return (Qe = l.actionId), l;
|
|
2453
1647
|
})(e, r, n);
|
|
2454
1648
|
try {
|
|
2455
1649
|
return t.apply(r, n);
|
|
2456
1650
|
} catch (e) {
|
|
2457
|
-
throw ((
|
|
1651
|
+
throw ((o.error = e), e);
|
|
2458
1652
|
} finally {
|
|
2459
1653
|
!(function (e) {
|
|
2460
1654
|
Qe !== e.actionId &&
|
|
2461
1655
|
J('invalid action stack. did you forget to finish an action?');
|
|
2462
1656
|
(Qe = e.parentActionId),
|
|
2463
1657
|
void 0 !== e.error && (ft.suppressReactionErrors = !0);
|
|
2464
|
-
|
|
1658
|
+
it(e.prevAllowStateChanges),
|
|
2465
1659
|
Ye(e.prevAllowStateReads),
|
|
2466
1660
|
mt(),
|
|
2467
|
-
|
|
1661
|
+
Xe(e.prevDerivation),
|
|
2468
1662
|
e.notifySpy &&
|
|
2469
1663
|
'production' !== process.env.NODE_ENV &&
|
|
2470
|
-
|
|
1664
|
+
kt({ time: Date.now() - e.startTime });
|
|
2471
1665
|
ft.suppressReactionErrors = !1;
|
|
2472
|
-
})(
|
|
1666
|
+
})(o);
|
|
2473
1667
|
}
|
|
2474
1668
|
})(e, t, r || this, arguments);
|
|
2475
1669
|
};
|
|
@@ -2481,29 +1675,29 @@ function nt(e, t, r) {
|
|
|
2481
1675
|
n
|
|
2482
1676
|
);
|
|
2483
1677
|
}
|
|
2484
|
-
function
|
|
1678
|
+
function ot(e) {
|
|
2485
1679
|
var t = ft.allowStateChanges;
|
|
2486
1680
|
return (ft.allowStateChanges = e), t;
|
|
2487
1681
|
}
|
|
2488
|
-
function
|
|
1682
|
+
function it(e) {
|
|
2489
1683
|
ft.allowStateChanges = e;
|
|
2490
1684
|
}
|
|
2491
1685
|
var at = (function (e) {
|
|
2492
|
-
function t(t, r, n,
|
|
2493
|
-
void 0 === n && (n = 'ObservableValue@' +
|
|
2494
|
-
void 0 ===
|
|
2495
|
-
void 0 ===
|
|
1686
|
+
function t(t, r, n, o, i) {
|
|
1687
|
+
void 0 === n && (n = 'ObservableValue@' + F()),
|
|
1688
|
+
void 0 === o && (o = !0),
|
|
1689
|
+
void 0 === i && (i = le.default);
|
|
2496
1690
|
var a = e.call(this, n) || this;
|
|
2497
1691
|
return (
|
|
2498
1692
|
(a.enhancer = r),
|
|
2499
1693
|
(a.name = n),
|
|
2500
|
-
(a.equals =
|
|
1694
|
+
(a.equals = i),
|
|
2501
1695
|
(a.hasUnreportedChange = !1),
|
|
2502
1696
|
(a.value = r(t, void 0, n)),
|
|
2503
|
-
|
|
2504
|
-
|
|
1697
|
+
o &&
|
|
1698
|
+
Dt() &&
|
|
2505
1699
|
'production' !== process.env.NODE_ENV &&
|
|
2506
|
-
|
|
1700
|
+
At({ type: 'create', name: a.name, newValue: '' + a.value }),
|
|
2507
1701
|
a
|
|
2508
1702
|
);
|
|
2509
1703
|
}
|
|
@@ -2524,17 +1718,17 @@ var at = (function (e) {
|
|
|
2524
1718
|
(t.prototype.set = function (e) {
|
|
2525
1719
|
var t = this.value;
|
|
2526
1720
|
if ((e = this.prepareNewValue(e)) !== ft.UNCHANGED) {
|
|
2527
|
-
var r =
|
|
1721
|
+
var r = Dt();
|
|
2528
1722
|
r &&
|
|
2529
1723
|
'production' !== process.env.NODE_ENV &&
|
|
2530
|
-
|
|
1724
|
+
Vt({ type: 'update', name: this.name, newValue: e, oldValue: t }),
|
|
2531
1725
|
this.setNewValue(e),
|
|
2532
|
-
r && 'production' !== process.env.NODE_ENV &&
|
|
1726
|
+
r && 'production' !== process.env.NODE_ENV && kt();
|
|
2533
1727
|
}
|
|
2534
1728
|
}),
|
|
2535
1729
|
(t.prototype.prepareNewValue = function (e) {
|
|
2536
1730
|
if ((Ke(this), Ht(this))) {
|
|
2537
|
-
var t =
|
|
1731
|
+
var t = Xt(this, { object: this, type: 'update', newValue: e });
|
|
2538
1732
|
if (!t) return ft.UNCHANGED;
|
|
2539
1733
|
e = t.newValue;
|
|
2540
1734
|
}
|
|
@@ -2547,7 +1741,7 @@ var at = (function (e) {
|
|
|
2547
1741
|
var t = this.value;
|
|
2548
1742
|
(this.value = e),
|
|
2549
1743
|
this.reportChanged(),
|
|
2550
|
-
|
|
1744
|
+
$t(this) &&
|
|
2551
1745
|
Zt(this, { type: 'update', object: this, newValue: e, oldValue: t });
|
|
2552
1746
|
}),
|
|
2553
1747
|
(t.prototype.get = function () {
|
|
@@ -2575,18 +1769,18 @@ var at = (function (e) {
|
|
|
2575
1769
|
return this.name + '[' + this.value + ']';
|
|
2576
1770
|
}),
|
|
2577
1771
|
(t.prototype.valueOf = function () {
|
|
2578
|
-
return
|
|
1772
|
+
return ie(this.get());
|
|
2579
1773
|
}),
|
|
2580
1774
|
(t.prototype[Symbol.toPrimitive] = function () {
|
|
2581
1775
|
return this.valueOf();
|
|
2582
1776
|
}),
|
|
2583
1777
|
t
|
|
2584
1778
|
);
|
|
2585
|
-
})(
|
|
1779
|
+
})(ue);
|
|
2586
1780
|
ee('ObservableValue', at);
|
|
2587
1781
|
var st = (function () {
|
|
2588
1782
|
function e(e) {
|
|
2589
|
-
(this.dependenciesState =
|
|
1783
|
+
(this.dependenciesState = Le.NOT_TRACKING),
|
|
2590
1784
|
(this.observing = []),
|
|
2591
1785
|
(this.newObserving = null),
|
|
2592
1786
|
(this.isBeingObserved = !1),
|
|
@@ -2595,20 +1789,20 @@ var st = (function () {
|
|
|
2595
1789
|
(this.diffValue = 0),
|
|
2596
1790
|
(this.runId = 0),
|
|
2597
1791
|
(this.lastAccessedBy = 0),
|
|
2598
|
-
(this.lowestObserverState =
|
|
1792
|
+
(this.lowestObserverState = Le.UP_TO_DATE),
|
|
2599
1793
|
(this.unboundDepsCount = 0),
|
|
2600
|
-
(this.__mapid = '#' +
|
|
2601
|
-
(this.value = new
|
|
1794
|
+
(this.__mapid = '#' + F()),
|
|
1795
|
+
(this.value = new Me(null)),
|
|
2602
1796
|
(this.isComputing = !1),
|
|
2603
1797
|
(this.isRunningSetter = !1),
|
|
2604
|
-
(this.isTracing =
|
|
1798
|
+
(this.isTracing = Be.NONE),
|
|
2605
1799
|
H(e.get, 'missing option for computed: get'),
|
|
2606
1800
|
(this.derivation = e.get),
|
|
2607
|
-
(this.name = e.name || 'ComputedValue@' +
|
|
1801
|
+
(this.name = e.name || 'ComputedValue@' + F()),
|
|
2608
1802
|
e.set && (this.setter = nt(this.name + '-setter', e.set)),
|
|
2609
1803
|
(this.equals =
|
|
2610
1804
|
e.equals ||
|
|
2611
|
-
(e.compareStructural || e.struct ?
|
|
1805
|
+
(e.compareStructural || e.struct ? le.structural : le.default)),
|
|
2612
1806
|
(this.scope = e.context),
|
|
2613
1807
|
(this.requiresReaction = !!e.requiresReaction),
|
|
2614
1808
|
(this.keepAlive = !!e.keepAlive);
|
|
@@ -2616,12 +1810,12 @@ var st = (function () {
|
|
|
2616
1810
|
return (
|
|
2617
1811
|
(e.prototype.onBecomeStale = function () {
|
|
2618
1812
|
!(function (e) {
|
|
2619
|
-
if (e.lowestObserverState !==
|
|
2620
|
-
(e.lowestObserverState =
|
|
1813
|
+
if (e.lowestObserverState !== Le.UP_TO_DATE) return;
|
|
1814
|
+
(e.lowestObserverState = Le.POSSIBLY_STALE),
|
|
2621
1815
|
e.observers.forEach(function (t) {
|
|
2622
|
-
t.dependenciesState ===
|
|
2623
|
-
((t.dependenciesState =
|
|
2624
|
-
t.isTracing !==
|
|
1816
|
+
t.dependenciesState === Le.UP_TO_DATE &&
|
|
1817
|
+
((t.dependenciesState = Le.POSSIBLY_STALE),
|
|
1818
|
+
t.isTracing !== Be.NONE && Ot(t, e),
|
|
2625
1819
|
t.onBecomeStale());
|
|
2626
1820
|
});
|
|
2627
1821
|
})(this);
|
|
@@ -2648,30 +1842,30 @@ var st = (function () {
|
|
|
2648
1842
|
),
|
|
2649
1843
|
0 !== ft.inBatch || 0 !== this.observers.size || this.keepAlive
|
|
2650
1844
|
? (gt(this),
|
|
2651
|
-
|
|
1845
|
+
ze(this) &&
|
|
2652
1846
|
this.trackAndCompute() &&
|
|
2653
1847
|
(function (e) {
|
|
2654
|
-
if (e.lowestObserverState ===
|
|
2655
|
-
(e.lowestObserverState =
|
|
1848
|
+
if (e.lowestObserverState === Le.STALE) return;
|
|
1849
|
+
(e.lowestObserverState = Le.STALE),
|
|
2656
1850
|
e.observers.forEach(function (t) {
|
|
2657
|
-
t.dependenciesState ===
|
|
2658
|
-
? (t.dependenciesState =
|
|
2659
|
-
: t.dependenciesState ===
|
|
2660
|
-
(e.lowestObserverState =
|
|
1851
|
+
t.dependenciesState === Le.POSSIBLY_STALE
|
|
1852
|
+
? (t.dependenciesState = Le.STALE)
|
|
1853
|
+
: t.dependenciesState === Le.UP_TO_DATE &&
|
|
1854
|
+
(e.lowestObserverState = Le.UP_TO_DATE);
|
|
2661
1855
|
});
|
|
2662
1856
|
})(this))
|
|
2663
|
-
:
|
|
1857
|
+
: ze(this) &&
|
|
2664
1858
|
(this.warnAboutUntrackedRead(),
|
|
2665
1859
|
bt(),
|
|
2666
1860
|
(this.value = this.computeValue(!1)),
|
|
2667
1861
|
mt());
|
|
2668
1862
|
var e = this.value;
|
|
2669
|
-
if (
|
|
1863
|
+
if (Ge(e)) throw e.cause;
|
|
2670
1864
|
return e;
|
|
2671
1865
|
}),
|
|
2672
1866
|
(e.prototype.peek = function () {
|
|
2673
1867
|
var e = this.computeValue(!1);
|
|
2674
|
-
if (
|
|
1868
|
+
if (Ge(e)) throw e.cause;
|
|
2675
1869
|
return e;
|
|
2676
1870
|
}),
|
|
2677
1871
|
(e.prototype.set = function (e) {
|
|
@@ -2698,26 +1892,26 @@ var st = (function () {
|
|
|
2698
1892
|
);
|
|
2699
1893
|
}),
|
|
2700
1894
|
(e.prototype.trackAndCompute = function () {
|
|
2701
|
-
|
|
1895
|
+
Dt() &&
|
|
2702
1896
|
'production' !== process.env.NODE_ENV &&
|
|
2703
|
-
|
|
1897
|
+
At({ object: this.scope, type: 'compute', name: this.name });
|
|
2704
1898
|
var e = this.value,
|
|
2705
|
-
t = this.dependenciesState ===
|
|
1899
|
+
t = this.dependenciesState === Le.NOT_TRACKING,
|
|
2706
1900
|
r = this.computeValue(!0),
|
|
2707
|
-
n = t ||
|
|
1901
|
+
n = t || Ge(e) || Ge(r) || !this.equals(e, r);
|
|
2708
1902
|
return n && (this.value = r), n;
|
|
2709
1903
|
}),
|
|
2710
1904
|
(e.prototype.computeValue = function (e) {
|
|
2711
1905
|
var t;
|
|
2712
1906
|
if (((this.isComputing = !0), ft.computationDepth++, e))
|
|
2713
|
-
t =
|
|
1907
|
+
t = Fe(this, this.derivation, this.scope);
|
|
2714
1908
|
else if (!0 === ft.disableErrorBoundaries)
|
|
2715
1909
|
t = this.derivation.call(this.scope);
|
|
2716
1910
|
else
|
|
2717
1911
|
try {
|
|
2718
1912
|
t = this.derivation.call(this.scope);
|
|
2719
1913
|
} catch (e) {
|
|
2720
|
-
t = new
|
|
1914
|
+
t = new Me(e);
|
|
2721
1915
|
}
|
|
2722
1916
|
return ft.computationDepth--, (this.isComputing = !1), t;
|
|
2723
1917
|
}),
|
|
@@ -2727,7 +1921,7 @@ var st = (function () {
|
|
|
2727
1921
|
(e.prototype.observe = function (e, t) {
|
|
2728
1922
|
var r = this,
|
|
2729
1923
|
n = !0,
|
|
2730
|
-
|
|
1924
|
+
o = void 0;
|
|
2731
1925
|
return (function (e, t) {
|
|
2732
1926
|
void 0 === t && (t = K);
|
|
2733
1927
|
'production' !== process.env.NODE_ENV &&
|
|
@@ -2741,24 +1935,24 @@ var st = (function () {
|
|
|
2741
1935
|
));
|
|
2742
1936
|
var r;
|
|
2743
1937
|
var n,
|
|
2744
|
-
|
|
1938
|
+
o = (t && t.name) || e.name || 'Autorun@' + F();
|
|
2745
1939
|
if (t.scheduler || t.delay) {
|
|
2746
|
-
var
|
|
1940
|
+
var i = (function (e) {
|
|
2747
1941
|
return e.scheduler
|
|
2748
1942
|
? e.scheduler
|
|
2749
1943
|
: e.delay
|
|
2750
1944
|
? function (t) {
|
|
2751
1945
|
return setTimeout(t, e.delay);
|
|
2752
1946
|
}
|
|
2753
|
-
:
|
|
1947
|
+
: Ct;
|
|
2754
1948
|
})(t),
|
|
2755
1949
|
a = !1;
|
|
2756
|
-
n = new
|
|
2757
|
-
|
|
1950
|
+
n = new Nt(
|
|
1951
|
+
o,
|
|
2758
1952
|
function () {
|
|
2759
1953
|
a ||
|
|
2760
1954
|
((a = !0),
|
|
2761
|
-
|
|
1955
|
+
i(function () {
|
|
2762
1956
|
(a = !1), n.isDisposed || n.track(s);
|
|
2763
1957
|
}));
|
|
2764
1958
|
},
|
|
@@ -2766,8 +1960,8 @@ var st = (function () {
|
|
|
2766
1960
|
t.requiresObservable,
|
|
2767
1961
|
);
|
|
2768
1962
|
} else
|
|
2769
|
-
n = new
|
|
2770
|
-
|
|
1963
|
+
n = new Nt(
|
|
1964
|
+
o,
|
|
2771
1965
|
function () {
|
|
2772
1966
|
this.track(s);
|
|
2773
1967
|
},
|
|
@@ -2779,12 +1973,12 @@ var st = (function () {
|
|
|
2779
1973
|
}
|
|
2780
1974
|
return n.schedule(), n.getDisposer();
|
|
2781
1975
|
})(function () {
|
|
2782
|
-
var
|
|
1976
|
+
var i = r.get();
|
|
2783
1977
|
if (!n || t) {
|
|
2784
1978
|
var a = We();
|
|
2785
|
-
e({ type: 'update', object: r, newValue:
|
|
1979
|
+
e({ type: 'update', object: r, newValue: i, oldValue: o }), Xe(a);
|
|
2786
1980
|
}
|
|
2787
|
-
(n = !1), (
|
|
1981
|
+
(n = !1), (o = i);
|
|
2788
1982
|
});
|
|
2789
1983
|
}),
|
|
2790
1984
|
(e.prototype.warnAboutUntrackedRead = function () {
|
|
@@ -2795,7 +1989,7 @@ var st = (function () {
|
|
|
2795
1989
|
this.name +
|
|
2796
1990
|
' is read outside a reactive context',
|
|
2797
1991
|
),
|
|
2798
|
-
this.isTracing !==
|
|
1992
|
+
this.isTracing !== Be.NONE &&
|
|
2799
1993
|
console.log(
|
|
2800
1994
|
"[mobx.trace] '" +
|
|
2801
1995
|
this.name +
|
|
@@ -2815,7 +2009,7 @@ var st = (function () {
|
|
|
2815
2009
|
return this.name + '[' + this.derivation.toString() + ']';
|
|
2816
2010
|
}),
|
|
2817
2011
|
(e.prototype.valueOf = function () {
|
|
2818
|
-
return
|
|
2012
|
+
return ie(this.get());
|
|
2819
2013
|
}),
|
|
2820
2014
|
(e.prototype[Symbol.toPrimitive] = function () {
|
|
2821
2015
|
return this.valueOf();
|
|
@@ -2823,8 +2017,8 @@ var st = (function () {
|
|
|
2823
2017
|
e
|
|
2824
2018
|
);
|
|
2825
2019
|
})(),
|
|
2826
|
-
|
|
2827
|
-
|
|
2020
|
+
ut = ee('ComputedValue', st),
|
|
2021
|
+
ct = function () {
|
|
2828
2022
|
(this.version = 5),
|
|
2829
2023
|
(this.UNCHANGED = {}),
|
|
2830
2024
|
(this.trackingDerivation = null),
|
|
@@ -2848,7 +2042,7 @@ var st = (function () {
|
|
|
2848
2042
|
(this.suppressReactionErrors = !1);
|
|
2849
2043
|
},
|
|
2850
2044
|
pt = {};
|
|
2851
|
-
function
|
|
2045
|
+
function lt() {
|
|
2852
2046
|
return 'undefined' != typeof window
|
|
2853
2047
|
? window
|
|
2854
2048
|
: 'undefined' != typeof global
|
|
@@ -2859,35 +2053,35 @@ function ct() {
|
|
|
2859
2053
|
}
|
|
2860
2054
|
var dt = !0,
|
|
2861
2055
|
ft = (function () {
|
|
2862
|
-
var e =
|
|
2056
|
+
var e = lt();
|
|
2863
2057
|
return (
|
|
2864
2058
|
e.__mobxInstanceCount > 0 && !e.__mobxGlobals && (dt = !1),
|
|
2865
2059
|
e.__mobxGlobals &&
|
|
2866
|
-
e.__mobxGlobals.version !== new
|
|
2060
|
+
e.__mobxGlobals.version !== new ct().version &&
|
|
2867
2061
|
(dt = !1),
|
|
2868
2062
|
dt
|
|
2869
2063
|
? e.__mobxGlobals
|
|
2870
2064
|
? ((e.__mobxInstanceCount += 1),
|
|
2871
2065
|
e.__mobxGlobals.UNCHANGED || (e.__mobxGlobals.UNCHANGED = {}),
|
|
2872
2066
|
e.__mobxGlobals)
|
|
2873
|
-
: ((e.__mobxInstanceCount = 1), (e.__mobxGlobals = new
|
|
2067
|
+
: ((e.__mobxInstanceCount = 1), (e.__mobxGlobals = new ct()))
|
|
2874
2068
|
: (setTimeout(function () {
|
|
2875
2069
|
J(
|
|
2876
2070
|
'There are multiple, different versions of MobX active. Make sure MobX is loaded only once or use `configure({ isolateGlobalState: true })`',
|
|
2877
2071
|
);
|
|
2878
2072
|
}, 1),
|
|
2879
|
-
new
|
|
2073
|
+
new ct())
|
|
2880
2074
|
);
|
|
2881
2075
|
})();
|
|
2882
|
-
function
|
|
2076
|
+
function ht(e, t) {
|
|
2883
2077
|
e.observers.add(t),
|
|
2884
2078
|
e.lowestObserverState > t.dependenciesState &&
|
|
2885
2079
|
(e.lowestObserverState = t.dependenciesState);
|
|
2886
2080
|
}
|
|
2887
|
-
function
|
|
2888
|
-
e.observers.delete(t), 0 === e.observers.size &&
|
|
2081
|
+
function vt(e, t) {
|
|
2082
|
+
e.observers.delete(t), 0 === e.observers.size && yt(e);
|
|
2889
2083
|
}
|
|
2890
|
-
function
|
|
2084
|
+
function yt(e) {
|
|
2891
2085
|
!1 === e.isPendingUnobservation &&
|
|
2892
2086
|
((e.isPendingUnobservation = !0), ft.pendingUnobservations.push(e));
|
|
2893
2087
|
}
|
|
@@ -2895,7 +2089,7 @@ function bt() {
|
|
|
2895
2089
|
ft.inBatch++;
|
|
2896
2090
|
}
|
|
2897
2091
|
function mt() {
|
|
2898
|
-
if (0
|
|
2092
|
+
if (0 === --ft.inBatch) {
|
|
2899
2093
|
jt();
|
|
2900
2094
|
for (var e = ft.pendingUnobservations, t = 0; t < e.length; t++) {
|
|
2901
2095
|
var r = e[t];
|
|
@@ -2926,7 +2120,7 @@ function gt(e) {
|
|
|
2926
2120
|
(t.newObserving[t.unboundDepsCount++] = e),
|
|
2927
2121
|
e.isBeingObserved || ((e.isBeingObserved = !0), e.onBecomeObserved())),
|
|
2928
2122
|
!0)
|
|
2929
|
-
: (0 === e.observers.size && ft.inBatch > 0 &&
|
|
2123
|
+
: (0 === e.observers.size && ft.inBatch > 0 && yt(e), !1);
|
|
2930
2124
|
}
|
|
2931
2125
|
function Ot(e, t) {
|
|
2932
2126
|
if (
|
|
@@ -2937,10 +2131,10 @@ function Ot(e, t) {
|
|
|
2937
2131
|
t.name +
|
|
2938
2132
|
"'",
|
|
2939
2133
|
),
|
|
2940
|
-
e.isTracing ===
|
|
2134
|
+
e.isTracing === Be.BREAK)
|
|
2941
2135
|
) {
|
|
2942
2136
|
var r = [];
|
|
2943
|
-
|
|
2137
|
+
Et(Bt(gr(e, n)), r, 1),
|
|
2944
2138
|
new Function(
|
|
2945
2139
|
"debugger;\n/*\nTracing '" +
|
|
2946
2140
|
e.name +
|
|
@@ -2959,18 +2153,18 @@ function Ot(e, t) {
|
|
|
2959
2153
|
}
|
|
2960
2154
|
var n;
|
|
2961
2155
|
}
|
|
2962
|
-
function
|
|
2156
|
+
function Et(e, t, r) {
|
|
2963
2157
|
t.length >= 1e3
|
|
2964
2158
|
? t.push('(and many more)')
|
|
2965
2159
|
: (t.push('' + new Array(r).join('\t') + e.name),
|
|
2966
2160
|
e.dependencies &&
|
|
2967
2161
|
e.dependencies.forEach(function (e) {
|
|
2968
|
-
return
|
|
2162
|
+
return Et(e, t, r + 1);
|
|
2969
2163
|
}));
|
|
2970
2164
|
}
|
|
2971
|
-
var
|
|
2165
|
+
var Nt = (function () {
|
|
2972
2166
|
function e(e, t, r, n) {
|
|
2973
|
-
void 0 === e && (e = 'Reaction@' +
|
|
2167
|
+
void 0 === e && (e = 'Reaction@' + F()),
|
|
2974
2168
|
void 0 === n && (n = !1),
|
|
2975
2169
|
(this.name = e),
|
|
2976
2170
|
(this.onInvalidate = t),
|
|
@@ -2978,16 +2172,16 @@ var Et = (function () {
|
|
|
2978
2172
|
(this.requiresObservable = n),
|
|
2979
2173
|
(this.observing = []),
|
|
2980
2174
|
(this.newObserving = []),
|
|
2981
|
-
(this.dependenciesState =
|
|
2175
|
+
(this.dependenciesState = Le.NOT_TRACKING),
|
|
2982
2176
|
(this.diffValue = 0),
|
|
2983
2177
|
(this.runId = 0),
|
|
2984
2178
|
(this.unboundDepsCount = 0),
|
|
2985
|
-
(this.__mapid = '#' +
|
|
2179
|
+
(this.__mapid = '#' + F()),
|
|
2986
2180
|
(this.isDisposed = !1),
|
|
2987
2181
|
(this._isScheduled = !1),
|
|
2988
2182
|
(this._isTrackPending = !1),
|
|
2989
2183
|
(this._isRunning = !1),
|
|
2990
|
-
(this.isTracing =
|
|
2184
|
+
(this.isTracing = Be.NONE);
|
|
2991
2185
|
}
|
|
2992
2186
|
return (
|
|
2993
2187
|
(e.prototype.onBecomeStale = function () {
|
|
@@ -3002,14 +2196,14 @@ var Et = (function () {
|
|
|
3002
2196
|
}),
|
|
3003
2197
|
(e.prototype.runReaction = function () {
|
|
3004
2198
|
if (!this.isDisposed) {
|
|
3005
|
-
if ((bt(), (this._isScheduled = !1),
|
|
2199
|
+
if ((bt(), (this._isScheduled = !1), ze(this))) {
|
|
3006
2200
|
this._isTrackPending = !0;
|
|
3007
2201
|
try {
|
|
3008
2202
|
this.onInvalidate(),
|
|
3009
2203
|
this._isTrackPending &&
|
|
3010
|
-
|
|
2204
|
+
Dt() &&
|
|
3011
2205
|
'production' !== process.env.NODE_ENV &&
|
|
3012
|
-
|
|
2206
|
+
At({ name: this.name, type: 'scheduled-reaction' });
|
|
3013
2207
|
} catch (e) {
|
|
3014
2208
|
this.reportExceptionInDerivation(e);
|
|
3015
2209
|
}
|
|
@@ -3021,19 +2215,19 @@ var Et = (function () {
|
|
|
3021
2215
|
if (!this.isDisposed) {
|
|
3022
2216
|
bt();
|
|
3023
2217
|
var t,
|
|
3024
|
-
r =
|
|
2218
|
+
r = Dt();
|
|
3025
2219
|
r &&
|
|
3026
2220
|
'production' !== process.env.NODE_ENV &&
|
|
3027
|
-
((t = Date.now()),
|
|
2221
|
+
((t = Date.now()), Vt({ name: this.name, type: 'reaction' })),
|
|
3028
2222
|
(this._isRunning = !0);
|
|
3029
|
-
var n =
|
|
2223
|
+
var n = Fe(this, e, void 0);
|
|
3030
2224
|
(this._isRunning = !1),
|
|
3031
2225
|
(this._isTrackPending = !1),
|
|
3032
2226
|
this.isDisposed && Je(this),
|
|
3033
|
-
|
|
2227
|
+
Ge(n) && this.reportExceptionInDerivation(n.cause),
|
|
3034
2228
|
r &&
|
|
3035
2229
|
'production' !== process.env.NODE_ENV &&
|
|
3036
|
-
|
|
2230
|
+
kt({ time: Date.now() - t }),
|
|
3037
2231
|
mt();
|
|
3038
2232
|
}
|
|
3039
2233
|
}),
|
|
@@ -3053,8 +2247,8 @@ var Et = (function () {
|
|
|
3053
2247
|
"' suppressed, fix error of causing action below)",
|
|
3054
2248
|
)
|
|
3055
2249
|
: console.error(r, e),
|
|
3056
|
-
|
|
3057
|
-
|
|
2250
|
+
Dt() &&
|
|
2251
|
+
At({ type: 'error', name: this.name, message: r, error: '' + e }),
|
|
3058
2252
|
ft.globalReactionErrorHandlers.forEach(function (r) {
|
|
3059
2253
|
return r(e, t);
|
|
3060
2254
|
});
|
|
@@ -3093,78 +2287,78 @@ var Et = (function () {
|
|
|
3093
2287
|
'production' !== process.env.NODE_ENV &&
|
|
3094
2288
|
"'trace(break?)' can only be used inside a tracked computed value or a Reaction. Consider passing in the computed value or reaction explicitly",
|
|
3095
2289
|
);
|
|
3096
|
-
n.isTracing ===
|
|
2290
|
+
n.isTracing === Be.NONE &&
|
|
3097
2291
|
console.log("[mobx.trace] '" + n.name + "' tracing enabled");
|
|
3098
|
-
n.isTracing = r ?
|
|
2292
|
+
n.isTracing = r ? Be.BREAK : Be.LOG;
|
|
3099
2293
|
})(this, e);
|
|
3100
2294
|
}),
|
|
3101
2295
|
e
|
|
3102
2296
|
);
|
|
3103
2297
|
})(),
|
|
3104
|
-
|
|
2298
|
+
wt = 100,
|
|
3105
2299
|
_t = function (e) {
|
|
3106
2300
|
return e();
|
|
3107
2301
|
};
|
|
3108
2302
|
function jt() {
|
|
3109
|
-
ft.inBatch > 0 || ft.isRunningReactions || _t(
|
|
2303
|
+
ft.inBatch > 0 || ft.isRunningReactions || _t(xt);
|
|
3110
2304
|
}
|
|
3111
|
-
function
|
|
2305
|
+
function xt() {
|
|
3112
2306
|
ft.isRunningReactions = !0;
|
|
3113
2307
|
for (var e = ft.pendingReactions, t = 0; e.length > 0; ) {
|
|
3114
|
-
++t ===
|
|
2308
|
+
++t === wt &&
|
|
3115
2309
|
(console.error(
|
|
3116
2310
|
"Reaction doesn't converge to a stable state after " +
|
|
3117
|
-
|
|
2311
|
+
wt +
|
|
3118
2312
|
' iterations. Probably there is a cycle in the reactive function: ' +
|
|
3119
2313
|
e[0],
|
|
3120
2314
|
),
|
|
3121
2315
|
e.splice(0));
|
|
3122
|
-
for (var r = e.splice(0), n = 0,
|
|
2316
|
+
for (var r = e.splice(0), n = 0, o = r.length; n < o; n++)
|
|
3123
2317
|
r[n].runReaction();
|
|
3124
2318
|
}
|
|
3125
2319
|
ft.isRunningReactions = !1;
|
|
3126
2320
|
}
|
|
3127
|
-
var
|
|
3128
|
-
function
|
|
2321
|
+
var St = ee('Reaction', Nt);
|
|
2322
|
+
function Dt() {
|
|
3129
2323
|
return 'production' !== process.env.NODE_ENV && !!ft.spyListeners.length;
|
|
3130
2324
|
}
|
|
3131
|
-
function
|
|
2325
|
+
function At(e) {
|
|
3132
2326
|
if ('production' !== process.env.NODE_ENV && ft.spyListeners.length)
|
|
3133
2327
|
for (var t = ft.spyListeners, r = 0, n = t.length; r < n; r++) t[r](e);
|
|
3134
2328
|
}
|
|
3135
|
-
function
|
|
2329
|
+
function Vt(e) {
|
|
3136
2330
|
'production' !== process.env.NODE_ENV &&
|
|
3137
|
-
|
|
2331
|
+
At(fe(fe({}, e), { spyReportStart: !0 }));
|
|
3138
2332
|
}
|
|
3139
2333
|
var Tt = { spyReportEnd: !0 };
|
|
3140
|
-
function
|
|
2334
|
+
function kt(e) {
|
|
3141
2335
|
'production' !== process.env.NODE_ENV &&
|
|
3142
|
-
|
|
2336
|
+
At(e ? fe(fe({}, e), { spyReportEnd: !0 }) : Tt);
|
|
3143
2337
|
}
|
|
3144
|
-
var
|
|
2338
|
+
var Ct = function (e) {
|
|
3145
2339
|
return e();
|
|
3146
2340
|
};
|
|
3147
|
-
function
|
|
2341
|
+
function Rt(e, t, r) {
|
|
3148
2342
|
return Pt('onBecomeUnobserved', e, t, r);
|
|
3149
2343
|
}
|
|
3150
2344
|
function Pt(e, t, r, n) {
|
|
3151
|
-
var
|
|
3152
|
-
|
|
2345
|
+
var o = 'function' == typeof n ? gr(t, r) : gr(t),
|
|
2346
|
+
i = 'function' == typeof n ? n : r,
|
|
3153
2347
|
a = e + 'Listeners';
|
|
3154
2348
|
return (
|
|
3155
|
-
|
|
3156
|
-
'function' != typeof
|
|
2349
|
+
o[a] ? o[a].add(i) : (o[a] = new Set([i])),
|
|
2350
|
+
'function' != typeof o[e]
|
|
3157
2351
|
? J(
|
|
3158
2352
|
'production' !== process.env.NODE_ENV &&
|
|
3159
2353
|
'Not an atom that can be (un)observed',
|
|
3160
2354
|
)
|
|
3161
2355
|
: function () {
|
|
3162
|
-
var e =
|
|
3163
|
-
e && (e.delete(
|
|
2356
|
+
var e = o[a];
|
|
2357
|
+
e && (e.delete(i), 0 === e.size && delete o[a]);
|
|
3164
2358
|
}
|
|
3165
2359
|
);
|
|
3166
2360
|
}
|
|
3167
|
-
function
|
|
2361
|
+
function Ut(e, t, r, n) {
|
|
3168
2362
|
'production' !== process.env.NODE_ENV &&
|
|
3169
2363
|
(H(
|
|
3170
2364
|
arguments.length >= 2 && arguments.length <= 4,
|
|
@@ -3175,73 +2369,73 @@ function It(e, t, r, n) {
|
|
|
3175
2369
|
"'extendObservable' expects an object as first argument",
|
|
3176
2370
|
),
|
|
3177
2371
|
H(
|
|
3178
|
-
!
|
|
2372
|
+
!ur(e),
|
|
3179
2373
|
"'extendObservable' should not be used on maps, use map.merge instead",
|
|
3180
2374
|
));
|
|
3181
|
-
var
|
|
3182
|
-
return
|
|
2375
|
+
var o = qt((n = Ae(n)));
|
|
2376
|
+
return Ee(e), fr(e, n.name, o.enhancer), t && Lt(e, t, r, o), e;
|
|
3183
2377
|
}
|
|
3184
|
-
function
|
|
3185
|
-
return e.defaultDecorator || (!1 === e.deep ?
|
|
2378
|
+
function qt(e) {
|
|
2379
|
+
return e.defaultDecorator || (!1 === e.deep ? ke : Ve);
|
|
3186
2380
|
}
|
|
3187
|
-
function
|
|
3188
|
-
var
|
|
2381
|
+
function Lt(e, t, r, n) {
|
|
2382
|
+
var o, i, a, s;
|
|
3189
2383
|
if (
|
|
3190
2384
|
'production' !== process.env.NODE_ENV &&
|
|
3191
2385
|
(H(
|
|
3192
|
-
!
|
|
2386
|
+
!Mt(t),
|
|
3193
2387
|
'Extending an object with another observable (object) is not supported. Please construct an explicit propertymap, using `toJS` if need. See issue #540',
|
|
3194
2388
|
),
|
|
3195
2389
|
r)
|
|
3196
2390
|
) {
|
|
3197
|
-
var
|
|
2391
|
+
var u = ne(r);
|
|
3198
2392
|
try {
|
|
3199
|
-
for (var
|
|
2393
|
+
for (var c = he(u), p = c.next(); !p.done; p = c.next()) {
|
|
3200
2394
|
(f = p.value) in t ||
|
|
3201
2395
|
J(
|
|
3202
2396
|
"Trying to declare a decorator for unspecified property '" +
|
|
3203
|
-
|
|
2397
|
+
oe(f) +
|
|
3204
2398
|
"'",
|
|
3205
2399
|
);
|
|
3206
2400
|
}
|
|
3207
2401
|
} catch (e) {
|
|
3208
|
-
|
|
2402
|
+
o = { error: e };
|
|
3209
2403
|
} finally {
|
|
3210
2404
|
try {
|
|
3211
|
-
p && !p.done && (
|
|
2405
|
+
p && !p.done && (i = c.return) && i.call(c);
|
|
3212
2406
|
} finally {
|
|
3213
|
-
if (
|
|
2407
|
+
if (o) throw o.error;
|
|
3214
2408
|
}
|
|
3215
2409
|
}
|
|
3216
2410
|
}
|
|
3217
2411
|
bt();
|
|
3218
2412
|
try {
|
|
3219
|
-
|
|
2413
|
+
u = ae(t);
|
|
3220
2414
|
try {
|
|
3221
|
-
for (var
|
|
2415
|
+
for (var l = he(u), d = l.next(); !d.done; d = l.next()) {
|
|
3222
2416
|
var f = d.value,
|
|
3223
|
-
|
|
2417
|
+
h = Object.getOwnPropertyDescriptor(t, f);
|
|
3224
2418
|
'production' !== process.env.NODE_ENV &&
|
|
3225
2419
|
(Y(t) ||
|
|
3226
2420
|
J(
|
|
3227
2421
|
"'extendObservable' only accepts plain objects as second argument",
|
|
3228
2422
|
),
|
|
3229
|
-
|
|
2423
|
+
It(h.value) &&
|
|
3230
2424
|
J(
|
|
3231
2425
|
"Passing a 'computed' as initial property value is no longer supported by extendObservable. Use a getter or decorator instead",
|
|
3232
2426
|
));
|
|
3233
|
-
var
|
|
2427
|
+
var v = r && f in r ? r[f] : h.get ? Ie : n;
|
|
3234
2428
|
'production' !== process.env.NODE_ENV &&
|
|
3235
|
-
'function' != typeof
|
|
3236
|
-
J("Not a valid decorator for '" +
|
|
3237
|
-
var
|
|
3238
|
-
|
|
2429
|
+
'function' != typeof v &&
|
|
2430
|
+
J("Not a valid decorator for '" + oe(f) + "', got: " + v);
|
|
2431
|
+
var y = v(e, f, h, !0);
|
|
2432
|
+
y && Object.defineProperty(e, f, y);
|
|
3239
2433
|
}
|
|
3240
2434
|
} catch (e) {
|
|
3241
2435
|
a = { error: e };
|
|
3242
2436
|
} finally {
|
|
3243
2437
|
try {
|
|
3244
|
-
d && !d.done && (s =
|
|
2438
|
+
d && !d.done && (s = l.return) && s.call(l);
|
|
3245
2439
|
} finally {
|
|
3246
2440
|
if (a) throw a.error;
|
|
3247
2441
|
}
|
|
@@ -3250,7 +2444,7 @@ function Bt(e, t, r, n) {
|
|
|
3250
2444
|
mt();
|
|
3251
2445
|
}
|
|
3252
2446
|
}
|
|
3253
|
-
function
|
|
2447
|
+
function Bt(e) {
|
|
3254
2448
|
var t,
|
|
3255
2449
|
r,
|
|
3256
2450
|
n = { name: e.name };
|
|
@@ -3262,11 +2456,11 @@ function Lt(e) {
|
|
|
3262
2456
|
t.forEach(function (e) {
|
|
3263
2457
|
-1 === r.indexOf(e) && r.push(e);
|
|
3264
2458
|
}),
|
|
3265
|
-
r).map(
|
|
2459
|
+
r).map(Bt)),
|
|
3266
2460
|
n
|
|
3267
2461
|
);
|
|
3268
2462
|
}
|
|
3269
|
-
function
|
|
2463
|
+
function It(e) {
|
|
3270
2464
|
return arguments.length > 1
|
|
3271
2465
|
? J(
|
|
3272
2466
|
'production' !== process.env.NODE_ENV &&
|
|
@@ -3278,12 +2472,12 @@ function Ut(e) {
|
|
|
3278
2472
|
if (!1 === mr(e)) return !1;
|
|
3279
2473
|
if (!e[se].values.has(t)) return !1;
|
|
3280
2474
|
var r = gr(e, t);
|
|
3281
|
-
return
|
|
2475
|
+
return ut(r);
|
|
3282
2476
|
}
|
|
3283
|
-
return
|
|
2477
|
+
return ut(e);
|
|
3284
2478
|
})(e);
|
|
3285
2479
|
}
|
|
3286
|
-
function
|
|
2480
|
+
function Mt(e) {
|
|
3287
2481
|
return (
|
|
3288
2482
|
1 !== arguments.length &&
|
|
3289
2483
|
J(
|
|
@@ -3294,27 +2488,27 @@ function qt(e) {
|
|
|
3294
2488
|
return (
|
|
3295
2489
|
null != e &&
|
|
3296
2490
|
(void 0 !== t
|
|
3297
|
-
? 'production' !== process.env.NODE_ENV && (
|
|
2491
|
+
? 'production' !== process.env.NODE_ENV && (ur(e) || or(e))
|
|
3298
2492
|
? J(
|
|
3299
2493
|
'isObservable(object, propertyName) is not supported for arrays and maps. Use map.has or array.length instead.',
|
|
3300
2494
|
)
|
|
3301
2495
|
: !!mr(e) && e[se].values.has(t)
|
|
3302
|
-
: mr(e) || !!e[se] ||
|
|
2496
|
+
: mr(e) || !!e[se] || ce(e) || St(e) || ut(e))
|
|
3303
2497
|
);
|
|
3304
2498
|
})(e)
|
|
3305
2499
|
);
|
|
3306
2500
|
}
|
|
3307
|
-
function
|
|
3308
|
-
if (2 !== arguments.length ||
|
|
2501
|
+
function Gt(e, t, r) {
|
|
2502
|
+
if (2 !== arguments.length || lr(e))
|
|
3309
2503
|
if (mr(e)) {
|
|
3310
2504
|
var n = e[se];
|
|
3311
2505
|
n.values.get(t)
|
|
3312
2506
|
? n.write(t, r)
|
|
3313
2507
|
: n.addObservableProp(t, r, n.defaultEnhancer);
|
|
3314
|
-
} else if (
|
|
3315
|
-
else if (
|
|
2508
|
+
} else if (ur(e)) e.set(t, r);
|
|
2509
|
+
else if (lr(e)) e.add(t);
|
|
3316
2510
|
else {
|
|
3317
|
-
if (!
|
|
2511
|
+
if (!or(e))
|
|
3318
2512
|
return J(
|
|
3319
2513
|
'production' !== process.env.NODE_ENV &&
|
|
3320
2514
|
"'set()' can only be used on observable objects, arrays and maps",
|
|
@@ -3328,15 +2522,15 @@ function Ft(e, t, r) {
|
|
|
3328
2522
|
}
|
|
3329
2523
|
else {
|
|
3330
2524
|
bt();
|
|
3331
|
-
var
|
|
2525
|
+
var o = t;
|
|
3332
2526
|
try {
|
|
3333
|
-
for (var
|
|
2527
|
+
for (var i in o) Gt(e, i, o[i]);
|
|
3334
2528
|
} finally {
|
|
3335
2529
|
mt();
|
|
3336
2530
|
}
|
|
3337
2531
|
}
|
|
3338
2532
|
}
|
|
3339
|
-
function
|
|
2533
|
+
function zt(e, t) {
|
|
3340
2534
|
void 0 === t && (t = void 0), bt();
|
|
3341
2535
|
try {
|
|
3342
2536
|
return e.apply(t);
|
|
@@ -3347,30 +2541,30 @@ function Gt(e, t) {
|
|
|
3347
2541
|
function Kt(e) {
|
|
3348
2542
|
return e[se];
|
|
3349
2543
|
}
|
|
3350
|
-
function
|
|
2544
|
+
function Ft(e) {
|
|
3351
2545
|
return 'string' == typeof e || 'number' == typeof e || 'symbol' == typeof e;
|
|
3352
2546
|
}
|
|
3353
2547
|
var Jt = {
|
|
3354
2548
|
has: function (e, t) {
|
|
3355
2549
|
if (t === se || 'constructor' === t || t === be) return !0;
|
|
3356
2550
|
var r = Kt(e);
|
|
3357
|
-
return
|
|
2551
|
+
return Ft(t) ? r.has(t) : t in e;
|
|
3358
2552
|
},
|
|
3359
2553
|
get: function (e, t) {
|
|
3360
2554
|
if (t === se || 'constructor' === t || t === be) return e[t];
|
|
3361
2555
|
var r = Kt(e),
|
|
3362
2556
|
n = r.values.get(t);
|
|
3363
|
-
if (n instanceof
|
|
3364
|
-
var
|
|
3365
|
-
return void 0 ===
|
|
2557
|
+
if (n instanceof ue) {
|
|
2558
|
+
var o = n.get();
|
|
2559
|
+
return void 0 === o && r.has(t), o;
|
|
3366
2560
|
}
|
|
3367
|
-
return
|
|
2561
|
+
return Ft(t) && r.has(t), e[t];
|
|
3368
2562
|
},
|
|
3369
2563
|
set: function (e, t, r) {
|
|
3370
|
-
return !!
|
|
2564
|
+
return !!Ft(t) && (Gt(e, t, r), !0);
|
|
3371
2565
|
},
|
|
3372
2566
|
deleteProperty: function (e, t) {
|
|
3373
|
-
return !!
|
|
2567
|
+
return !!Ft(t) && (Kt(e).remove(t), !0);
|
|
3374
2568
|
},
|
|
3375
2569
|
ownKeys: function (e) {
|
|
3376
2570
|
return Kt(e).keysAtom.reportObserved(), Reflect.ownKeys(e);
|
|
@@ -3392,25 +2586,25 @@ function Wt(e, t) {
|
|
|
3392
2586
|
})
|
|
3393
2587
|
);
|
|
3394
2588
|
}
|
|
3395
|
-
function
|
|
2589
|
+
function Xt(e, t) {
|
|
3396
2590
|
var r = We();
|
|
3397
2591
|
try {
|
|
3398
2592
|
for (
|
|
3399
|
-
var n =
|
|
3400
|
-
|
|
2593
|
+
var n = ye(e.interceptors || []), o = 0, i = n.length;
|
|
2594
|
+
o < i &&
|
|
3401
2595
|
(H(
|
|
3402
|
-
!(t = n[
|
|
2596
|
+
!(t = n[o](t)) || t.type,
|
|
3403
2597
|
'Intercept handlers should return nothing or a change object',
|
|
3404
2598
|
),
|
|
3405
2599
|
t);
|
|
3406
|
-
|
|
2600
|
+
o++
|
|
3407
2601
|
);
|
|
3408
2602
|
return t;
|
|
3409
2603
|
} finally {
|
|
3410
|
-
|
|
2604
|
+
Xe(r);
|
|
3411
2605
|
}
|
|
3412
2606
|
}
|
|
3413
|
-
function
|
|
2607
|
+
function $t(e) {
|
|
3414
2608
|
return void 0 !== e.changeListeners && e.changeListeners.length > 0;
|
|
3415
2609
|
}
|
|
3416
2610
|
function Yt(e, t) {
|
|
@@ -3427,8 +2621,8 @@ function Zt(e, t) {
|
|
|
3427
2621
|
var r = We(),
|
|
3428
2622
|
n = e.changeListeners;
|
|
3429
2623
|
if (n) {
|
|
3430
|
-
for (var
|
|
3431
|
-
|
|
2624
|
+
for (var o = 0, i = (n = n.slice()).length; o < i; o++) n[o](t);
|
|
2625
|
+
Xe(r);
|
|
3432
2626
|
}
|
|
3433
2627
|
}
|
|
3434
2628
|
var Qt = {
|
|
@@ -3465,7 +2659,7 @@ var er = (function () {
|
|
|
3465
2659
|
(this.values = []),
|
|
3466
2660
|
(this.proxy = void 0),
|
|
3467
2661
|
(this.lastKnownLength = 0),
|
|
3468
|
-
(this.atom = new
|
|
2662
|
+
(this.atom = new ue(e || 'ObservableArray@' + F())),
|
|
3469
2663
|
(this.enhancer = function (r, n) {
|
|
3470
2664
|
return t(r, n, e + '[..]');
|
|
3471
2665
|
});
|
|
@@ -3521,31 +2715,31 @@ var er = (function () {
|
|
|
3521
2715
|
(e.prototype.spliceWithArray = function (e, t, r) {
|
|
3522
2716
|
var n = this;
|
|
3523
2717
|
Ke(this.atom);
|
|
3524
|
-
var
|
|
2718
|
+
var o = this.values.length;
|
|
3525
2719
|
if (
|
|
3526
2720
|
(void 0 === e
|
|
3527
2721
|
? (e = 0)
|
|
3528
|
-
: e >
|
|
3529
|
-
? (e =
|
|
3530
|
-
: e < 0 && (e = Math.max(0,
|
|
2722
|
+
: e > o
|
|
2723
|
+
? (e = o)
|
|
2724
|
+
: e < 0 && (e = Math.max(0, o + e)),
|
|
3531
2725
|
(t =
|
|
3532
2726
|
1 === arguments.length
|
|
3533
|
-
?
|
|
2727
|
+
? o - e
|
|
3534
2728
|
: null == t
|
|
3535
2729
|
? 0
|
|
3536
|
-
: Math.max(0, Math.min(t,
|
|
3537
|
-
void 0 === r && (r =
|
|
2730
|
+
: Math.max(0, Math.min(t, o - e))),
|
|
2731
|
+
void 0 === r && (r = z),
|
|
3538
2732
|
Ht(this))
|
|
3539
2733
|
) {
|
|
3540
|
-
var
|
|
2734
|
+
var i = Xt(this, {
|
|
3541
2735
|
object: this.proxy,
|
|
3542
2736
|
type: 'splice',
|
|
3543
2737
|
index: e,
|
|
3544
2738
|
removedCount: t,
|
|
3545
2739
|
added: r,
|
|
3546
2740
|
});
|
|
3547
|
-
if (!
|
|
3548
|
-
(t =
|
|
2741
|
+
if (!i) return z;
|
|
2742
|
+
(t = i.removedCount), (r = i.added);
|
|
3549
2743
|
}
|
|
3550
2744
|
if (
|
|
3551
2745
|
((r =
|
|
@@ -3557,7 +2751,7 @@ var er = (function () {
|
|
|
3557
2751
|
'production' !== process.env.NODE_ENV)
|
|
3558
2752
|
) {
|
|
3559
2753
|
var a = r.length - t;
|
|
3560
|
-
this.updateArrayLength(
|
|
2754
|
+
this.updateArrayLength(o, a);
|
|
3561
2755
|
}
|
|
3562
2756
|
var s = this.spliceItemsIntoValues(e, t, r);
|
|
3563
2757
|
return (
|
|
@@ -3568,20 +2762,20 @@ var er = (function () {
|
|
|
3568
2762
|
(e.prototype.spliceItemsIntoValues = function (e, t, r) {
|
|
3569
2763
|
var n;
|
|
3570
2764
|
if (r.length < 1e4)
|
|
3571
|
-
return (n = this.values).splice.apply(n,
|
|
3572
|
-
var
|
|
2765
|
+
return (n = this.values).splice.apply(n, ye([e, t], r));
|
|
2766
|
+
var o = this.values.slice(e, e + t);
|
|
3573
2767
|
return (
|
|
3574
2768
|
(this.values = this.values
|
|
3575
2769
|
.slice(0, e)
|
|
3576
2770
|
.concat(r, this.values.slice(e + t))),
|
|
3577
|
-
|
|
2771
|
+
o
|
|
3578
2772
|
);
|
|
3579
2773
|
}),
|
|
3580
2774
|
(e.prototype.notifyArrayChildUpdate = function (e, t, r) {
|
|
3581
|
-
var n = !this.owned &&
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
2775
|
+
var n = !this.owned && Dt(),
|
|
2776
|
+
o = $t(this),
|
|
2777
|
+
i =
|
|
2778
|
+
o || n
|
|
3585
2779
|
? {
|
|
3586
2780
|
object: this.proxy,
|
|
3587
2781
|
type: 'update',
|
|
@@ -3592,16 +2786,16 @@ var er = (function () {
|
|
|
3592
2786
|
: null;
|
|
3593
2787
|
n &&
|
|
3594
2788
|
'production' !== process.env.NODE_ENV &&
|
|
3595
|
-
|
|
2789
|
+
Vt(fe(fe({}, i), { name: this.atom.name })),
|
|
3596
2790
|
this.atom.reportChanged(),
|
|
3597
|
-
|
|
3598
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
2791
|
+
o && Zt(this, i),
|
|
2792
|
+
n && 'production' !== process.env.NODE_ENV && kt();
|
|
3599
2793
|
}),
|
|
3600
2794
|
(e.prototype.notifyArraySplice = function (e, t, r) {
|
|
3601
|
-
var n = !this.owned &&
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
2795
|
+
var n = !this.owned && Dt(),
|
|
2796
|
+
o = $t(this),
|
|
2797
|
+
i =
|
|
2798
|
+
o || n
|
|
3605
2799
|
? {
|
|
3606
2800
|
object: this.proxy,
|
|
3607
2801
|
type: 'splice',
|
|
@@ -3614,10 +2808,10 @@ var er = (function () {
|
|
|
3614
2808
|
: null;
|
|
3615
2809
|
n &&
|
|
3616
2810
|
'production' !== process.env.NODE_ENV &&
|
|
3617
|
-
|
|
2811
|
+
Vt(fe(fe({}, i), { name: this.atom.name })),
|
|
3618
2812
|
this.atom.reportChanged(),
|
|
3619
|
-
|
|
3620
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
2813
|
+
o && Zt(this, i),
|
|
2814
|
+
n && 'production' !== process.env.NODE_ENV && kt();
|
|
3621
2815
|
}),
|
|
3622
2816
|
e
|
|
3623
2817
|
);
|
|
@@ -3645,16 +2839,16 @@ var er = (function () {
|
|
|
3645
2839
|
splice: function (e, t) {
|
|
3646
2840
|
for (var r = [], n = 2; n < arguments.length; n++)
|
|
3647
2841
|
r[n - 2] = arguments[n];
|
|
3648
|
-
var
|
|
2842
|
+
var o = this[se];
|
|
3649
2843
|
switch (arguments.length) {
|
|
3650
2844
|
case 0:
|
|
3651
2845
|
return [];
|
|
3652
2846
|
case 1:
|
|
3653
|
-
return
|
|
2847
|
+
return o.spliceWithArray(e);
|
|
3654
2848
|
case 2:
|
|
3655
|
-
return
|
|
2849
|
+
return o.spliceWithArray(e, t);
|
|
3656
2850
|
}
|
|
3657
|
-
return
|
|
2851
|
+
return o.spliceWithArray(e, t, r);
|
|
3658
2852
|
},
|
|
3659
2853
|
spliceWithArray: function (e, t, r) {
|
|
3660
2854
|
return this[se].spliceWithArray(e, t, r);
|
|
@@ -3715,19 +2909,19 @@ var er = (function () {
|
|
|
3715
2909
|
n = r.values;
|
|
3716
2910
|
if (e < n.length) {
|
|
3717
2911
|
Ke(r.atom);
|
|
3718
|
-
var
|
|
2912
|
+
var o = n[e];
|
|
3719
2913
|
if (Ht(r)) {
|
|
3720
|
-
var
|
|
2914
|
+
var i = Xt(r, {
|
|
3721
2915
|
type: 'update',
|
|
3722
2916
|
object: r.proxy,
|
|
3723
2917
|
index: e,
|
|
3724
2918
|
newValue: t,
|
|
3725
2919
|
});
|
|
3726
|
-
if (!
|
|
3727
|
-
t =
|
|
2920
|
+
if (!i) return;
|
|
2921
|
+
t = i.newValue;
|
|
3728
2922
|
}
|
|
3729
|
-
(t = r.enhancer(t,
|
|
3730
|
-
((n[e] = t), r.notifyArrayChildUpdate(e, t,
|
|
2923
|
+
(t = r.enhancer(t, o)) !== o &&
|
|
2924
|
+
((n[e] = t), r.notifyArrayChildUpdate(e, t, o));
|
|
3731
2925
|
} else {
|
|
3732
2926
|
if (e !== n.length)
|
|
3733
2927
|
throw new Error(
|
|
@@ -3772,11 +2966,11 @@ var er = (function () {
|
|
|
3772
2966
|
'function' == typeof Array.prototype[e] &&
|
|
3773
2967
|
(tr[e] = function (t, r) {
|
|
3774
2968
|
var n = this,
|
|
3775
|
-
|
|
2969
|
+
o = this[se];
|
|
3776
2970
|
return (
|
|
3777
|
-
|
|
3778
|
-
|
|
3779
|
-
return t.call(r, e,
|
|
2971
|
+
o.atom.reportObserved(),
|
|
2972
|
+
o.dehanceValues(o.values)[e](function (e, o) {
|
|
2973
|
+
return t.call(r, e, o, n);
|
|
3780
2974
|
}, r)
|
|
3781
2975
|
);
|
|
3782
2976
|
});
|
|
@@ -3788,8 +2982,8 @@ var er = (function () {
|
|
|
3788
2982
|
r.atom.reportObserved();
|
|
3789
2983
|
var n = arguments[0];
|
|
3790
2984
|
return (
|
|
3791
|
-
(arguments[0] = function (e,
|
|
3792
|
-
return (
|
|
2985
|
+
(arguments[0] = function (e, o, i) {
|
|
2986
|
+
return (o = r.dehanceValue(o)), n(e, o, i, t);
|
|
3793
2987
|
}),
|
|
3794
2988
|
r.values[e].apply(r.values, arguments)
|
|
3795
2989
|
);
|
|
@@ -3797,16 +2991,16 @@ var er = (function () {
|
|
|
3797
2991
|
});
|
|
3798
2992
|
var rr,
|
|
3799
2993
|
nr = ee('ObservableArrayAdministration', er);
|
|
3800
|
-
function
|
|
3801
|
-
return
|
|
2994
|
+
function or(e) {
|
|
2995
|
+
return $(e) && nr(e[se]);
|
|
3802
2996
|
}
|
|
3803
|
-
var
|
|
2997
|
+
var ir,
|
|
3804
2998
|
ar = {},
|
|
3805
2999
|
sr = (function () {
|
|
3806
3000
|
function e(e, t, r) {
|
|
3807
3001
|
if (
|
|
3808
3002
|
(void 0 === t && (t = _e),
|
|
3809
|
-
void 0 === r && (r = 'ObservableMap@' +
|
|
3003
|
+
void 0 === r && (r = 'ObservableMap@' + F()),
|
|
3810
3004
|
(this.enhancer = t),
|
|
3811
3005
|
(this.name = r),
|
|
3812
3006
|
(this[rr] = ar),
|
|
@@ -3831,11 +3025,11 @@ var or,
|
|
|
3831
3025
|
var n = (r = new at(
|
|
3832
3026
|
this._has(e),
|
|
3833
3027
|
je,
|
|
3834
|
-
this.name + '.' +
|
|
3028
|
+
this.name + '.' + oe(e) + '?',
|
|
3835
3029
|
!1,
|
|
3836
3030
|
));
|
|
3837
3031
|
this._hasMap.set(e, n),
|
|
3838
|
-
|
|
3032
|
+
Rt(n, function () {
|
|
3839
3033
|
return t._hasMap.delete(e);
|
|
3840
3034
|
});
|
|
3841
3035
|
}
|
|
@@ -3844,7 +3038,7 @@ var or,
|
|
|
3844
3038
|
(e.prototype.set = function (e, t) {
|
|
3845
3039
|
var r = this._has(e);
|
|
3846
3040
|
if (Ht(this)) {
|
|
3847
|
-
var n =
|
|
3041
|
+
var n = Xt(this, {
|
|
3848
3042
|
type: r ? 'update' : 'add',
|
|
3849
3043
|
object: this,
|
|
3850
3044
|
newValue: t,
|
|
@@ -3859,13 +3053,13 @@ var or,
|
|
|
3859
3053
|
var t = this;
|
|
3860
3054
|
if (
|
|
3861
3055
|
(Ke(this._keysAtom), Ht(this)) &&
|
|
3862
|
-
!(
|
|
3056
|
+
!(o = Xt(this, { type: 'delete', object: this, name: e }))
|
|
3863
3057
|
)
|
|
3864
3058
|
return !1;
|
|
3865
3059
|
if (this._has(e)) {
|
|
3866
|
-
var r =
|
|
3867
|
-
n =
|
|
3868
|
-
|
|
3060
|
+
var r = Dt(),
|
|
3061
|
+
n = $t(this),
|
|
3062
|
+
o =
|
|
3869
3063
|
n || r
|
|
3870
3064
|
? {
|
|
3871
3065
|
type: 'delete',
|
|
@@ -3877,15 +3071,15 @@ var or,
|
|
|
3877
3071
|
return (
|
|
3878
3072
|
r &&
|
|
3879
3073
|
'production' !== process.env.NODE_ENV &&
|
|
3880
|
-
|
|
3881
|
-
|
|
3074
|
+
Vt(fe(fe({}, o), { name: this.name, key: e })),
|
|
3075
|
+
zt(function () {
|
|
3882
3076
|
t._keysAtom.reportChanged(),
|
|
3883
3077
|
t._updateHasMapEntry(e, !1),
|
|
3884
3078
|
t._data.get(e).setNewValue(void 0),
|
|
3885
3079
|
t._data.delete(e);
|
|
3886
3080
|
}),
|
|
3887
|
-
n && Zt(this,
|
|
3888
|
-
r && 'production' !== process.env.NODE_ENV &&
|
|
3081
|
+
n && Zt(this, o),
|
|
3082
|
+
r && 'production' !== process.env.NODE_ENV && kt(),
|
|
3889
3083
|
!0
|
|
3890
3084
|
);
|
|
3891
3085
|
}
|
|
@@ -3898,10 +3092,10 @@ var or,
|
|
|
3898
3092
|
(e.prototype._updateValue = function (e, t) {
|
|
3899
3093
|
var r = this._data.get(e);
|
|
3900
3094
|
if ((t = r.prepareNewValue(t)) !== ft.UNCHANGED) {
|
|
3901
|
-
var n =
|
|
3902
|
-
|
|
3903
|
-
|
|
3904
|
-
|
|
3095
|
+
var n = Dt(),
|
|
3096
|
+
o = $t(this),
|
|
3097
|
+
i =
|
|
3098
|
+
o || n
|
|
3905
3099
|
? {
|
|
3906
3100
|
type: 'update',
|
|
3907
3101
|
object: this,
|
|
@@ -3912,31 +3106,31 @@ var or,
|
|
|
3912
3106
|
: null;
|
|
3913
3107
|
n &&
|
|
3914
3108
|
'production' !== process.env.NODE_ENV &&
|
|
3915
|
-
|
|
3109
|
+
Vt(fe(fe({}, i), { name: this.name, key: e })),
|
|
3916
3110
|
r.setNewValue(t),
|
|
3917
|
-
|
|
3918
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
3111
|
+
o && Zt(this, i),
|
|
3112
|
+
n && 'production' !== process.env.NODE_ENV && kt();
|
|
3919
3113
|
}
|
|
3920
3114
|
}),
|
|
3921
3115
|
(e.prototype._addValue = function (e, t) {
|
|
3922
3116
|
var r = this;
|
|
3923
3117
|
Ke(this._keysAtom),
|
|
3924
|
-
|
|
3925
|
-
var n = new at(t, r.enhancer, r.name + '.' +
|
|
3118
|
+
zt(function () {
|
|
3119
|
+
var n = new at(t, r.enhancer, r.name + '.' + oe(e), !1);
|
|
3926
3120
|
r._data.set(e, n),
|
|
3927
3121
|
(t = n.value),
|
|
3928
3122
|
r._updateHasMapEntry(e, !0),
|
|
3929
3123
|
r._keysAtom.reportChanged();
|
|
3930
3124
|
});
|
|
3931
|
-
var n =
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3125
|
+
var n = Dt(),
|
|
3126
|
+
o = $t(this),
|
|
3127
|
+
i =
|
|
3128
|
+
o || n ? { type: 'add', object: this, name: e, newValue: t } : null;
|
|
3935
3129
|
n &&
|
|
3936
3130
|
'production' !== process.env.NODE_ENV &&
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
3131
|
+
Vt(fe(fe({}, i), { name: this.name, key: e })),
|
|
3132
|
+
o && Zt(this, i),
|
|
3133
|
+
n && 'production' !== process.env.NODE_ENV && kt();
|
|
3940
3134
|
}),
|
|
3941
3135
|
(e.prototype.get = function (e) {
|
|
3942
3136
|
return this.has(e)
|
|
@@ -3952,24 +3146,24 @@ var or,
|
|
|
3952
3146
|
(e.prototype.values = function () {
|
|
3953
3147
|
var e = this,
|
|
3954
3148
|
t = this.keys();
|
|
3955
|
-
return
|
|
3149
|
+
return Dr({
|
|
3956
3150
|
next: function () {
|
|
3957
3151
|
var r = t.next(),
|
|
3958
3152
|
n = r.done,
|
|
3959
|
-
|
|
3960
|
-
return { done: n, value: n ? void 0 : e.get(
|
|
3153
|
+
o = r.value;
|
|
3154
|
+
return { done: n, value: n ? void 0 : e.get(o) };
|
|
3961
3155
|
},
|
|
3962
3156
|
});
|
|
3963
3157
|
}),
|
|
3964
3158
|
(e.prototype.entries = function () {
|
|
3965
3159
|
var e = this,
|
|
3966
3160
|
t = this.keys();
|
|
3967
|
-
return
|
|
3161
|
+
return Dr({
|
|
3968
3162
|
next: function () {
|
|
3969
3163
|
var r = t.next(),
|
|
3970
3164
|
n = r.done,
|
|
3971
|
-
|
|
3972
|
-
return { done: n, value: n ? void 0 : [
|
|
3165
|
+
o = r.value;
|
|
3166
|
+
return { done: n, value: n ? void 0 : [o, e.get(o)] };
|
|
3973
3167
|
},
|
|
3974
3168
|
});
|
|
3975
3169
|
}),
|
|
@@ -3979,17 +3173,17 @@ var or,
|
|
|
3979
3173
|
(e.prototype.forEach = function (e, t) {
|
|
3980
3174
|
var r, n;
|
|
3981
3175
|
try {
|
|
3982
|
-
for (var
|
|
3983
|
-
var a =
|
|
3176
|
+
for (var o = he(this), i = o.next(); !i.done; i = o.next()) {
|
|
3177
|
+
var a = ve(i.value, 2),
|
|
3984
3178
|
s = a[0],
|
|
3985
|
-
|
|
3986
|
-
e.call(t,
|
|
3179
|
+
u = a[1];
|
|
3180
|
+
e.call(t, u, s, this);
|
|
3987
3181
|
}
|
|
3988
3182
|
} catch (e) {
|
|
3989
3183
|
r = { error: e };
|
|
3990
3184
|
} finally {
|
|
3991
3185
|
try {
|
|
3992
|
-
|
|
3186
|
+
i && !i.done && (n = o.return) && n.call(o);
|
|
3993
3187
|
} finally {
|
|
3994
3188
|
if (r) throw r.error;
|
|
3995
3189
|
}
|
|
@@ -3998,9 +3192,9 @@ var or,
|
|
|
3998
3192
|
(e.prototype.merge = function (e) {
|
|
3999
3193
|
var t = this;
|
|
4000
3194
|
return (
|
|
4001
|
-
|
|
4002
|
-
|
|
4003
|
-
var r =
|
|
3195
|
+
ur(e) && (e = e.toJS()),
|
|
3196
|
+
zt(function () {
|
|
3197
|
+
var r = ot(!0);
|
|
4004
3198
|
try {
|
|
4005
3199
|
Y(e)
|
|
4006
3200
|
? ne(e).forEach(function (r) {
|
|
@@ -4008,10 +3202,10 @@ var or,
|
|
|
4008
3202
|
})
|
|
4009
3203
|
: Array.isArray(e)
|
|
4010
3204
|
? e.forEach(function (e) {
|
|
4011
|
-
var r =
|
|
3205
|
+
var r = ve(e, 2),
|
|
4012
3206
|
n = r[0],
|
|
4013
|
-
|
|
4014
|
-
return t.set(n,
|
|
3207
|
+
o = r[1];
|
|
3208
|
+
return t.set(n, o);
|
|
4015
3209
|
})
|
|
4016
3210
|
: te(e)
|
|
4017
3211
|
? (e.constructor !== Map &&
|
|
@@ -4024,7 +3218,7 @@ var or,
|
|
|
4024
3218
|
}))
|
|
4025
3219
|
: null != e && J('Cannot initialize map from ' + e);
|
|
4026
3220
|
} finally {
|
|
4027
|
-
|
|
3221
|
+
it(r);
|
|
4028
3222
|
}
|
|
4029
3223
|
}),
|
|
4030
3224
|
this
|
|
@@ -4032,19 +3226,19 @@ var or,
|
|
|
4032
3226
|
}),
|
|
4033
3227
|
(e.prototype.clear = function () {
|
|
4034
3228
|
var e = this;
|
|
4035
|
-
|
|
3229
|
+
zt(function () {
|
|
4036
3230
|
He(function () {
|
|
4037
3231
|
var t, r;
|
|
4038
3232
|
try {
|
|
4039
|
-
for (var n =
|
|
4040
|
-
var
|
|
4041
|
-
e.delete(
|
|
3233
|
+
for (var n = he(e.keys()), o = n.next(); !o.done; o = n.next()) {
|
|
3234
|
+
var i = o.value;
|
|
3235
|
+
e.delete(i);
|
|
4042
3236
|
}
|
|
4043
3237
|
} catch (e) {
|
|
4044
3238
|
t = { error: e };
|
|
4045
3239
|
} finally {
|
|
4046
3240
|
try {
|
|
4047
|
-
|
|
3241
|
+
o && !o.done && (r = n.return) && r.call(n);
|
|
4048
3242
|
} finally {
|
|
4049
3243
|
if (t) throw t.error;
|
|
4050
3244
|
}
|
|
@@ -4055,13 +3249,13 @@ var or,
|
|
|
4055
3249
|
(e.prototype.replace = function (e) {
|
|
4056
3250
|
var t = this;
|
|
4057
3251
|
return (
|
|
4058
|
-
|
|
3252
|
+
zt(function () {
|
|
4059
3253
|
var r,
|
|
4060
3254
|
n,
|
|
4061
|
-
i,
|
|
4062
3255
|
o,
|
|
3256
|
+
i,
|
|
4063
3257
|
a = (function (e) {
|
|
4064
|
-
if (te(e) ||
|
|
3258
|
+
if (te(e) || ur(e)) return e;
|
|
4065
3259
|
if (Array.isArray(e)) return new Map(e);
|
|
4066
3260
|
if (Y(e)) {
|
|
4067
3261
|
var t = new Map();
|
|
@@ -4071,68 +3265,68 @@ var or,
|
|
|
4071
3265
|
return J("Cannot convert to map from '" + e + "'");
|
|
4072
3266
|
})(e),
|
|
4073
3267
|
s = new Map(),
|
|
4074
|
-
|
|
3268
|
+
u = !1;
|
|
4075
3269
|
try {
|
|
4076
3270
|
for (
|
|
4077
|
-
var
|
|
3271
|
+
var c = he(t._data.keys()), p = c.next();
|
|
4078
3272
|
!p.done;
|
|
4079
|
-
p =
|
|
3273
|
+
p = c.next()
|
|
4080
3274
|
) {
|
|
4081
|
-
var
|
|
4082
|
-
if (!a.has(
|
|
4083
|
-
if (t.delete(
|
|
3275
|
+
var l = p.value;
|
|
3276
|
+
if (!a.has(l))
|
|
3277
|
+
if (t.delete(l)) u = !0;
|
|
4084
3278
|
else {
|
|
4085
|
-
var d = t._data.get(
|
|
4086
|
-
s.set(
|
|
3279
|
+
var d = t._data.get(l);
|
|
3280
|
+
s.set(l, d);
|
|
4087
3281
|
}
|
|
4088
3282
|
}
|
|
4089
3283
|
} catch (e) {
|
|
4090
3284
|
r = { error: e };
|
|
4091
3285
|
} finally {
|
|
4092
3286
|
try {
|
|
4093
|
-
p && !p.done && (n =
|
|
3287
|
+
p && !p.done && (n = c.return) && n.call(c);
|
|
4094
3288
|
} finally {
|
|
4095
3289
|
if (r) throw r.error;
|
|
4096
3290
|
}
|
|
4097
3291
|
}
|
|
4098
3292
|
try {
|
|
4099
3293
|
for (
|
|
4100
|
-
var f =
|
|
4101
|
-
!
|
|
4102
|
-
|
|
3294
|
+
var f = he(a.entries()), h = f.next();
|
|
3295
|
+
!h.done;
|
|
3296
|
+
h = f.next()
|
|
4103
3297
|
) {
|
|
4104
|
-
var
|
|
4105
|
-
|
|
4106
|
-
if ((t.set(
|
|
4107
|
-
var b = t._data.get(
|
|
4108
|
-
s.set(
|
|
3298
|
+
var v = ve(h.value, 2),
|
|
3299
|
+
y = ((l = v[0]), (d = v[1]), t._data.has(l));
|
|
3300
|
+
if ((t.set(l, d), t._data.has(l))) {
|
|
3301
|
+
var b = t._data.get(l);
|
|
3302
|
+
s.set(l, b), y || (u = !0);
|
|
4109
3303
|
}
|
|
4110
3304
|
}
|
|
4111
3305
|
} catch (e) {
|
|
4112
|
-
|
|
3306
|
+
o = { error: e };
|
|
4113
3307
|
} finally {
|
|
4114
3308
|
try {
|
|
4115
|
-
|
|
3309
|
+
h && !h.done && (i = f.return) && i.call(f);
|
|
4116
3310
|
} finally {
|
|
4117
|
-
if (
|
|
3311
|
+
if (o) throw o.error;
|
|
4118
3312
|
}
|
|
4119
3313
|
}
|
|
4120
|
-
if (!
|
|
3314
|
+
if (!u)
|
|
4121
3315
|
if (t._data.size !== s.size) t._keysAtom.reportChanged();
|
|
4122
3316
|
else
|
|
4123
3317
|
for (
|
|
4124
3318
|
var m = t._data.keys(),
|
|
4125
3319
|
g = s.keys(),
|
|
4126
3320
|
O = m.next(),
|
|
4127
|
-
|
|
3321
|
+
E = g.next();
|
|
4128
3322
|
!O.done;
|
|
4129
3323
|
|
|
4130
3324
|
) {
|
|
4131
|
-
if (O.value !==
|
|
3325
|
+
if (O.value !== E.value) {
|
|
4132
3326
|
t._keysAtom.reportChanged();
|
|
4133
3327
|
break;
|
|
4134
3328
|
}
|
|
4135
|
-
(O = m.next()), (
|
|
3329
|
+
(O = m.next()), (E = g.next());
|
|
4136
3330
|
}
|
|
4137
3331
|
t._data = s;
|
|
4138
3332
|
}),
|
|
@@ -4151,17 +3345,17 @@ var or,
|
|
|
4151
3345
|
t,
|
|
4152
3346
|
r = {};
|
|
4153
3347
|
try {
|
|
4154
|
-
for (var n =
|
|
4155
|
-
var
|
|
4156
|
-
a =
|
|
4157
|
-
s =
|
|
4158
|
-
r['symbol' == typeof a ? a :
|
|
3348
|
+
for (var n = he(this), o = n.next(); !o.done; o = n.next()) {
|
|
3349
|
+
var i = ve(o.value, 2),
|
|
3350
|
+
a = i[0],
|
|
3351
|
+
s = i[1];
|
|
3352
|
+
r['symbol' == typeof a ? a : oe(a)] = s;
|
|
4159
3353
|
}
|
|
4160
3354
|
} catch (t) {
|
|
4161
3355
|
e = { error: t };
|
|
4162
3356
|
} finally {
|
|
4163
3357
|
try {
|
|
4164
|
-
|
|
3358
|
+
o && !o.done && (t = n.return) && t.call(n);
|
|
4165
3359
|
} finally {
|
|
4166
3360
|
if (e) throw e.error;
|
|
4167
3361
|
}
|
|
@@ -4181,7 +3375,7 @@ var or,
|
|
|
4181
3375
|
'[{ ' +
|
|
4182
3376
|
Array.from(this.keys())
|
|
4183
3377
|
.map(function (t) {
|
|
4184
|
-
return
|
|
3378
|
+
return oe(t) + ': ' + e.get(t);
|
|
4185
3379
|
})
|
|
4186
3380
|
.join(', ') +
|
|
4187
3381
|
' }]'
|
|
@@ -4203,15 +3397,15 @@ var or,
|
|
|
4203
3397
|
e
|
|
4204
3398
|
);
|
|
4205
3399
|
})(),
|
|
4206
|
-
|
|
4207
|
-
|
|
3400
|
+
ur = ee('ObservableMap', sr),
|
|
3401
|
+
cr = {},
|
|
4208
3402
|
pr = (function () {
|
|
4209
3403
|
function e(e, t, r) {
|
|
4210
3404
|
if (
|
|
4211
3405
|
(void 0 === t && (t = _e),
|
|
4212
|
-
void 0 === r && (r = 'ObservableSet@' +
|
|
3406
|
+
void 0 === r && (r = 'ObservableSet@' + F()),
|
|
4213
3407
|
(this.name = r),
|
|
4214
|
-
(this[
|
|
3408
|
+
(this[ir] = cr),
|
|
4215
3409
|
(this._data = new Set()),
|
|
4216
3410
|
(this._atom = pe(this.name)),
|
|
4217
3411
|
(this[Symbol.toStringTag] = 'Set'),
|
|
@@ -4231,23 +3425,23 @@ var or,
|
|
|
4231
3425
|
}),
|
|
4232
3426
|
(e.prototype.clear = function () {
|
|
4233
3427
|
var e = this;
|
|
4234
|
-
|
|
3428
|
+
zt(function () {
|
|
4235
3429
|
He(function () {
|
|
4236
3430
|
var t, r;
|
|
4237
3431
|
try {
|
|
4238
3432
|
for (
|
|
4239
|
-
var n =
|
|
4240
|
-
!
|
|
4241
|
-
|
|
3433
|
+
var n = he(e._data.values()), o = n.next();
|
|
3434
|
+
!o.done;
|
|
3435
|
+
o = n.next()
|
|
4242
3436
|
) {
|
|
4243
|
-
var
|
|
4244
|
-
e.delete(
|
|
3437
|
+
var i = o.value;
|
|
3438
|
+
e.delete(i);
|
|
4245
3439
|
}
|
|
4246
3440
|
} catch (e) {
|
|
4247
3441
|
t = { error: e };
|
|
4248
3442
|
} finally {
|
|
4249
3443
|
try {
|
|
4250
|
-
|
|
3444
|
+
o && !o.done && (r = n.return) && r.call(n);
|
|
4251
3445
|
} finally {
|
|
4252
3446
|
if (t) throw t.error;
|
|
4253
3447
|
}
|
|
@@ -4258,15 +3452,15 @@ var or,
|
|
|
4258
3452
|
(e.prototype.forEach = function (e, t) {
|
|
4259
3453
|
var r, n;
|
|
4260
3454
|
try {
|
|
4261
|
-
for (var
|
|
4262
|
-
var a =
|
|
3455
|
+
for (var o = he(this), i = o.next(); !i.done; i = o.next()) {
|
|
3456
|
+
var a = i.value;
|
|
4263
3457
|
e.call(t, a, a, this);
|
|
4264
3458
|
}
|
|
4265
3459
|
} catch (e) {
|
|
4266
3460
|
r = { error: e };
|
|
4267
3461
|
} finally {
|
|
4268
3462
|
try {
|
|
4269
|
-
|
|
3463
|
+
i && !i.done && (n = o.return) && n.call(o);
|
|
4270
3464
|
} finally {
|
|
4271
3465
|
if (r) throw r.error;
|
|
4272
3466
|
}
|
|
@@ -4283,19 +3477,19 @@ var or,
|
|
|
4283
3477
|
var t = this;
|
|
4284
3478
|
if (
|
|
4285
3479
|
(Ke(this._atom), Ht(this)) &&
|
|
4286
|
-
!(
|
|
3480
|
+
!(o = Xt(this, { type: 'add', object: this, newValue: e }))
|
|
4287
3481
|
)
|
|
4288
3482
|
return this;
|
|
4289
3483
|
if (!this.has(e)) {
|
|
4290
|
-
|
|
3484
|
+
zt(function () {
|
|
4291
3485
|
t._data.add(t.enhancer(e, void 0)), t._atom.reportChanged();
|
|
4292
3486
|
});
|
|
4293
|
-
var r =
|
|
4294
|
-
n =
|
|
4295
|
-
|
|
4296
|
-
r && 'production' !== process.env.NODE_ENV &&
|
|
4297
|
-
n && Zt(this,
|
|
4298
|
-
r && 'production' !== process.env.NODE_ENV &&
|
|
3487
|
+
var r = Dt(),
|
|
3488
|
+
n = $t(this),
|
|
3489
|
+
o = n || r ? { type: 'add', object: this, newValue: e } : null;
|
|
3490
|
+
r && 'production' !== process.env.NODE_ENV && Vt(o),
|
|
3491
|
+
n && Zt(this, o),
|
|
3492
|
+
r && 'production' !== process.env.NODE_ENV && kt();
|
|
4299
3493
|
}
|
|
4300
3494
|
return this;
|
|
4301
3495
|
}),
|
|
@@ -4303,22 +3497,22 @@ var or,
|
|
|
4303
3497
|
var t = this;
|
|
4304
3498
|
if (
|
|
4305
3499
|
Ht(this) &&
|
|
4306
|
-
!(
|
|
3500
|
+
!(o = Xt(this, { type: 'delete', object: this, oldValue: e }))
|
|
4307
3501
|
)
|
|
4308
3502
|
return !1;
|
|
4309
3503
|
if (this.has(e)) {
|
|
4310
|
-
var r =
|
|
4311
|
-
n =
|
|
4312
|
-
|
|
3504
|
+
var r = Dt(),
|
|
3505
|
+
n = $t(this),
|
|
3506
|
+
o = n || r ? { type: 'delete', object: this, oldValue: e } : null;
|
|
4313
3507
|
return (
|
|
4314
3508
|
r &&
|
|
4315
3509
|
'production' !== process.env.NODE_ENV &&
|
|
4316
|
-
|
|
4317
|
-
|
|
3510
|
+
Vt(fe(fe({}, o), { name: this.name })),
|
|
3511
|
+
zt(function () {
|
|
4318
3512
|
t._atom.reportChanged(), t._data.delete(e);
|
|
4319
3513
|
}),
|
|
4320
|
-
n && Zt(this,
|
|
4321
|
-
r && 'production' !== process.env.NODE_ENV &&
|
|
3514
|
+
n && Zt(this, o),
|
|
3515
|
+
r && 'production' !== process.env.NODE_ENV && kt(),
|
|
4322
3516
|
!0
|
|
4323
3517
|
);
|
|
4324
3518
|
}
|
|
@@ -4333,7 +3527,7 @@ var or,
|
|
|
4333
3527
|
var e = 0,
|
|
4334
3528
|
t = Array.from(this.keys()),
|
|
4335
3529
|
r = Array.from(this.values());
|
|
4336
|
-
return
|
|
3530
|
+
return Dr({
|
|
4337
3531
|
next: function () {
|
|
4338
3532
|
var n = e;
|
|
4339
3533
|
return (
|
|
@@ -4351,7 +3545,7 @@ var or,
|
|
|
4351
3545
|
var e = this,
|
|
4352
3546
|
t = 0,
|
|
4353
3547
|
r = Array.from(this._data.values());
|
|
4354
|
-
return
|
|
3548
|
+
return Dr({
|
|
4355
3549
|
next: function () {
|
|
4356
3550
|
return t < r.length
|
|
4357
3551
|
? { value: e.dehanceValue(r[t++]), done: !1 }
|
|
@@ -4362,9 +3556,9 @@ var or,
|
|
|
4362
3556
|
(e.prototype.replace = function (e) {
|
|
4363
3557
|
var t = this;
|
|
4364
3558
|
return (
|
|
4365
|
-
|
|
4366
|
-
|
|
4367
|
-
var r =
|
|
3559
|
+
lr(e) && (e = e.toJS()),
|
|
3560
|
+
zt(function () {
|
|
3561
|
+
var r = ot(!0);
|
|
4368
3562
|
try {
|
|
4369
3563
|
Array.isArray(e) || re(e)
|
|
4370
3564
|
? (t.clear(),
|
|
@@ -4373,7 +3567,7 @@ var or,
|
|
|
4373
3567
|
}))
|
|
4374
3568
|
: null != e && J('Cannot initialize set from ' + e);
|
|
4375
3569
|
} finally {
|
|
4376
|
-
|
|
3570
|
+
it(r);
|
|
4377
3571
|
}
|
|
4378
3572
|
}),
|
|
4379
3573
|
this
|
|
@@ -4398,13 +3592,13 @@ var or,
|
|
|
4398
3592
|
(e.prototype.toString = function () {
|
|
4399
3593
|
return this.name + '[ ' + Array.from(this).join(', ') + ' ]';
|
|
4400
3594
|
}),
|
|
4401
|
-
(e.prototype[((
|
|
3595
|
+
(e.prototype[((ir = se), Symbol.iterator)] = function () {
|
|
4402
3596
|
return this.values();
|
|
4403
3597
|
}),
|
|
4404
3598
|
e
|
|
4405
3599
|
);
|
|
4406
3600
|
})(),
|
|
4407
|
-
|
|
3601
|
+
lr = ee('ObservableSet', pr),
|
|
4408
3602
|
dr = (function () {
|
|
4409
3603
|
function e(e, t, r, n) {
|
|
4410
3604
|
void 0 === t && (t = new Map()),
|
|
@@ -4412,7 +3606,7 @@ var or,
|
|
|
4412
3606
|
(this.values = t),
|
|
4413
3607
|
(this.name = r),
|
|
4414
3608
|
(this.defaultEnhancer = n),
|
|
4415
|
-
(this.keysAtom = new
|
|
3609
|
+
(this.keysAtom = new ue(r + '.keys'));
|
|
4416
3610
|
}
|
|
4417
3611
|
return (
|
|
4418
3612
|
(e.prototype.read = function (e) {
|
|
@@ -4425,7 +3619,7 @@ var or,
|
|
|
4425
3619
|
else {
|
|
4426
3620
|
if (Ht(this)) {
|
|
4427
3621
|
if (
|
|
4428
|
-
!(a =
|
|
3622
|
+
!(a = Xt(this, {
|
|
4429
3623
|
type: 'update',
|
|
4430
3624
|
object: this.proxy || r,
|
|
4431
3625
|
name: e,
|
|
@@ -4436,10 +3630,10 @@ var or,
|
|
|
4436
3630
|
t = a.newValue;
|
|
4437
3631
|
}
|
|
4438
3632
|
if ((t = n.prepareNewValue(t)) !== ft.UNCHANGED) {
|
|
4439
|
-
var
|
|
4440
|
-
|
|
3633
|
+
var o = $t(this),
|
|
3634
|
+
i = Dt(),
|
|
4441
3635
|
a =
|
|
4442
|
-
|
|
3636
|
+
o || i
|
|
4443
3637
|
? {
|
|
4444
3638
|
type: 'update',
|
|
4445
3639
|
object: this.proxy || r,
|
|
@@ -4448,12 +3642,12 @@ var or,
|
|
|
4448
3642
|
newValue: t,
|
|
4449
3643
|
}
|
|
4450
3644
|
: null;
|
|
4451
|
-
|
|
3645
|
+
i &&
|
|
4452
3646
|
'production' !== process.env.NODE_ENV &&
|
|
4453
|
-
|
|
3647
|
+
Vt(fe(fe({}, a), { name: this.name, key: e })),
|
|
4454
3648
|
n.setNewValue(t),
|
|
4455
|
-
|
|
4456
|
-
|
|
3649
|
+
o && Zt(this, a),
|
|
3650
|
+
i && 'production' !== process.env.NODE_ENV && kt();
|
|
4457
3651
|
}
|
|
4458
3652
|
}
|
|
4459
3653
|
}),
|
|
@@ -4463,7 +3657,7 @@ var or,
|
|
|
4463
3657
|
if (r) return r.get();
|
|
4464
3658
|
var n = !!this.values.get(e);
|
|
4465
3659
|
return (
|
|
4466
|
-
(r = new at(n, je, this.name + '.' +
|
|
3660
|
+
(r = new at(n, je, this.name + '.' + oe(e) + '?', !1)),
|
|
4467
3661
|
t.set(e, r),
|
|
4468
3662
|
r.get()
|
|
4469
3663
|
);
|
|
@@ -4471,22 +3665,22 @@ var or,
|
|
|
4471
3665
|
(e.prototype.addObservableProp = function (e, t, r) {
|
|
4472
3666
|
void 0 === r && (r = this.defaultEnhancer);
|
|
4473
3667
|
var n,
|
|
4474
|
-
|
|
4475
|
-
|
|
3668
|
+
o,
|
|
3669
|
+
i = this.target;
|
|
4476
3670
|
if (
|
|
4477
|
-
((n =
|
|
4478
|
-
(
|
|
3671
|
+
((n = i),
|
|
3672
|
+
(o = e),
|
|
4479
3673
|
'production' === process.env.NODE_ENV ||
|
|
4480
|
-
Q(n,
|
|
3674
|
+
Q(n, o) ||
|
|
4481
3675
|
J(
|
|
4482
3676
|
"Cannot make property '" +
|
|
4483
|
-
|
|
3677
|
+
o.toString() +
|
|
4484
3678
|
"' observable, it is not configurable and writable in the target object",
|
|
4485
3679
|
),
|
|
4486
3680
|
Ht(this))
|
|
4487
3681
|
) {
|
|
4488
|
-
var a =
|
|
4489
|
-
object: this.proxy ||
|
|
3682
|
+
var a = Xt(this, {
|
|
3683
|
+
object: this.proxy || i,
|
|
4490
3684
|
name: e,
|
|
4491
3685
|
type: 'add',
|
|
4492
3686
|
newValue: t,
|
|
@@ -4494,16 +3688,16 @@ var or,
|
|
|
4494
3688
|
if (!a) return;
|
|
4495
3689
|
t = a.newValue;
|
|
4496
3690
|
}
|
|
4497
|
-
var s = new at(t, r, this.name + '.' +
|
|
3691
|
+
var s = new at(t, r, this.name + '.' + oe(e), !1);
|
|
4498
3692
|
this.values.set(e, s),
|
|
4499
3693
|
(t = s.value),
|
|
4500
3694
|
Object.defineProperty(
|
|
4501
|
-
|
|
3695
|
+
i,
|
|
4502
3696
|
e,
|
|
4503
3697
|
(function (e) {
|
|
4504
3698
|
return (
|
|
4505
|
-
|
|
4506
|
-
(
|
|
3699
|
+
hr[e] ||
|
|
3700
|
+
(hr[e] = {
|
|
4507
3701
|
configurable: !0,
|
|
4508
3702
|
enumerable: !0,
|
|
4509
3703
|
get: function () {
|
|
@@ -4520,7 +3714,7 @@ var or,
|
|
|
4520
3714
|
}),
|
|
4521
3715
|
(e.prototype.addComputedProp = function (e, t, r) {
|
|
4522
3716
|
var n = this.target;
|
|
4523
|
-
(r.name = r.name || this.name + '.' +
|
|
3717
|
+
(r.name = r.name || this.name + '.' + oe(t)),
|
|
4524
3718
|
this.values.set(t, new st(r)),
|
|
4525
3719
|
(e === n || Q(e, t)) &&
|
|
4526
3720
|
Object.defineProperty(
|
|
@@ -4528,15 +3722,15 @@ var or,
|
|
|
4528
3722
|
t,
|
|
4529
3723
|
(function (e) {
|
|
4530
3724
|
return (
|
|
4531
|
-
|
|
4532
|
-
(
|
|
3725
|
+
vr[e] ||
|
|
3726
|
+
(vr[e] = {
|
|
4533
3727
|
configurable: ft.computedConfigurable,
|
|
4534
3728
|
enumerable: !1,
|
|
4535
3729
|
get: function () {
|
|
4536
|
-
return
|
|
3730
|
+
return yr(this).read(e);
|
|
4537
3731
|
},
|
|
4538
3732
|
set: function (t) {
|
|
4539
|
-
|
|
3733
|
+
yr(this).write(e, t);
|
|
4540
3734
|
},
|
|
4541
3735
|
})
|
|
4542
3736
|
);
|
|
@@ -4548,7 +3742,7 @@ var or,
|
|
|
4548
3742
|
var t = this.target;
|
|
4549
3743
|
if (Ht(this))
|
|
4550
3744
|
if (
|
|
4551
|
-
!(s =
|
|
3745
|
+
!(s = Xt(this, {
|
|
4552
3746
|
object: this.proxy || t,
|
|
4553
3747
|
name: e,
|
|
4554
3748
|
type: 'remove',
|
|
@@ -4557,12 +3751,12 @@ var or,
|
|
|
4557
3751
|
return;
|
|
4558
3752
|
try {
|
|
4559
3753
|
bt();
|
|
4560
|
-
var r =
|
|
4561
|
-
n =
|
|
4562
|
-
|
|
4563
|
-
|
|
3754
|
+
var r = $t(this),
|
|
3755
|
+
n = Dt(),
|
|
3756
|
+
o = this.values.get(e),
|
|
3757
|
+
i = o && o.get();
|
|
4564
3758
|
if (
|
|
4565
|
-
(
|
|
3759
|
+
(o && o.set(void 0),
|
|
4566
3760
|
this.keysAtom.reportChanged(),
|
|
4567
3761
|
this.values.delete(e),
|
|
4568
3762
|
this.pendingKeys)
|
|
@@ -4576,15 +3770,15 @@ var or,
|
|
|
4576
3770
|
? {
|
|
4577
3771
|
type: 'remove',
|
|
4578
3772
|
object: this.proxy || t,
|
|
4579
|
-
oldValue:
|
|
3773
|
+
oldValue: i,
|
|
4580
3774
|
name: e,
|
|
4581
3775
|
}
|
|
4582
3776
|
: null;
|
|
4583
3777
|
n &&
|
|
4584
3778
|
'production' !== process.env.NODE_ENV &&
|
|
4585
|
-
|
|
3779
|
+
Vt(fe(fe({}, s), { name: this.name, key: e })),
|
|
4586
3780
|
r && Zt(this, s),
|
|
4587
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
3781
|
+
n && 'production' !== process.env.NODE_ENV && kt();
|
|
4588
3782
|
} finally {
|
|
4589
3783
|
mt();
|
|
4590
3784
|
}
|
|
@@ -4613,9 +3807,9 @@ var or,
|
|
|
4613
3807
|
return Wt(this, e);
|
|
4614
3808
|
}),
|
|
4615
3809
|
(e.prototype.notifyPropertyAddition = function (e, t) {
|
|
4616
|
-
var r =
|
|
4617
|
-
n =
|
|
4618
|
-
|
|
3810
|
+
var r = $t(this),
|
|
3811
|
+
n = Dt(),
|
|
3812
|
+
o =
|
|
4619
3813
|
r || n
|
|
4620
3814
|
? {
|
|
4621
3815
|
type: 'add',
|
|
@@ -4627,13 +3821,13 @@ var or,
|
|
|
4627
3821
|
if (
|
|
4628
3822
|
(n &&
|
|
4629
3823
|
'production' !== process.env.NODE_ENV &&
|
|
4630
|
-
|
|
4631
|
-
r && Zt(this,
|
|
4632
|
-
n && 'production' !== process.env.NODE_ENV &&
|
|
3824
|
+
Vt(fe(fe({}, o), { name: this.name, key: e })),
|
|
3825
|
+
r && Zt(this, o),
|
|
3826
|
+
n && 'production' !== process.env.NODE_ENV && kt(),
|
|
4633
3827
|
this.pendingKeys)
|
|
4634
3828
|
) {
|
|
4635
|
-
var
|
|
4636
|
-
|
|
3829
|
+
var i = this.pendingKeys.get(e);
|
|
3830
|
+
i && i.set(!0);
|
|
4637
3831
|
}
|
|
4638
3832
|
this.keysAtom.reportChanged();
|
|
4639
3833
|
}),
|
|
@@ -4642,16 +3836,16 @@ var or,
|
|
|
4642
3836
|
this.keysAtom.reportObserved();
|
|
4643
3837
|
var r = [];
|
|
4644
3838
|
try {
|
|
4645
|
-
for (var n =
|
|
4646
|
-
var
|
|
4647
|
-
a =
|
|
4648
|
-
|
|
3839
|
+
for (var n = he(this.values), o = n.next(); !o.done; o = n.next()) {
|
|
3840
|
+
var i = ve(o.value, 2),
|
|
3841
|
+
a = i[0];
|
|
3842
|
+
i[1] instanceof at && r.push(a);
|
|
4649
3843
|
}
|
|
4650
3844
|
} catch (t) {
|
|
4651
3845
|
e = { error: t };
|
|
4652
3846
|
} finally {
|
|
4653
3847
|
try {
|
|
4654
|
-
|
|
3848
|
+
o && !o.done && (t = n.return) && t.call(n);
|
|
4655
3849
|
} finally {
|
|
4656
3850
|
if (e) throw e.error;
|
|
4657
3851
|
}
|
|
@@ -4673,24 +3867,24 @@ function fr(e, t, r) {
|
|
|
4673
3867
|
Object.isExtensible(e),
|
|
4674
3868
|
'Cannot make the designated object observable; it is not extensible',
|
|
4675
3869
|
),
|
|
4676
|
-
Y(e) || (t = (e.constructor.name || 'ObservableObject') + '@' +
|
|
4677
|
-
t || (t = 'ObservableObject@' +
|
|
4678
|
-
var n = new dr(e, new Map(),
|
|
3870
|
+
Y(e) || (t = (e.constructor.name || 'ObservableObject') + '@' + F()),
|
|
3871
|
+
t || (t = 'ObservableObject@' + F());
|
|
3872
|
+
var n = new dr(e, new Map(), oe(t), r);
|
|
4679
3873
|
return Z(e, se, n), n;
|
|
4680
3874
|
}
|
|
4681
|
-
var
|
|
4682
|
-
|
|
4683
|
-
function
|
|
3875
|
+
var hr = Object.create(null),
|
|
3876
|
+
vr = Object.create(null);
|
|
3877
|
+
function yr(e) {
|
|
4684
3878
|
var t = e[se];
|
|
4685
|
-
return t || (
|
|
3879
|
+
return t || (Ee(e), e[se]);
|
|
4686
3880
|
}
|
|
4687
3881
|
var br = ee('ObservableObjectAdministration', dr);
|
|
4688
3882
|
function mr(e) {
|
|
4689
|
-
return
|
|
3883
|
+
return !!$(e) && (Ee(e), br(e[se]));
|
|
4690
3884
|
}
|
|
4691
3885
|
function gr(e, t) {
|
|
4692
3886
|
if ('object' == typeof e && null !== e) {
|
|
4693
|
-
if (
|
|
3887
|
+
if (or(e))
|
|
4694
3888
|
return (
|
|
4695
3889
|
void 0 !== t &&
|
|
4696
3890
|
J(
|
|
@@ -4699,8 +3893,8 @@ function gr(e, t) {
|
|
|
4699
3893
|
),
|
|
4700
3894
|
e[se].atom
|
|
4701
3895
|
);
|
|
4702
|
-
if (
|
|
4703
|
-
if (
|
|
3896
|
+
if (lr(e)) return e[se];
|
|
3897
|
+
if (ur(e)) {
|
|
4704
3898
|
var r = e;
|
|
4705
3899
|
return void 0 === t
|
|
4706
3900
|
? r._keysAtom
|
|
@@ -4710,13 +3904,13 @@ function gr(e, t) {
|
|
|
4710
3904
|
"the entry '" +
|
|
4711
3905
|
t +
|
|
4712
3906
|
"' does not exist in the observable map '" +
|
|
4713
|
-
|
|
3907
|
+
Er(e) +
|
|
4714
3908
|
"'",
|
|
4715
3909
|
),
|
|
4716
3910
|
n);
|
|
4717
3911
|
}
|
|
4718
3912
|
var n;
|
|
4719
|
-
if ((
|
|
3913
|
+
if ((Ee(e), t && !e[se] && e[t], mr(e)))
|
|
4720
3914
|
return t
|
|
4721
3915
|
? ((n = e[se].values.get(t)) ||
|
|
4722
3916
|
J(
|
|
@@ -4724,7 +3918,7 @@ function gr(e, t) {
|
|
|
4724
3918
|
"no observable property '" +
|
|
4725
3919
|
t +
|
|
4726
3920
|
"' found on the observable object '" +
|
|
4727
|
-
|
|
3921
|
+
Er(e) +
|
|
4728
3922
|
"'",
|
|
4729
3923
|
),
|
|
4730
3924
|
n)
|
|
@@ -4732,8 +3926,8 @@ function gr(e, t) {
|
|
|
4732
3926
|
'production' !== process.env.NODE_ENV &&
|
|
4733
3927
|
'please specify a property',
|
|
4734
3928
|
);
|
|
4735
|
-
if (
|
|
4736
|
-
} else if ('function' == typeof e &&
|
|
3929
|
+
if (ce(e) || ut(e) || St(e)) return e;
|
|
3930
|
+
} else if ('function' == typeof e && St(e[se])) return e[se];
|
|
4737
3931
|
return J(
|
|
4738
3932
|
'production' !== process.env.NODE_ENV && 'Cannot obtain atom from ' + e,
|
|
4739
3933
|
);
|
|
@@ -4743,9 +3937,9 @@ function Or(e, t) {
|
|
|
4743
3937
|
e || J('Expecting some object'),
|
|
4744
3938
|
void 0 !== t
|
|
4745
3939
|
? Or(gr(e, t))
|
|
4746
|
-
:
|
|
3940
|
+
: ce(e) || ut(e) || St(e) || ur(e) || lr(e)
|
|
4747
3941
|
? e
|
|
4748
|
-
: (
|
|
3942
|
+
: (Ee(e),
|
|
4749
3943
|
e[se]
|
|
4750
3944
|
? e[se]
|
|
4751
3945
|
: void J(
|
|
@@ -4754,32 +3948,32 @@ function Or(e, t) {
|
|
|
4754
3948
|
))
|
|
4755
3949
|
);
|
|
4756
3950
|
}
|
|
4757
|
-
function
|
|
4758
|
-
return (void 0 !== t ? gr(e, t) : mr(e) ||
|
|
3951
|
+
function Er(e, t) {
|
|
3952
|
+
return (void 0 !== t ? gr(e, t) : mr(e) || ur(e) || lr(e) ? Or(e) : gr(e))
|
|
4759
3953
|
.name;
|
|
4760
3954
|
}
|
|
4761
|
-
var
|
|
4762
|
-
|
|
3955
|
+
var Nr,
|
|
3956
|
+
wr = Object.prototype.toString;
|
|
4763
3957
|
function _r(e, t, r) {
|
|
4764
3958
|
return void 0 === r && (r = -1), jr(e, t, r);
|
|
4765
3959
|
}
|
|
4766
|
-
function jr(e, t, r, n,
|
|
3960
|
+
function jr(e, t, r, n, o) {
|
|
4767
3961
|
if (e === t) return 0 !== e || 1 / e == 1 / t;
|
|
4768
3962
|
if (null == e || null == t) return !1;
|
|
4769
3963
|
if (e != e) return t != t;
|
|
4770
|
-
var
|
|
4771
|
-
if ('function' !==
|
|
4772
|
-
var a =
|
|
4773
|
-
if (a !==
|
|
3964
|
+
var i = typeof e;
|
|
3965
|
+
if ('function' !== i && 'object' !== i && 'object' != typeof t) return !1;
|
|
3966
|
+
var a = wr.call(e);
|
|
3967
|
+
if (a !== wr.call(t)) return !1;
|
|
4774
3968
|
switch (a) {
|
|
4775
3969
|
case '[object RegExp]':
|
|
4776
3970
|
case '[object String]':
|
|
4777
3971
|
return '' + e == '' + t;
|
|
4778
3972
|
case '[object Number]':
|
|
4779
|
-
return +e != +e ? +t != +t : 0
|
|
3973
|
+
return +e != +e ? +t != +t : 0 === +e ? 1 / +e == 1 / t : +e === +t;
|
|
4780
3974
|
case '[object Date]':
|
|
4781
3975
|
case '[object Boolean]':
|
|
4782
|
-
return +e
|
|
3976
|
+
return +e === +t;
|
|
4783
3977
|
case '[object Symbol]':
|
|
4784
3978
|
return (
|
|
4785
3979
|
'undefined' != typeof Symbol &&
|
|
@@ -4789,19 +3983,19 @@ function jr(e, t, r, n, i) {
|
|
|
4789
3983
|
case '[object Set]':
|
|
4790
3984
|
r >= 0 && r++;
|
|
4791
3985
|
}
|
|
4792
|
-
(e =
|
|
3986
|
+
(e = xr(e)), (t = xr(t));
|
|
4793
3987
|
var s = '[object Array]' === a;
|
|
4794
3988
|
if (!s) {
|
|
4795
3989
|
if ('object' != typeof e || 'object' != typeof t) return !1;
|
|
4796
|
-
var
|
|
4797
|
-
|
|
3990
|
+
var u = e.constructor,
|
|
3991
|
+
c = t.constructor;
|
|
4798
3992
|
if (
|
|
4799
|
-
|
|
3993
|
+
u !== c &&
|
|
4800
3994
|
!(
|
|
4801
|
-
'function' == typeof l &&
|
|
4802
|
-
l instanceof l &&
|
|
4803
3995
|
'function' == typeof u &&
|
|
4804
|
-
u instanceof u
|
|
3996
|
+
u instanceof u &&
|
|
3997
|
+
'function' == typeof c &&
|
|
3998
|
+
c instanceof c
|
|
4805
3999
|
) &&
|
|
4806
4000
|
'constructor' in e &&
|
|
4807
4001
|
'constructor' in t
|
|
@@ -4809,34 +4003,34 @@ function jr(e, t, r, n, i) {
|
|
|
4809
4003
|
return !1;
|
|
4810
4004
|
}
|
|
4811
4005
|
if (0 === r) return !1;
|
|
4812
|
-
r < 0 && (r = -1), (
|
|
4813
|
-
for (var p = (n = n || []).length; p--; ) if (n[p] === e) return
|
|
4814
|
-
if ((n.push(e),
|
|
4006
|
+
r < 0 && (r = -1), (o = o || []);
|
|
4007
|
+
for (var p = (n = n || []).length; p--; ) if (n[p] === e) return o[p] === t;
|
|
4008
|
+
if ((n.push(e), o.push(t), s)) {
|
|
4815
4009
|
if ((p = e.length) !== t.length) return !1;
|
|
4816
|
-
for (; p--; ) if (!jr(e[p], t[p], r - 1, n,
|
|
4010
|
+
for (; p--; ) if (!jr(e[p], t[p], r - 1, n, o)) return !1;
|
|
4817
4011
|
} else {
|
|
4818
|
-
var
|
|
4012
|
+
var l = Object.keys(e),
|
|
4819
4013
|
d = void 0;
|
|
4820
|
-
if (((p =
|
|
4014
|
+
if (((p = l.length), Object.keys(t).length !== p)) return !1;
|
|
4821
4015
|
for (; p--; )
|
|
4822
|
-
if (!
|
|
4016
|
+
if (!Sr(t, (d = l[p])) || !jr(e[d], t[d], r - 1, n, o)) return !1;
|
|
4823
4017
|
}
|
|
4824
|
-
return n.pop(),
|
|
4018
|
+
return n.pop(), o.pop(), !0;
|
|
4825
4019
|
}
|
|
4826
|
-
function
|
|
4827
|
-
return
|
|
4020
|
+
function xr(e) {
|
|
4021
|
+
return or(e)
|
|
4828
4022
|
? e.slice()
|
|
4829
|
-
: te(e) ||
|
|
4023
|
+
: te(e) || ur(e) || re(e) || lr(e)
|
|
4830
4024
|
? Array.from(e.entries())
|
|
4831
4025
|
: e;
|
|
4832
4026
|
}
|
|
4833
|
-
function
|
|
4027
|
+
function Sr(e, t) {
|
|
4834
4028
|
return Object.prototype.hasOwnProperty.call(e, t);
|
|
4835
4029
|
}
|
|
4836
|
-
function
|
|
4837
|
-
return (e[Symbol.iterator] =
|
|
4030
|
+
function Dr(e) {
|
|
4031
|
+
return (e[Symbol.iterator] = Ar), e;
|
|
4838
4032
|
}
|
|
4839
|
-
function
|
|
4033
|
+
function Ar() {
|
|
4840
4034
|
return this;
|
|
4841
4035
|
}
|
|
4842
4036
|
if ('undefined' == typeof Proxy || 'undefined' == typeof Symbol)
|
|
@@ -4846,8 +4040,8 @@ if ('undefined' == typeof Proxy || 'undefined' == typeof Symbol)
|
|
|
4846
4040
|
try {
|
|
4847
4041
|
process.env.NODE_ENV;
|
|
4848
4042
|
} catch (e) {
|
|
4849
|
-
var
|
|
4850
|
-
'undefined' == typeof process && (
|
|
4043
|
+
var Vr = lt();
|
|
4044
|
+
'undefined' == typeof process && (Vr.process = {}), (Vr.process.env = {});
|
|
4851
4045
|
}
|
|
4852
4046
|
!(function () {
|
|
4853
4047
|
if (
|
|
@@ -4877,11 +4071,11 @@ try {
|
|
|
4877
4071
|
});
|
|
4878
4072
|
}));
|
|
4879
4073
|
},
|
|
4880
|
-
extras: { getDebugName:
|
|
4074
|
+
extras: { getDebugName: Er },
|
|
4881
4075
|
$mobx: se,
|
|
4882
4076
|
});
|
|
4883
4077
|
var Tr =
|
|
4884
|
-
(((
|
|
4078
|
+
(((Nr = {
|
|
4885
4079
|
array: 'array',
|
|
4886
4080
|
boolean: 'boolean',
|
|
4887
4081
|
'box-style': 'object',
|
|
@@ -4905,25 +4099,20 @@ var Tr =
|
|
|
4905
4099
|
radio: 'string',
|
|
4906
4100
|
select: 'array',
|
|
4907
4101
|
}).select = 'string'),
|
|
4908
|
-
(
|
|
4909
|
-
(
|
|
4910
|
-
(
|
|
4911
|
-
(
|
|
4912
|
-
|
|
4913
|
-
|
|
4914
|
-
(Er['dynamic-array'] = 'object'),
|
|
4915
|
-
(Er['sohu-source'] = 'object'),
|
|
4916
|
-
(Er['sohu-event'] = 'object'),
|
|
4917
|
-
Er);
|
|
4918
|
-
function Vr(e) {
|
|
4102
|
+
(Nr.textarea = 'string'),
|
|
4103
|
+
(Nr['text-editor'] = 'string'),
|
|
4104
|
+
(Nr.time = 'string'),
|
|
4105
|
+
(Nr.url = 'string'),
|
|
4106
|
+
Nr);
|
|
4107
|
+
function kr(e) {
|
|
4919
4108
|
return Tr[e] || e;
|
|
4920
4109
|
}
|
|
4921
|
-
function
|
|
4110
|
+
function Cr(e, t) {
|
|
4922
4111
|
Tr[e]
|
|
4923
4112
|
? console.warn('当前已经存在' + e + '(' + Tr[e] + '),暂时不支持覆盖。')
|
|
4924
4113
|
: (Tr[e] = t);
|
|
4925
4114
|
}
|
|
4926
|
-
function
|
|
4115
|
+
function Rr(e) {
|
|
4927
4116
|
var t = !0;
|
|
4928
4117
|
if (!e) return t;
|
|
4929
4118
|
var r = e.type;
|
|
@@ -4949,13 +4138,13 @@ function Pr(e) {
|
|
|
4949
4138
|
n = new Date('2024-10-05T00:01:00.691Z').getTime();
|
|
4950
4139
|
return r && new Date(r).getTime() >= n && (t = !0), t;
|
|
4951
4140
|
}
|
|
4952
|
-
function
|
|
4141
|
+
function Ur(e) {
|
|
4953
4142
|
var t = !1,
|
|
4954
|
-
r =
|
|
4143
|
+
r = kr(e.type),
|
|
4955
4144
|
n = void 0 === e.isContainer || e.isContainer;
|
|
4956
4145
|
return 'object' === r && n && (t = !0), t;
|
|
4957
4146
|
}
|
|
4958
|
-
function
|
|
4147
|
+
function qr(e) {
|
|
4959
4148
|
var t = !0;
|
|
4960
4149
|
return (
|
|
4961
4150
|
'object' === e.type && e.propertyOrder && e.properties
|
|
@@ -4967,41 +4156,41 @@ function Mr(e) {
|
|
|
4967
4156
|
t
|
|
4968
4157
|
);
|
|
4969
4158
|
}
|
|
4970
|
-
function
|
|
4159
|
+
function Lr(e, t) {
|
|
4971
4160
|
var r = e.split('-'),
|
|
4972
4161
|
n = t.split('-');
|
|
4973
4162
|
return r.pop(), n.pop(), r.join('-') === n.join('-');
|
|
4974
4163
|
}
|
|
4975
|
-
function
|
|
4164
|
+
function Br(e, t) {
|
|
4976
4165
|
for (
|
|
4977
4166
|
var r = e.split('-'),
|
|
4978
4167
|
n = t.split('-'),
|
|
4979
|
-
|
|
4980
|
-
|
|
4168
|
+
o = 'before',
|
|
4169
|
+
i = 0,
|
|
4981
4170
|
a = (r.length > n.length ? n : r).length;
|
|
4982
|
-
|
|
4983
|
-
|
|
4171
|
+
i < a;
|
|
4172
|
+
i += 1
|
|
4984
4173
|
) {
|
|
4985
|
-
Number(r[
|
|
4174
|
+
Number(r[i]) > Number(n[i]) && (o = 'after');
|
|
4986
4175
|
}
|
|
4987
|
-
return
|
|
4176
|
+
return o;
|
|
4988
4177
|
}
|
|
4989
|
-
function
|
|
4178
|
+
function Ir(e) {
|
|
4990
4179
|
var t = e.split('-');
|
|
4991
4180
|
return t.pop(), t.join('-');
|
|
4992
4181
|
}
|
|
4993
|
-
function
|
|
4182
|
+
function Mr(e) {
|
|
4994
4183
|
var t = e.split('-'),
|
|
4995
4184
|
r = t.pop(),
|
|
4996
4185
|
n = Number(r) + 1;
|
|
4997
4186
|
return t.push('' + n), t.join('-');
|
|
4998
4187
|
}
|
|
4999
|
-
function
|
|
4188
|
+
function Gr(e) {
|
|
5000
4189
|
var t = e.split('-'),
|
|
5001
4190
|
r = t.pop();
|
|
5002
4191
|
return [t.join('-'), r];
|
|
5003
4192
|
}
|
|
5004
|
-
function
|
|
4193
|
+
function zr(e) {
|
|
5005
4194
|
var t = e.split('-'),
|
|
5006
4195
|
r = t.pop();
|
|
5007
4196
|
return t.push(Number(r) - 1), t.join('-');
|
|
@@ -5011,7 +4200,7 @@ function Kr(e) {
|
|
|
5011
4200
|
r = t.pop();
|
|
5012
4201
|
return t.push(Number(r) + 1), t.join('-');
|
|
5013
4202
|
}
|
|
5014
|
-
function
|
|
4203
|
+
function Fr(e, t) {
|
|
5015
4204
|
var r = '',
|
|
5016
4205
|
n = !1;
|
|
5017
4206
|
if (!1 !== e.defaultActiveFirstOption && e.defaultActiveFirstOption)
|
|
@@ -5024,35 +4213,35 @@ function zr(e, t) {
|
|
|
5024
4213
|
function Jr(e, t) {
|
|
5025
4214
|
var r,
|
|
5026
4215
|
n,
|
|
5027
|
-
|
|
5028
|
-
|
|
5029
|
-
|
|
5030
|
-
|
|
5031
|
-
(typeof
|
|
5032
|
-
((r =
|
|
5033
|
-
(
|
|
5034
|
-
var a =
|
|
4216
|
+
o = void 0,
|
|
4217
|
+
i = t;
|
|
4218
|
+
V(i) &&
|
|
4219
|
+
V(e.default) &&
|
|
4220
|
+
(typeof i != typeof e.default ||
|
|
4221
|
+
((r = i), (n = e.default), E(r) + '-' + g(r) != E(n) + '-' + g(n))) &&
|
|
4222
|
+
(i = void 0);
|
|
4223
|
+
var a = V(i) ? i : e.default;
|
|
5035
4224
|
switch (e.type) {
|
|
5036
4225
|
case 'select':
|
|
5037
4226
|
case 'radio':
|
|
5038
|
-
|
|
4227
|
+
o = null != a ? a : Fr(e);
|
|
5039
4228
|
break;
|
|
5040
4229
|
case 'checkboxes':
|
|
5041
|
-
|
|
4230
|
+
o = null != a ? a : Fr(e, !0);
|
|
5042
4231
|
break;
|
|
5043
4232
|
case 'color':
|
|
5044
4233
|
('#fff' !== a && '#FFF' !== a) || (a = '#ffffff'),
|
|
5045
|
-
(
|
|
4234
|
+
(o = V(a) ? a : '#ffffff');
|
|
5046
4235
|
break;
|
|
5047
4236
|
case 'boolean':
|
|
5048
|
-
|
|
4237
|
+
o = !!V(a) && a;
|
|
5049
4238
|
break;
|
|
5050
4239
|
case 'number':
|
|
5051
|
-
|
|
4240
|
+
o = V(a) ? a : void 0;
|
|
5052
4241
|
break;
|
|
5053
4242
|
case 'json':
|
|
5054
4243
|
var s = '';
|
|
5055
|
-
if (
|
|
4244
|
+
if (E(a) || g(a)) s = a;
|
|
5056
4245
|
else if (_(a) || '' === a) s = {};
|
|
5057
4246
|
else
|
|
5058
4247
|
try {
|
|
@@ -5060,36 +4249,36 @@ function Jr(e, t) {
|
|
|
5060
4249
|
} catch (e) {
|
|
5061
4250
|
s = {};
|
|
5062
4251
|
}
|
|
5063
|
-
|
|
4252
|
+
o = s;
|
|
5064
4253
|
break;
|
|
5065
4254
|
default:
|
|
5066
|
-
|
|
4255
|
+
o =
|
|
5067
4256
|
'input' === e.type && '0' === e.default
|
|
5068
4257
|
? a || e.default
|
|
5069
|
-
:
|
|
4258
|
+
: V(a)
|
|
5070
4259
|
? a
|
|
5071
4260
|
: void 0;
|
|
5072
4261
|
}
|
|
5073
|
-
return
|
|
4262
|
+
return o;
|
|
5074
4263
|
}
|
|
5075
4264
|
function Hr(e, t) {
|
|
5076
4265
|
var r = {},
|
|
5077
4266
|
n = e.type;
|
|
5078
|
-
if (
|
|
5079
|
-
var
|
|
5080
|
-
|
|
5081
|
-
|
|
5082
|
-
((
|
|
5083
|
-
(
|
|
5084
|
-
var a =
|
|
4267
|
+
if (E(e) && 'object' === kr(e.type)) {
|
|
4268
|
+
var o = e,
|
|
4269
|
+
i = t;
|
|
4270
|
+
V(i) &&
|
|
4271
|
+
((V(o.default) && typeof i != typeof e.default) || !E(i)) &&
|
|
4272
|
+
(i = void 0);
|
|
4273
|
+
var a = V(i) ? i : o.default;
|
|
5085
4274
|
if ('dynamic-data' === n)
|
|
5086
|
-
(r =
|
|
5087
|
-
a &&
|
|
4275
|
+
(r = S(u)),
|
|
4276
|
+
a && E(a) && '{}' !== JSON.stringify(a) && (r = Object.assign(r, a));
|
|
5088
4277
|
else if ('datasource' === n)
|
|
5089
|
-
|
|
5090
|
-
|
|
5091
|
-
|
|
5092
|
-
'local' ===
|
|
4278
|
+
o.properties &&
|
|
4279
|
+
o.properties.type &&
|
|
4280
|
+
o.properties.type.default &&
|
|
4281
|
+
'local' === o.properties.type.default
|
|
5093
4282
|
? ((r = { data: '{}', filter: '() => {}' }),
|
|
5094
4283
|
a && a.data && (r.data = a.data),
|
|
5095
4284
|
a && a.filter && (r.filter = a.filter),
|
|
@@ -5099,10 +4288,10 @@ function Hr(e, t) {
|
|
|
5099
4288
|
a && a.filter && (r.filter = a.filter),
|
|
5100
4289
|
'{}' === r.data && (r.data = 'http://xxx'));
|
|
5101
4290
|
else if ('event' === n)
|
|
5102
|
-
|
|
5103
|
-
|
|
5104
|
-
|
|
5105
|
-
'emit' ===
|
|
4291
|
+
o.properties &&
|
|
4292
|
+
o.properties.type &&
|
|
4293
|
+
o.properties.type.default &&
|
|
4294
|
+
'emit' === o.properties.type.default
|
|
5106
4295
|
? a && 'out' === a.type
|
|
5107
4296
|
? (r = { trigger: (a && a.filter) || 'eventName', eventData: '{}' })
|
|
5108
4297
|
: ((r = { trigger: 'eventName', eventData: '{}' }),
|
|
@@ -5116,23 +4305,23 @@ function Hr(e, t) {
|
|
|
5116
4305
|
: ((r = { register: 'eventName', actionFunc: '() => {}' }),
|
|
5117
4306
|
a && a.register && (r.register = a.register),
|
|
5118
4307
|
a && a.actionFunc && (r.actionFunc = a.actionFunc));
|
|
5119
|
-
else if (!1 === e.isContainer && a &&
|
|
4308
|
+
else if (!1 === e.isContainer && a && E(a) && '{}' !== JSON.stringify(a))
|
|
5120
4309
|
r = Object.assign(r, a);
|
|
5121
|
-
else if (void 0 ===
|
|
4310
|
+
else if (void 0 === i && o.default && E(o.default)) r = o.default;
|
|
5122
4311
|
else if (e.properties) {
|
|
5123
4312
|
(e.propertyOrder ? e.propertyOrder : Object.keys(e.properties)).map(
|
|
5124
4313
|
function (n) {
|
|
5125
|
-
var
|
|
5126
|
-
|
|
5127
|
-
switch (
|
|
4314
|
+
var o = e.properties[n],
|
|
4315
|
+
i = t && t[n];
|
|
4316
|
+
switch (kr(o.type)) {
|
|
5128
4317
|
case 'array':
|
|
5129
|
-
r[n] = Wr(
|
|
4318
|
+
r[n] = Wr(o, i);
|
|
5130
4319
|
break;
|
|
5131
4320
|
case 'object':
|
|
5132
|
-
r[n] = Hr(
|
|
4321
|
+
r[n] = Hr(o, i);
|
|
5133
4322
|
break;
|
|
5134
4323
|
default:
|
|
5135
|
-
r[n] = Jr(
|
|
4324
|
+
r[n] = Jr(o, i);
|
|
5136
4325
|
}
|
|
5137
4326
|
},
|
|
5138
4327
|
);
|
|
@@ -5142,49 +4331,49 @@ function Hr(e, t) {
|
|
|
5142
4331
|
}
|
|
5143
4332
|
function Wr(e, t) {
|
|
5144
4333
|
var r = [];
|
|
5145
|
-
if (e && 'array' ===
|
|
4334
|
+
if (e && 'array' === kr(e.type)) {
|
|
5146
4335
|
var n = t;
|
|
5147
|
-
|
|
5148
|
-
((
|
|
4336
|
+
V(n) &&
|
|
4337
|
+
((V(e.default) && typeof n != typeof e.default) || !g(n)) &&
|
|
5149
4338
|
(n = void 0);
|
|
5150
|
-
var
|
|
5151
|
-
if ('array' ===
|
|
5152
|
-
if (g(
|
|
5153
|
-
|
|
4339
|
+
var o = V(n) ? n : e.default;
|
|
4340
|
+
if ('array' === kr(e.type))
|
|
4341
|
+
if (g(o))
|
|
4342
|
+
o.map(function (t) {
|
|
5154
4343
|
r.push(Hr(e.items, t));
|
|
5155
4344
|
});
|
|
5156
|
-
else if (
|
|
4345
|
+
else if (o) r = o;
|
|
5157
4346
|
else {
|
|
5158
|
-
var
|
|
5159
|
-
r.push(
|
|
4347
|
+
var i = Hr(e.items, o);
|
|
4348
|
+
r.push(i);
|
|
5160
4349
|
}
|
|
5161
|
-
else r =
|
|
4350
|
+
else r = V(o) ? o : [];
|
|
5162
4351
|
}
|
|
5163
4352
|
return r;
|
|
5164
4353
|
}
|
|
5165
|
-
function
|
|
5166
|
-
return 'object' ===
|
|
4354
|
+
function Xr(e, t) {
|
|
4355
|
+
return 'object' === kr(e.type)
|
|
5167
4356
|
? Hr(e, t)
|
|
5168
|
-
: 'array' ===
|
|
4357
|
+
: 'array' === kr(e.type)
|
|
5169
4358
|
? Wr(e, t)
|
|
5170
4359
|
: Jr(e, t);
|
|
5171
4360
|
}
|
|
5172
|
-
var
|
|
4361
|
+
var $r = c;
|
|
5173
4362
|
function Yr(e, t) {
|
|
5174
4363
|
var r = t || [];
|
|
5175
4364
|
if (e && '{}' !== JSON.stringify(e))
|
|
5176
|
-
if (
|
|
4365
|
+
if (E(e))
|
|
5177
4366
|
if (
|
|
5178
4367
|
e.type &&
|
|
5179
4368
|
'remote' === e.type &&
|
|
5180
4369
|
e.config &&
|
|
5181
|
-
|
|
4370
|
+
E(e.config) &&
|
|
5182
4371
|
e.config.dataName &&
|
|
5183
|
-
|
|
5184
|
-
|
|
4372
|
+
V(e.localFilter) &&
|
|
4373
|
+
V(e.data)
|
|
5185
4374
|
) {
|
|
5186
4375
|
var n = e.config.body;
|
|
5187
|
-
if (n && !
|
|
4376
|
+
if (n && !E(n))
|
|
5188
4377
|
try {
|
|
5189
4378
|
n = JSON.parse(n);
|
|
5190
4379
|
} catch (e) {
|
|
@@ -5214,35 +4403,35 @@ function Zr(e, t) {
|
|
|
5214
4403
|
}
|
|
5215
4404
|
function Qr(e, t) {
|
|
5216
4405
|
var r = [];
|
|
5217
|
-
|
|
4406
|
+
E(e)
|
|
5218
4407
|
? Object.keys(e).map(function (n) {
|
|
5219
|
-
var
|
|
5220
|
-
|
|
5221
|
-
|
|
5222
|
-
? r.push({ title: n, value:
|
|
5223
|
-
: r.push({ title: n, value:
|
|
4408
|
+
var o = e[n],
|
|
4409
|
+
i = t ? t + '-' + n : n;
|
|
4410
|
+
E(o) || g(o)
|
|
4411
|
+
? r.push({ title: n, value: i, key: i, children: Qr(o, i) })
|
|
4412
|
+
: r.push({ title: n, value: i, key: i });
|
|
5224
4413
|
})
|
|
5225
4414
|
: g(e) &&
|
|
5226
4415
|
e.map(function (e, n) {
|
|
5227
|
-
var
|
|
5228
|
-
|
|
5229
|
-
|
|
5230
|
-
? r.push({ title:
|
|
5231
|
-
: r.push({ title:
|
|
4416
|
+
var o = n.toString(),
|
|
4417
|
+
i = t ? t + '-' + n : o;
|
|
4418
|
+
E(e) || g(e)
|
|
4419
|
+
? r.push({ title: o, value: i, key: i, children: Qr(e, i) })
|
|
4420
|
+
: r.push({ title: o, value: i, key: i });
|
|
5232
4421
|
});
|
|
5233
4422
|
return r;
|
|
5234
4423
|
}
|
|
5235
4424
|
function en(e, t) {
|
|
5236
4425
|
var r = '';
|
|
5237
|
-
if ('object' ===
|
|
4426
|
+
if ('object' === kr(e.type) && e.properties) {
|
|
5238
4427
|
(e.propertyOrder ? e.propertyOrder : Object.keys(e.properties)).map(
|
|
5239
4428
|
function (n) {
|
|
5240
|
-
var
|
|
5241
|
-
|
|
5242
|
-
('array' ===
|
|
5243
|
-
(
|
|
5244
|
-
|
|
5245
|
-
(r.indexOf('-') > 0 ? (r += '-' +
|
|
4429
|
+
var o = e.properties[n],
|
|
4430
|
+
i = t[n];
|
|
4431
|
+
('array' === kr(o.type) && 'object' === kr(o.type)) ||
|
|
4432
|
+
(i &&
|
|
4433
|
+
o.isConditionProp &&
|
|
4434
|
+
(r.indexOf('-') > 0 ? (r += '-' + i) : (r = i)));
|
|
5246
4435
|
},
|
|
5247
4436
|
);
|
|
5248
4437
|
}
|
|
@@ -5287,60 +4476,60 @@ var nn = [
|
|
|
5287
4476
|
'object',
|
|
5288
4477
|
];
|
|
5289
4478
|
export {
|
|
5290
|
-
|
|
4479
|
+
l as DataSourceTypeList,
|
|
5291
4480
|
p as EventTypeDataList,
|
|
5292
4481
|
nn as KeyWordList,
|
|
5293
|
-
|
|
4482
|
+
c as TypeDataList,
|
|
5294
4483
|
Zr as dataRoute2dataPath,
|
|
5295
4484
|
Yr as dynamicDataAnalyzer,
|
|
5296
|
-
|
|
5297
|
-
|
|
5298
|
-
|
|
5299
|
-
|
|
5300
|
-
|
|
5301
|
-
|
|
5302
|
-
|
|
5303
|
-
|
|
4485
|
+
k as evalExpression,
|
|
4486
|
+
Br as getCurPosition,
|
|
4487
|
+
Fr as getDefaultOptionVal,
|
|
4488
|
+
kr as getExpectType,
|
|
4489
|
+
C as getJsonDataByKeyRoute,
|
|
4490
|
+
Mr as getNextIndexRoute,
|
|
4491
|
+
Ir as getParentIndexRoute,
|
|
4492
|
+
Gr as getParentIndexRoute_CurIndex,
|
|
5304
4493
|
tn as getParentKeyRoute,
|
|
5305
4494
|
rn as getParentKeyRoute_CurKey,
|
|
5306
|
-
|
|
4495
|
+
R as getSchemaByIndexRoute,
|
|
5307
4496
|
P as getSchemaByKeyRoute,
|
|
5308
|
-
|
|
5309
|
-
|
|
4497
|
+
V as hasProperties,
|
|
4498
|
+
U as indexRoute2keyRoute,
|
|
5310
4499
|
g as isArray,
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
4500
|
+
v as isBoolean,
|
|
4501
|
+
w as isColor,
|
|
4502
|
+
Ur as isContainerSchema,
|
|
4503
|
+
y as isDateStr,
|
|
5315
4504
|
b as isDateTimeStr,
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
4505
|
+
Rr as isEmptySchema,
|
|
4506
|
+
D as isEqual,
|
|
4507
|
+
A as isEqualByIdT,
|
|
5319
4508
|
_ as isFunction,
|
|
5320
4509
|
Pr as isNewSchemaData,
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
|
|
5324
|
-
|
|
4510
|
+
h as isNumber,
|
|
4511
|
+
E as isObject,
|
|
4512
|
+
N as isQuantity,
|
|
4513
|
+
Lr as isSameParent,
|
|
5325
4514
|
O as isSelect,
|
|
5326
4515
|
f as isString,
|
|
5327
|
-
|
|
4516
|
+
qr as isStructuredSchema,
|
|
5328
4517
|
m as isTimeStr,
|
|
5329
4518
|
d as isURL,
|
|
5330
|
-
|
|
4519
|
+
L as json2schema,
|
|
5331
4520
|
Qr as json2treeData,
|
|
5332
|
-
|
|
5333
|
-
|
|
4521
|
+
q as keyRoute2indexRoute,
|
|
4522
|
+
I as metaElemAnalyzer,
|
|
5334
4523
|
Kr as moveBackward,
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
4524
|
+
zr as moveForward,
|
|
4525
|
+
S as objClone,
|
|
4526
|
+
G as oldSchemaToNewSchema,
|
|
4527
|
+
M as oldSchemaToNewSchemaV1,
|
|
4528
|
+
Cr as registerExpectType,
|
|
5340
4529
|
en as schema2conditionValue,
|
|
5341
|
-
|
|
5342
|
-
|
|
4530
|
+
Xr as schema2json,
|
|
4531
|
+
$r as schemaMetaList,
|
|
5343
4532
|
T as truncate,
|
|
5344
4533
|
j as urlParse,
|
|
5345
|
-
|
|
4534
|
+
x as urlStringify,
|
|
5346
4535
|
};
|