@datagrok/helm 2.13.8 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/489.js +2 -0
- package/dist/489.js.map +1 -0
- package/dist/package-test.js +1 -1
- package/dist/package-test.js.map +1 -1
- package/dist/package.js +1 -1
- package/dist/package.js.map +1 -1
- package/files/samples/helm-showcase.csv +56 -0
- package/package.json +6 -10
- package/src/helm-helper.ts +61 -413
- package/src/package-api.ts +14 -11
- package/src/package-test.ts +0 -2
- package/src/package-utils.ts +8 -298
- package/src/package.g.ts +2 -8
- package/src/package.ts +11 -31
- package/src/tests/helm-activity-cliffs.ts +2 -2
- package/src/tests/helm-input-tests.ts +83 -0
- package/src/tests/parse-helm-tests.ts +7 -57
- package/src/tests/properties-widget-tests.ts +21 -11
- package/src/utils/helm-grid-cell-renderer.ts +141 -151
- package/src/utils/index.ts +3 -7
- package/src/widgets/helm-input.ts +42 -12
- package/src/widgets/properties-widget.ts +18 -11
- package/test-console-output-1.log +105 -714
- package/test-record-1.mp4 +0 -0
- package/webpack.config.js +1 -12
- package/dist/455.js +0 -2
- package/dist/455.js.map +0 -1
- package/dist/package-dojo.js +0 -2
- package/dist/package-dojo.js.map +0 -1
- package/helm/JSDraw/Pistoia.HELM-uncompressed.js +0 -9694
- package/helm/JSDraw/ReadMe.txt +0 -8
- package/helm/JSDraw/Scilligence.JSDraw2.Lite-uncompressed.js +0 -31126
- package/helm/dojo/package.ts +0 -41
- package/helm/dojo/types.ts +0 -12
- package/src/helm-web-editor.ts +0 -68
- package/src/tests/get-monomer-tests.ts +0 -214
- package/src/tests/helm-service-tests.ts +0 -98
- package/src/types/dojo.ts +0 -3
- package/src/types/index.ts +0 -5
- package/src/utils/get-monomer.ts +0 -90
- package/src/utils/helm-service.ts +0 -166
- package/vendor/dojo-1.10.10/dijit/BackgroundIframe.js +0 -63
- package/vendor/dojo-1.10.10/dijit/BackgroundIframe.js.uncompressed.js +0 -116
- package/vendor/dojo-1.10.10/dijit/Destroyable.js +0 -35
- package/vendor/dojo-1.10.10/dijit/Destroyable.js.uncompressed.js +0 -83
- package/vendor/dojo-1.10.10/dijit/Tooltip.js +0 -240
- package/vendor/dojo-1.10.10/dijit/Tooltip.js.uncompressed.js +0 -612
- package/vendor/dojo-1.10.10/dijit/Viewport.js +0 -44
- package/vendor/dojo-1.10.10/dijit/Viewport.js.uncompressed.js +0 -87
- package/vendor/dojo-1.10.10/dijit/WidgetSet.js +0 -76
- package/vendor/dojo-1.10.10/dijit/WidgetSet.js.uncompressed.js +0 -247
- package/vendor/dojo-1.10.10/dijit/_AttachMixin.js +0 -94
- package/vendor/dojo-1.10.10/dijit/_AttachMixin.js.uncompressed.js +0 -238
- package/vendor/dojo-1.10.10/dijit/_Contained.js +0 -17
- package/vendor/dojo-1.10.10/dijit/_Contained.js.uncompressed.js +0 -56
- package/vendor/dojo-1.10.10/dijit/_Container.js +0 -47
- package/vendor/dojo-1.10.10/dijit/_Container.js.uncompressed.js +0 -108
- package/vendor/dojo-1.10.10/dijit/_CssStateMixin.js +0 -198
- package/vendor/dojo-1.10.10/dijit/_CssStateMixin.js.uncompressed.js +0 -372
- package/vendor/dojo-1.10.10/dijit/_FocusMixin.js +0 -11
- package/vendor/dojo-1.10.10/dijit/_FocusMixin.js.uncompressed.js +0 -66
- package/vendor/dojo-1.10.10/dijit/_HasDropDown.js +0 -188
- package/vendor/dojo-1.10.10/dijit/_HasDropDown.js.uncompressed.js +0 -472
- package/vendor/dojo-1.10.10/dijit/_OnDijitClickMixin.js +0 -8
- package/vendor/dojo-1.10.10/dijit/_OnDijitClickMixin.js.uncompressed.js +0 -31
- package/vendor/dojo-1.10.10/dijit/_TemplatedMixin.js +0 -90
- package/vendor/dojo-1.10.10/dijit/_TemplatedMixin.js.uncompressed.js +0 -205
- package/vendor/dojo-1.10.10/dijit/_Widget.js +0 -66
- package/vendor/dojo-1.10.10/dijit/_Widget.js.uncompressed.js +0 -352
- package/vendor/dojo-1.10.10/dijit/_WidgetBase.js +0 -353
- package/vendor/dojo-1.10.10/dijit/_WidgetBase.js.uncompressed.js +0 -1200
- package/vendor/dojo-1.10.10/dijit/_base/focus.js +0 -68
- package/vendor/dojo-1.10.10/dijit/_base/focus.js.uncompressed.js +0 -207
- package/vendor/dojo-1.10.10/dijit/_base/manager.js +0 -10
- package/vendor/dojo-1.10.10/dijit/_base/manager.js.uncompressed.js +0 -35
- package/vendor/dojo-1.10.10/dijit/_base/place.js +0 -52
- package/vendor/dojo-1.10.10/dijit/_base/place.js.uncompressed.js +0 -131
- package/vendor/dojo-1.10.10/dijit/_base/popup.js +0 -23
- package/vendor/dojo-1.10.10/dijit/_base/popup.js.uncompressed.js +0 -58
- package/vendor/dojo-1.10.10/dijit/_base/scroll.js +0 -6
- package/vendor/dojo-1.10.10/dijit/_base/scroll.js.uncompressed.js +0 -22
- package/vendor/dojo-1.10.10/dijit/_base/sniff.js +0 -3
- package/vendor/dojo-1.10.10/dijit/_base/sniff.js.uncompressed.js +0 -12
- package/vendor/dojo-1.10.10/dijit/_base/typematic.js +0 -3
- package/vendor/dojo-1.10.10/dijit/_base/typematic.js.uncompressed.js +0 -10
- package/vendor/dojo-1.10.10/dijit/_base/wai.js +0 -32
- package/vendor/dojo-1.10.10/dijit/_base/wai.js.uncompressed.js +0 -109
- package/vendor/dojo-1.10.10/dijit/_base/window.js +0 -6
- package/vendor/dojo-1.10.10/dijit/_base/window.js.uncompressed.js +0 -18
- package/vendor/dojo-1.10.10/dijit/_base.js +0 -4
- package/vendor/dojo-1.10.10/dijit/_base.js.uncompressed.js +0 -27
- package/vendor/dojo-1.10.10/dijit/a11y.js +0 -109
- package/vendor/dojo-1.10.10/dijit/a11y.js.uncompressed.js +0 -191
- package/vendor/dojo-1.10.10/dijit/a11yclick.js +0 -66
- package/vendor/dojo-1.10.10/dijit/a11yclick.js.uncompressed.js +0 -139
- package/vendor/dojo-1.10.10/dijit/focus.js +0 -188
- package/vendor/dojo-1.10.10/dijit/focus.js.uncompressed.js +0 -371
- package/vendor/dojo-1.10.10/dijit/form/Button.js +0 -49
- package/vendor/dojo-1.10.10/dijit/form/Button.js.uncompressed.js +0 -130
- package/vendor/dojo-1.10.10/dijit/form/ComboBox.js +0 -4
- package/vendor/dojo-1.10.10/dijit/form/ComboBox.js.uncompressed.js +0 -27
- package/vendor/dojo-1.10.10/dijit/form/ComboButton.js +0 -21
- package/vendor/dojo-1.10.10/dijit/form/ComboButton.js.uncompressed.js +0 -86
- package/vendor/dojo-1.10.10/dijit/form/DropDownButton.js +0 -38
- package/vendor/dojo-1.10.10/dijit/form/DropDownButton.js.uncompressed.js +0 -102
- package/vendor/dojo-1.10.10/dijit/form/ToggleButton.js +0 -7
- package/vendor/dojo-1.10.10/dijit/form/ToggleButton.js.uncompressed.js +0 -26
- package/vendor/dojo-1.10.10/dijit/form/_ButtonMixin.js +0 -50
- package/vendor/dojo-1.10.10/dijit/form/_ButtonMixin.js.uncompressed.js +0 -116
- package/vendor/dojo-1.10.10/dijit/form/_FormValueMixin.js +0 -26
- package/vendor/dojo-1.10.10/dijit/form/_FormValueMixin.js.uncompressed.js +0 -81
- package/vendor/dojo-1.10.10/dijit/form/_FormValueWidget.js +0 -24
- package/vendor/dojo-1.10.10/dijit/form/_FormValueWidget.js.uncompressed.js +0 -51
- package/vendor/dojo-1.10.10/dijit/form/_FormWidget.js +0 -22
- package/vendor/dojo-1.10.10/dijit/form/_FormWidget.js.uncompressed.js +0 -67
- package/vendor/dojo-1.10.10/dijit/form/_FormWidgetMixin.js +0 -111
- package/vendor/dojo-1.10.10/dijit/form/_FormWidgetMixin.js.uncompressed.js +0 -254
- package/vendor/dojo-1.10.10/dijit/form/_ToggleButtonMixin.js +0 -32
- package/vendor/dojo-1.10.10/dijit/form/_ToggleButtonMixin.js.uncompressed.js +0 -69
- package/vendor/dojo-1.10.10/dijit/hccss.js +0 -9
- package/vendor/dojo-1.10.10/dijit/hccss.js.uncompressed.js +0 -21
- package/vendor/dojo-1.10.10/dijit/layout/AccordionContainer.js +0 -215
- package/vendor/dojo-1.10.10/dijit/layout/AccordionContainer.js.uncompressed.js +0 -550
- package/vendor/dojo-1.10.10/dijit/layout/AccordionPane.js +0 -7
- package/vendor/dojo-1.10.10/dijit/layout/AccordionPane.js.uncompressed.js +0 -25
- package/vendor/dojo-1.10.10/dijit/layout/ContentPane.js +0 -235
- package/vendor/dojo-1.10.10/dijit/layout/ContentPane.js.uncompressed.js +0 -653
- package/vendor/dojo-1.10.10/dijit/layout/StackContainer.js +0 -171
- package/vendor/dojo-1.10.10/dijit/layout/StackContainer.js.uncompressed.js +0 -411
- package/vendor/dojo-1.10.10/dijit/layout/StackController.js +0 -194
- package/vendor/dojo-1.10.10/dijit/layout/StackController.js.uncompressed.js +0 -410
- package/vendor/dojo-1.10.10/dijit/layout/_ContentPaneResizeMixin.js +0 -99
- package/vendor/dojo-1.10.10/dijit/layout/_ContentPaneResizeMixin.js.uncompressed.js +0 -236
- package/vendor/dojo-1.10.10/dijit/layout/_LayoutWidget.js +0 -47
- package/vendor/dojo-1.10.10/dijit/layout/_LayoutWidget.js.uncompressed.js +0 -190
- package/vendor/dojo-1.10.10/dijit/layout/utils.js +0 -77
- package/vendor/dojo-1.10.10/dijit/layout/utils.js.uncompressed.js +0 -151
- package/vendor/dojo-1.10.10/dijit/main.js +0 -4
- package/vendor/dojo-1.10.10/dijit/main.js.uncompressed.js +0 -16
- package/vendor/dojo-1.10.10/dijit/nls/dijit-all_en-us.js +0 -2
- package/vendor/dojo-1.10.10/dijit/nls/dijit-all_en-us.js.uncompressed.js +0 -21
- package/vendor/dojo-1.10.10/dijit/nls/loading.js +0 -2
- package/vendor/dojo-1.10.10/dijit/nls/loading.js.uncompressed.js +0 -47
- package/vendor/dojo-1.10.10/dijit/place.js +0 -142
- package/vendor/dojo-1.10.10/dijit/place.js.uncompressed.js +0 -407
- package/vendor/dojo-1.10.10/dijit/popup.js +0 -162
- package/vendor/dojo-1.10.10/dijit/popup.js.uncompressed.js +0 -441
- package/vendor/dojo-1.10.10/dijit/registry.js +0 -79
- package/vendor/dojo-1.10.10/dijit/registry.js.uncompressed.js +0 -159
- package/vendor/dojo-1.10.10/dijit/selection.js +0 -364
- package/vendor/dojo-1.10.10/dijit/selection.js.uncompressed.js +0 -525
- package/vendor/dojo-1.10.10/dijit/typematic.js +0 -96
- package/vendor/dojo-1.10.10/dijit/typematic.js.uncompressed.js +0 -211
- package/vendor/dojo-1.10.10/dojo/NodeList-manipulate.js +0 -195
- package/vendor/dojo-1.10.10/dojo/NodeList-manipulate.js.uncompressed.js +0 -761
- package/vendor/dojo-1.10.10/dojo/Stateful.js +0 -90
- package/vendor/dojo-1.10.10/dojo/Stateful.js.uncompressed.js +0 -218
- package/vendor/dojo-1.10.10/dojo/_base/url.js +0 -87
- package/vendor/dojo-1.10.10/dojo/_base/url.js.uncompressed.js +0 -109
- package/vendor/dojo-1.10.10/dojo/cache.js +0 -9
- package/vendor/dojo-1.10.10/dojo/cache.js.uncompressed.js +0 -7
- package/vendor/dojo-1.10.10/dojo/colors.js +0 -74
- package/vendor/dojo-1.10.10/dojo/colors.js.uncompressed.js +0 -232
- package/vendor/dojo-1.10.10/dojo/cookie.js +0 -48
- package/vendor/dojo-1.10.10/dojo/cookie.js.uncompressed.js +0 -98
- package/vendor/dojo-1.10.10/dojo/date/stamp.js +0 -82
- package/vendor/dojo-1.10.10/dojo/date/stamp.js.uncompressed.js +0 -144
- package/vendor/dojo-1.10.10/dojo/dojo.js +0 -7
- package/vendor/dojo-1.10.10/dojo/dojo.js.uncompressed.js +0 -18680
- package/vendor/dojo-1.10.10/dojo/fx/Toggler.js +0 -27
- package/vendor/dojo-1.10.10/dojo/fx/Toggler.js.uncompressed.js +0 -101
- package/vendor/dojo-1.10.10/dojo/fx/easing.js +0 -165
- package/vendor/dojo-1.10.10/dojo/fx/easing.js.uncompressed.js +0 -276
- package/vendor/dojo-1.10.10/dojo/fx.js +0 -271
- package/vendor/dojo-1.10.10/dojo/fx.js.uncompressed.js +0 -443
- package/vendor/dojo-1.10.10/dojo/hccss.js +0 -26
- package/vendor/dojo-1.10.10/dojo/hccss.js.uncompressed.js +0 -52
- package/vendor/dojo-1.10.10/dojo/html.js +0 -161
- package/vendor/dojo-1.10.10/dojo/html.js.uncompressed.js +0 -370
- package/vendor/dojo-1.10.10/dojo/io/iframe.js +0 -71
- package/vendor/dojo-1.10.10/dojo/io/iframe.js.uncompressed.js +0 -190
- package/vendor/dojo-1.10.10/dojo/io/script.js +0 -112
- package/vendor/dojo-1.10.10/dojo/io/script.js.uncompressed.js +0 -280
- package/vendor/dojo-1.10.10/dojo/parser.js +0 -437
- package/vendor/dojo-1.10.10/dojo/parser.js.uncompressed.js +0 -915
- package/vendor/dojo-1.10.10/dojo/promise/all.js +0 -59
- package/vendor/dojo-1.10.10/dojo/promise/all.js.uncompressed.js +0 -77
- package/vendor/dojo-1.10.10/dojo/regexp.js +0 -32
- package/vendor/dojo-1.10.10/dojo/regexp.js.uncompressed.js +0 -70
- package/vendor/dojo-1.10.10/dojo/request/iframe.js +0 -291
- package/vendor/dojo-1.10.10/dojo/request/iframe.js.uncompressed.js +0 -438
- package/vendor/dojo-1.10.10/dojo/request/script.js +0 -129
- package/vendor/dojo-1.10.10/dojo/request/script.js.uncompressed.js +0 -237
- package/vendor/dojo-1.10.10/dojo/require.js +0 -11
- package/vendor/dojo-1.10.10/dojo/require.js.uncompressed.js +0 -7
- package/vendor/dojo-1.10.10/dojo/resources/blank.gif +0 -0
- package/vendor/dojo-1.10.10/dojo/string.js +0 -67
- package/vendor/dojo-1.10.10/dojo/string.js.uncompressed.js +0 -181
- package/vendor/dojo-1.10.10/dojo/touch.js +0 -191
- package/vendor/dojo-1.10.10/dojo/touch.js.uncompressed.js +0 -468
- package/vendor/dojo-1.10.10/dojo/uacss.js +0 -36
- package/vendor/dojo-1.10.10/dojo/uacss.js.uncompressed.js +0 -85
- package/vendor/dojo-1.10.10/dojo/window.js +0 -141
- package/vendor/dojo-1.10.10/dojo/window.js.uncompressed.js +0 -241
- package/vendor/dojo-1.10.10/dojox/charting/Chart.js +0 -626
- package/vendor/dojo-1.10.10/dojox/charting/Chart.js.uncompressed.js +0 -1220
- package/vendor/dojo-1.10.10/dojox/charting/Chart2D.js +0 -5
- package/vendor/dojo-1.10.10/dojox/charting/Chart2D.js.uncompressed.js +0 -16
- package/vendor/dojo-1.10.10/dojox/charting/Element.js +0 -247
- package/vendor/dojo-1.10.10/dojox/charting/Element.js.uncompressed.js +0 -402
- package/vendor/dojo-1.10.10/dojox/charting/Series.js +0 -24
- package/vendor/dojo-1.10.10/dojox/charting/Series.js.uncompressed.js +0 -58
- package/vendor/dojo-1.10.10/dojox/charting/SimpleTheme.js +0 -191
- package/vendor/dojo-1.10.10/dojox/charting/SimpleTheme.js.uncompressed.js +0 -577
- package/vendor/dojo-1.10.10/dojox/charting/Theme.js +0 -42
- package/vendor/dojo-1.10.10/dojox/charting/Theme.js.uncompressed.js +0 -120
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Base.js +0 -11
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Base.js.uncompressed.js +0 -36
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Highlight.js +0 -77
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Highlight.js.uncompressed.js +0 -144
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Magnify.js +0 -58
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Magnify.js.uncompressed.js +0 -123
- package/vendor/dojo-1.10.10/dojox/charting/action2d/MoveSlice.js +0 -54
- package/vendor/dojo-1.10.10/dojox/charting/action2d/MoveSlice.js.uncompressed.js +0 -124
- package/vendor/dojo-1.10.10/dojox/charting/action2d/PlotAction.js +0 -28
- package/vendor/dojo-1.10.10/dojox/charting/action2d/PlotAction.js.uncompressed.js +0 -74
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Tooltip.js +0 -116
- package/vendor/dojo-1.10.10/dojox/charting/action2d/Tooltip.js.uncompressed.js +0 -178
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Base.js +0 -24
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Base.js.uncompressed.js +0 -83
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Default.js +0 -557
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Default.js.uncompressed.js +0 -980
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Invisible.js +0 -65
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/Invisible.js.uncompressed.js +0 -224
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/common.js +0 -91
- package/vendor/dojo-1.10.10/dojox/charting/axis2d/common.js.uncompressed.js +0 -164
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Areas.js +0 -7
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Areas.js.uncompressed.js +0 -14
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bars.js +0 -168
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bars.js.uncompressed.js +0 -311
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Base.js +0 -61
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Base.js.uncompressed.js +0 -161
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bubble.js +0 -141
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bubble.js.uncompressed.js +0 -242
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Candlesticks.js +0 -126
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Candlesticks.js.uncompressed.js +0 -243
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/CartesianBase.js +0 -108
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/CartesianBase.js.uncompressed.js +0 -290
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredBars.js +0 -13
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredBars.js.uncompressed.js +0 -14
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredColumns.js +0 -13
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredColumns.js.uncompressed.js +0 -14
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Columns.js +0 -153
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Columns.js.uncompressed.js +0 -249
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Default.js +0 -253
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Default.js.uncompressed.js +0 -472
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Grid.js +0 -182
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Grid.js.uncompressed.js +0 -356
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Lines.js +0 -6
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Lines.js.uncompressed.js +0 -12
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Markers.js +0 -6
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Markers.js.uncompressed.js +0 -12
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/MarkersOnly.js +0 -7
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/MarkersOnly.js.uncompressed.js +0 -13
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/OHLC.js +0 -110
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/OHLC.js.uncompressed.js +0 -208
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Pie.js +0 -303
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Pie.js.uncompressed.js +0 -547
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Scatter.js +0 -134
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Scatter.js.uncompressed.js +0 -207
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Spider.js +0 -299
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Spider.js.uncompressed.js +0 -537
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Stacked.js +0 -24
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/Stacked.js.uncompressed.js +0 -44
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedAreas.js +0 -7
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedAreas.js.uncompressed.js +0 -14
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedBars.js +0 -22
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedBars.js.uncompressed.js +0 -33
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedColumns.js +0 -20
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedColumns.js.uncompressed.js +0 -31
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedLines.js +0 -6
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedLines.js.uncompressed.js +0 -12
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/_PlotEvents.js +0 -68
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/_PlotEvents.js.uncompressed.js +0 -120
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/common.js +0 -209
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/common.js.uncompressed.js +0 -214
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/commonStacked.js +0 -76
- package/vendor/dojo-1.10.10/dojox/charting/plot2d/commonStacked.js.uncompressed.js +0 -77
- package/vendor/dojo-1.10.10/dojox/charting/scaler/common.js +0 -59
- package/vendor/dojo-1.10.10/dojox/charting/scaler/common.js.uncompressed.js +0 -70
- package/vendor/dojo-1.10.10/dojox/charting/scaler/linear.js +0 -220
- package/vendor/dojo-1.10.10/dojox/charting/scaler/linear.js.uncompressed.js +0 -262
- package/vendor/dojo-1.10.10/dojox/charting/scaler/primitive.js +0 -23
- package/vendor/dojo-1.10.10/dojox/charting/scaler/primitive.js.uncompressed.js +0 -36
- package/vendor/dojo-1.10.10/dojox/charting/themes/Claro.js +0 -39
- package/vendor/dojo-1.10.10/dojox/charting/themes/Claro.js.uncompressed.js +0 -106
- package/vendor/dojo-1.10.10/dojox/charting/themes/Wetland.js +0 -5
- package/vendor/dojo-1.10.10/dojox/charting/themes/Wetland.js.uncompressed.js +0 -12
- package/vendor/dojo-1.10.10/dojox/charting/themes/common.js +0 -4
- package/vendor/dojo-1.10.10/dojox/charting/themes/common.js.uncompressed.js +0 -3
- package/vendor/dojo-1.10.10/dojox/charting/widget/Legend.js +0 -102
- package/vendor/dojo-1.10.10/dojox/charting/widget/Legend.js.uncompressed.js +0 -165
- package/vendor/dojo-1.10.10/dojox/color/Palette.js +0 -163
- package/vendor/dojo-1.10.10/dojox/color/Palette.js.uncompressed.js +0 -460
- package/vendor/dojo-1.10.10/dojox/color/_base.js +0 -174
- package/vendor/dojo-1.10.10/dojox/color/_base.js.uncompressed.js +0 -196
- package/vendor/dojo-1.10.10/dojox/gfx/_base.js +0 -253
- package/vendor/dojo-1.10.10/dojox/gfx/_base.js.uncompressed.js +0 -1024
- package/vendor/dojo-1.10.10/dojox/gfx/fx.js +0 -297
- package/vendor/dojo-1.10.10/dojox/gfx/fx.js.uncompressed.js +0 -350
- package/vendor/dojo-1.10.10/dojox/gfx/gradutils.js +0 -63
- package/vendor/dojo-1.10.10/dojox/gfx/gradutils.js.uncompressed.js +0 -91
- package/vendor/dojo-1.10.10/dojox/gfx/matrix.js +0 -170
- package/vendor/dojo-1.10.10/dojox/gfx/matrix.js.uncompressed.js +0 -501
- package/vendor/dojo-1.10.10/dojox/gfx/path.js +0 -319
- package/vendor/dojo-1.10.10/dojox/gfx/path.js.uncompressed.js +0 -478
- package/vendor/dojo-1.10.10/dojox/gfx/shape.js +0 -459
- package/vendor/dojo-1.10.10/dojox/gfx/shape.js.uncompressed.js +0 -1091
- package/vendor/dojo-1.10.10/dojox/gfx/svg.js +0 -662
- package/vendor/dojo-1.10.10/dojox/gfx/svg.js.uncompressed.js +0 -1023
- package/vendor/dojo-1.10.10/dojox/gfx/utils.js +0 -199
- package/vendor/dojo-1.10.10/dojox/gfx/utils.js.uncompressed.js +0 -322
- package/vendor/dojo-1.10.10/dojox/gfx.js +0 -2
- package/vendor/dojo-1.10.10/dojox/gfx.js.uncompressed.js +0 -1136
- package/vendor/dojo-1.10.10/dojox/lang/functional/array.js +0 -151
- package/vendor/dojo-1.10.10/dojox/lang/functional/array.js.uncompressed.js +0 -169
- package/vendor/dojo-1.10.10/dojox/lang/functional/fold.js +0 -93
- package/vendor/dojo-1.10.10/dojox/lang/functional/fold.js.uncompressed.js +0 -125
- package/vendor/dojo-1.10.10/dojox/lang/functional/lambda.js +0 -81
- package/vendor/dojo-1.10.10/dojox/lang/functional/lambda.js.uncompressed.js +0 -132
- package/vendor/dojo-1.10.10/dojox/lang/functional/object.js +0 -54
- package/vendor/dojo-1.10.10/dojox/lang/functional/object.js.uncompressed.js +0 -78
- package/vendor/dojo-1.10.10/dojox/lang/functional/reversed.js +0 -61
- package/vendor/dojo-1.10.10/dojox/lang/functional/reversed.js.uncompressed.js +0 -77
- package/vendor/dojo-1.10.10/dojox/lang/functional/scan.js +0 -87
- package/vendor/dojo-1.10.10/dojox/lang/functional/scan.js.uncompressed.js +0 -107
- package/vendor/dojo-1.10.10/dojox/lang/functional.js +0 -4
- package/vendor/dojo-1.10.10/dojox/lang/functional.js.uncompressed.js +0 -3
- package/vendor/dojo-1.10.10/dojox/lang/utils.js +0 -86
- package/vendor/dojo-1.10.10/dojox/lang/utils.js.uncompressed.js +0 -121
- package/vendor/dojo-1.10.10/dojox/main.js +0 -4
- package/vendor/dojo-1.10.10/dojox/main.js.uncompressed.js +0 -14
- package/vendor/dojo-1.10.10/dojox/storage/LocalStorageProvider.js +0 -112
- package/vendor/dojo-1.10.10/dojox/storage/LocalStorageProvider.js.uncompressed.js +0 -208
- package/vendor/dojo-1.10.10/dojox/storage/Provider.js +0 -62
- package/vendor/dojo-1.10.10/dojox/storage/Provider.js.uncompressed.js +0 -344
- package/vendor/dojo-1.10.10/dojox/storage/manager.js +0 -110
- package/vendor/dojo-1.10.10/dojox/storage/manager.js.uncompressed.js +0 -263
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
define("dojo/io/iframe", [
|
|
2
|
-
"../_base/config", "../_base/json", "../_base/kernel", /*===== "../_base/declare", =====*/ "../_base/lang",
|
|
3
|
-
"../_base/xhr", "../sniff", "../_base/window",
|
|
4
|
-
"../dom", "../dom-construct", "../query", "require", "../aspect", "../request/iframe"
|
|
5
|
-
], function(config, json, kernel, /*===== declare, =====*/ lang, xhr, has, win, dom, domConstruct, query, require, aspect, _iframe){
|
|
6
|
-
|
|
7
|
-
// module:
|
|
8
|
-
// dojo/io/iframe
|
|
9
|
-
|
|
10
|
-
kernel.deprecated("dojo/io/iframe", "Use dojo/request/iframe.", "2.0");
|
|
11
|
-
|
|
12
|
-
/*=====
|
|
13
|
-
var __ioArgs = declare(kernel.__IoArgs, {
|
|
14
|
-
// method: String?
|
|
15
|
-
// The HTTP method to use. "GET" or "POST" are the only supported
|
|
16
|
-
// values. It will try to read the value from the form node's
|
|
17
|
-
// method, then try this argument. If neither one exists, then it
|
|
18
|
-
// defaults to POST.
|
|
19
|
-
// handleAs: String?
|
|
20
|
-
// Specifies what format the result data should be given to the
|
|
21
|
-
// load/handle callback. Valid values are: text, html, xml, json,
|
|
22
|
-
// javascript. IMPORTANT: For all values EXCEPT html and xml, The
|
|
23
|
-
// server response should be an HTML file with a textarea element.
|
|
24
|
-
// The response data should be inside the textarea element. Using an
|
|
25
|
-
// HTML document the only reliable, cross-browser way this
|
|
26
|
-
// transport can know when the response has loaded. For the html
|
|
27
|
-
// handleAs value, just return a normal HTML document. NOTE: xml
|
|
28
|
-
// is now supported with this transport (as of 1.1+); a known issue
|
|
29
|
-
// is if the XML document in question is malformed, Internet Explorer
|
|
30
|
-
// will throw an uncatchable error.
|
|
31
|
-
// content: Object?
|
|
32
|
-
// If "form" is one of the other args properties, then the content
|
|
33
|
-
// object properties become hidden form form elements. For
|
|
34
|
-
// instance, a content object of {name1 : "value1"} is converted
|
|
35
|
-
// to a hidden form element with a name of "name1" and a value of
|
|
36
|
-
// "value1". If there is not a "form" property, then the content
|
|
37
|
-
// object is converted into a name=value&name=value string, by
|
|
38
|
-
// using xhr.objectToQuery().
|
|
39
|
-
});
|
|
40
|
-
=====*/
|
|
41
|
-
|
|
42
|
-
/*=====
|
|
43
|
-
return kernel.io.iframe = {
|
|
44
|
-
// summary:
|
|
45
|
-
// Deprecated, use dojo/request/iframe instead.
|
|
46
|
-
// Sends an Ajax I/O call using and Iframe (for instance, to upload files)
|
|
47
|
-
|
|
48
|
-
create: function(fname, onloadstr, uri){
|
|
49
|
-
// summary:
|
|
50
|
-
// Creates a hidden iframe in the page. Used mostly for IO
|
|
51
|
-
// transports. You do not need to call this to start a
|
|
52
|
-
// dojo/io/iframe request. Just call send().
|
|
53
|
-
// fname: String
|
|
54
|
-
// The name of the iframe. Used for the name attribute on the
|
|
55
|
-
// iframe.
|
|
56
|
-
// onloadstr: String
|
|
57
|
-
// A string of JavaScript that will be executed when the content
|
|
58
|
-
// in the iframe loads.
|
|
59
|
-
// uri: String
|
|
60
|
-
// The value of the src attribute on the iframe element. If a
|
|
61
|
-
// value is not given, then dojo/resources/blank.html will be
|
|
62
|
-
// used.
|
|
63
|
-
},
|
|
64
|
-
setSrc: function(iframe, src, replace){
|
|
65
|
-
// summary:
|
|
66
|
-
// Sets the URL that is loaded in an IFrame. The replace parameter
|
|
67
|
-
// indicates whether location.replace() should be used when
|
|
68
|
-
// changing the location of the iframe.
|
|
69
|
-
},
|
|
70
|
-
doc: function(iframeNode){
|
|
71
|
-
// summary:
|
|
72
|
-
// Returns the document object associated with the iframe DOM Node argument.
|
|
73
|
-
}
|
|
74
|
-
};
|
|
75
|
-
=====*/
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
var mid = _iframe._iframeName;
|
|
79
|
-
mid = mid.substring(0, mid.lastIndexOf('_'));
|
|
80
|
-
|
|
81
|
-
var iframe = lang.delegate(_iframe, {
|
|
82
|
-
// summary:
|
|
83
|
-
// Deprecated, use dojo/request/iframe instead.
|
|
84
|
-
// Sends an Ajax I/O call using and Iframe (for instance, to upload files)
|
|
85
|
-
|
|
86
|
-
create: function(){
|
|
87
|
-
return iframe._frame = _iframe.create.apply(_iframe, arguments);
|
|
88
|
-
},
|
|
89
|
-
|
|
90
|
-
// cover up delegated methods
|
|
91
|
-
get: null,
|
|
92
|
-
post: null,
|
|
93
|
-
|
|
94
|
-
send: function(/*__ioArgs*/args){
|
|
95
|
-
// summary:
|
|
96
|
-
// Function that sends the request to the server.
|
|
97
|
-
// This transport can only process one send() request at a time, so if send() is called
|
|
98
|
-
// multiple times, it will queue up the calls and only process one at a time.
|
|
99
|
-
var rDfd;
|
|
100
|
-
|
|
101
|
-
//Set up the deferred.
|
|
102
|
-
var dfd = xhr._ioSetArgs(args,
|
|
103
|
-
function(/*Deferred*/dfd){
|
|
104
|
-
// summary:
|
|
105
|
-
// canceller function for xhr._ioSetArgs call.
|
|
106
|
-
rDfd && rDfd.cancel();
|
|
107
|
-
},
|
|
108
|
-
function(/*Deferred*/dfd){
|
|
109
|
-
// summary:
|
|
110
|
-
// okHandler function for xhr._ioSetArgs call.
|
|
111
|
-
var value = null,
|
|
112
|
-
ioArgs = dfd.ioArgs;
|
|
113
|
-
try{
|
|
114
|
-
var handleAs = ioArgs.handleAs;
|
|
115
|
-
|
|
116
|
-
//Assign correct value based on handleAs value.
|
|
117
|
-
if(handleAs === "xml" || handleAs === "html"){
|
|
118
|
-
value = rDfd.response.data;
|
|
119
|
-
}else{
|
|
120
|
-
value = rDfd.response.text;
|
|
121
|
-
if(handleAs === "json"){
|
|
122
|
-
value = json.fromJson(value);
|
|
123
|
-
}else if(handleAs === "javascript"){
|
|
124
|
-
value = kernel.eval(value);
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
}catch(e){
|
|
128
|
-
value = e;
|
|
129
|
-
}
|
|
130
|
-
return value;
|
|
131
|
-
},
|
|
132
|
-
function(/*Error*/error, /*Deferred*/dfd){
|
|
133
|
-
// summary:
|
|
134
|
-
// errHandler function for xhr._ioSetArgs call.
|
|
135
|
-
dfd.ioArgs._hasError = true;
|
|
136
|
-
return error;
|
|
137
|
-
}
|
|
138
|
-
);
|
|
139
|
-
|
|
140
|
-
var ioArgs = dfd.ioArgs;
|
|
141
|
-
|
|
142
|
-
var method = "GET",
|
|
143
|
-
form = dom.byId(args.form);
|
|
144
|
-
if(args.method && args.method.toUpperCase() === "POST" && form){
|
|
145
|
-
method = "POST";
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
var options = {
|
|
149
|
-
method: method,
|
|
150
|
-
handleAs: args.handleAs === "json" || args.handleAs === "javascript" ? "text" : args.handleAs,
|
|
151
|
-
form: args.form,
|
|
152
|
-
query: form ? null : args.content,
|
|
153
|
-
data: form ? args.content : null,
|
|
154
|
-
timeout: args.timeout,
|
|
155
|
-
ioArgs: ioArgs
|
|
156
|
-
};
|
|
157
|
-
|
|
158
|
-
if(options.method){
|
|
159
|
-
options.method = options.method.toUpperCase();
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
if(config.ioPublish && kernel.publish && ioArgs.args.ioPublish !== false){
|
|
163
|
-
var start = aspect.after(_iframe, "_notifyStart", function(data){
|
|
164
|
-
if(data.options.ioArgs === ioArgs){
|
|
165
|
-
start.remove();
|
|
166
|
-
xhr._ioNotifyStart(dfd);
|
|
167
|
-
}
|
|
168
|
-
}, true);
|
|
169
|
-
}
|
|
170
|
-
rDfd = _iframe(ioArgs.url, options, true);
|
|
171
|
-
|
|
172
|
-
ioArgs._callNext = rDfd._callNext;
|
|
173
|
-
|
|
174
|
-
rDfd.then(function(){
|
|
175
|
-
dfd.resolve(dfd);
|
|
176
|
-
}).otherwise(function(error){
|
|
177
|
-
dfd.ioArgs.error = error;
|
|
178
|
-
dfd.reject(error);
|
|
179
|
-
});
|
|
180
|
-
|
|
181
|
-
return dfd;
|
|
182
|
-
},
|
|
183
|
-
|
|
184
|
-
_iframeOnload: win.global[mid + '_onload']
|
|
185
|
-
});
|
|
186
|
-
|
|
187
|
-
lang.setObject("dojo.io.iframe", iframe);
|
|
188
|
-
|
|
189
|
-
return iframe;
|
|
190
|
-
});
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright (c) 2004-2017, The JS Foundation All Rights Reserved.
|
|
3
|
-
Available via Academic Free License >= 2.1 OR the modified BSD license.
|
|
4
|
-
see: http://dojotoolkit.org/license for details
|
|
5
|
-
*/
|
|
6
|
-
//>>built
|
|
7
|
-
define("dojo/io/script",["../_base/connect","../_base/kernel","../_base/lang","../sniff","../_base/window","../_base/xhr","../dom","../dom-construct","../request/script","../aspect"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a){
|
|
8
|
-
_2.deprecated("dojo/io/script","Use dojo/request/script.","2.0");
|
|
9
|
-
var _b={get:function(_c){
|
|
10
|
-
var _d;
|
|
11
|
-
var _e=this._makeScriptDeferred(_c,function(_f){
|
|
12
|
-
_d&&_d.cancel();
|
|
13
|
-
});
|
|
14
|
-
var _10=_e.ioArgs;
|
|
15
|
-
_6._ioAddQueryToUrl(_10);
|
|
16
|
-
_6._ioNotifyStart(_e);
|
|
17
|
-
_d=_9.get(_10.url,{timeout:_c.timeout,jsonp:_10.jsonp,checkString:_c.checkString,ioArgs:_10,frameDoc:_c.frameDoc,canAttach:function(_11){
|
|
18
|
-
_10.requestId=_11.id;
|
|
19
|
-
_10.scriptId=_11.scriptId;
|
|
20
|
-
_10.canDelete=_11.canDelete;
|
|
21
|
-
return _b._canAttach(_10);
|
|
22
|
-
}},true);
|
|
23
|
-
_a.around(_d,"isValid",function(_12){
|
|
24
|
-
return function(_13){
|
|
25
|
-
_b._validCheck(_e);
|
|
26
|
-
return _12.call(this,_13);
|
|
27
|
-
};
|
|
28
|
-
});
|
|
29
|
-
_d.then(function(){
|
|
30
|
-
_e.resolve(_e);
|
|
31
|
-
}).otherwise(function(_14){
|
|
32
|
-
_e.ioArgs.error=_14;
|
|
33
|
-
_e.reject(_14);
|
|
34
|
-
});
|
|
35
|
-
return _e;
|
|
36
|
-
},attach:_9._attach,remove:_9._remove,_makeScriptDeferred:function(_15,_16){
|
|
37
|
-
var dfd=_6._ioSetArgs(_15,_16||this._deferredCancel,this._deferredOk,this._deferredError);
|
|
38
|
-
var _17=dfd.ioArgs;
|
|
39
|
-
_17.id=_2._scopeName+"IoScript"+(this._counter++);
|
|
40
|
-
_17.canDelete=false;
|
|
41
|
-
_17.jsonp=_15.callbackParamName||_15.jsonp;
|
|
42
|
-
if(_17.jsonp){
|
|
43
|
-
_17.query=_17.query||"";
|
|
44
|
-
if(_17.query.length>0){
|
|
45
|
-
_17.query+="&";
|
|
46
|
-
}
|
|
47
|
-
_17.query+=_17.jsonp+"="+(_15.frameDoc?"parent.":"")+_2._scopeName+".io.script.jsonp_"+_17.id+"._jsonpCallback";
|
|
48
|
-
_17.frameDoc=_15.frameDoc;
|
|
49
|
-
_17.canDelete=true;
|
|
50
|
-
dfd._jsonpCallback=this._jsonpCallback;
|
|
51
|
-
this["jsonp_"+_17.id]=dfd;
|
|
52
|
-
}
|
|
53
|
-
dfd.addBoth(function(_18){
|
|
54
|
-
if(_17.canDelete){
|
|
55
|
-
if(_18 instanceof Error){
|
|
56
|
-
_b["jsonp_"+_17.id]._jsonpCallback=function(){
|
|
57
|
-
delete _b["jsonp_"+_17.id];
|
|
58
|
-
if(_17.requestId){
|
|
59
|
-
_2.global[_9._callbacksProperty][_17.requestId]();
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
}else{
|
|
63
|
-
_b._addDeadScript(_17);
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
});
|
|
67
|
-
return dfd;
|
|
68
|
-
},_deferredCancel:function(dfd){
|
|
69
|
-
dfd.canceled=true;
|
|
70
|
-
},_deferredOk:function(dfd){
|
|
71
|
-
var _19=dfd.ioArgs;
|
|
72
|
-
return _19.json||_19.scriptLoaded||_19;
|
|
73
|
-
},_deferredError:function(_1a,dfd){
|
|
74
|
-
return _1a;
|
|
75
|
-
},_deadScripts:[],_counter:1,_addDeadScript:function(_1b){
|
|
76
|
-
_b._deadScripts.push({id:_1b.id,frameDoc:_1b.frameDoc});
|
|
77
|
-
_1b.frameDoc=null;
|
|
78
|
-
},_validCheck:function(dfd){
|
|
79
|
-
var _1c=_b._deadScripts;
|
|
80
|
-
if(_1c&&_1c.length>0){
|
|
81
|
-
for(var i=0;i<_1c.length;i++){
|
|
82
|
-
_b.remove(_1c[i].id,_1c[i].frameDoc);
|
|
83
|
-
delete _b["jsonp_"+_1c[i].id];
|
|
84
|
-
_1c[i].frameDoc=null;
|
|
85
|
-
}
|
|
86
|
-
_b._deadScripts=[];
|
|
87
|
-
}
|
|
88
|
-
return true;
|
|
89
|
-
},_ioCheck:function(dfd){
|
|
90
|
-
var _1d=dfd.ioArgs;
|
|
91
|
-
if(_1d.json||(_1d.scriptLoaded&&!_1d.args.checkString)){
|
|
92
|
-
return true;
|
|
93
|
-
}
|
|
94
|
-
var _1e=_1d.args.checkString;
|
|
95
|
-
return _1e&&eval("typeof("+_1e+") != 'undefined'");
|
|
96
|
-
},_resHandle:function(dfd){
|
|
97
|
-
if(_b._ioCheck(dfd)){
|
|
98
|
-
dfd.callback(dfd);
|
|
99
|
-
}else{
|
|
100
|
-
dfd.errback(new Error("inconceivable dojo.io.script._resHandle error"));
|
|
101
|
-
}
|
|
102
|
-
},_canAttach:function(){
|
|
103
|
-
return true;
|
|
104
|
-
},_jsonpCallback:function(_1f){
|
|
105
|
-
this.ioArgs.json=_1f;
|
|
106
|
-
if(this.ioArgs.requestId){
|
|
107
|
-
_2.global[_9._callbacksProperty][this.ioArgs.requestId](_1f);
|
|
108
|
-
}
|
|
109
|
-
}};
|
|
110
|
-
_3.setObject("dojo.io.script",_b);
|
|
111
|
-
return _b;
|
|
112
|
-
});
|
|
@@ -1,280 +0,0 @@
|
|
|
1
|
-
define("dojo/io/script", [
|
|
2
|
-
"../_base/connect", /*===== "../_base/declare", =====*/ "../_base/kernel", "../_base/lang",
|
|
3
|
-
"../sniff", "../_base/window","../_base/xhr",
|
|
4
|
-
"../dom", "../dom-construct", "../request/script", "../aspect"
|
|
5
|
-
], function(connect, /*===== declare, =====*/ kernel, lang, has, win, xhr, dom, domConstruct, _script, aspect){
|
|
6
|
-
|
|
7
|
-
// module:
|
|
8
|
-
// dojo/io/script
|
|
9
|
-
|
|
10
|
-
kernel.deprecated("dojo/io/script", "Use dojo/request/script.", "2.0");
|
|
11
|
-
|
|
12
|
-
/*=====
|
|
13
|
-
var __ioArgs = declare(kernel.__IoArgs, {
|
|
14
|
-
// summary:
|
|
15
|
-
// All the properties described in the dojo.__ioArgs type, apply to this
|
|
16
|
-
// type as well, EXCEPT "handleAs". It is not applicable to
|
|
17
|
-
// dojo/io/script.get() calls, since it is implied by the usage of
|
|
18
|
-
// "jsonp" (response will be a JSONP call returning JSON)
|
|
19
|
-
// or the response is pure JavaScript defined in
|
|
20
|
-
// the body of the script that was attached.
|
|
21
|
-
// callbackParamName: String
|
|
22
|
-
// Deprecated as of Dojo 1.4 in favor of "jsonp", but still supported for
|
|
23
|
-
// legacy code. See notes for jsonp property.
|
|
24
|
-
// jsonp: String
|
|
25
|
-
// The URL parameter name that indicates the JSONP callback string.
|
|
26
|
-
// For instance, when using Yahoo JSONP calls it is normally,
|
|
27
|
-
// jsonp: "callback". For AOL JSONP calls it is normally
|
|
28
|
-
// jsonp: "c".
|
|
29
|
-
// checkString: String
|
|
30
|
-
// A string of JavaScript that when evaluated like so:
|
|
31
|
-
// "typeof(" + checkString + ") != 'undefined'"
|
|
32
|
-
// being true means that the script fetched has been loaded.
|
|
33
|
-
// Do not use this if doing a JSONP type of call (use callbackParamName instead).
|
|
34
|
-
// frameDoc: Document
|
|
35
|
-
// The Document object for a child iframe. If this is passed in, the script
|
|
36
|
-
// will be attached to that document. This can be helpful in some comet long-polling
|
|
37
|
-
// scenarios with Firefox and Opera.
|
|
38
|
-
});
|
|
39
|
-
=====*/
|
|
40
|
-
|
|
41
|
-
var script = {
|
|
42
|
-
// summary:
|
|
43
|
-
// TODOC
|
|
44
|
-
|
|
45
|
-
get: function(/*__ioArgs*/ args){
|
|
46
|
-
// summary:
|
|
47
|
-
// sends a get request using a dynamically created script tag.
|
|
48
|
-
var rDfd;
|
|
49
|
-
var dfd = this._makeScriptDeferred(args, function(dfd){
|
|
50
|
-
rDfd && rDfd.cancel();
|
|
51
|
-
});
|
|
52
|
-
var ioArgs = dfd.ioArgs;
|
|
53
|
-
xhr._ioAddQueryToUrl(ioArgs);
|
|
54
|
-
|
|
55
|
-
xhr._ioNotifyStart(dfd);
|
|
56
|
-
|
|
57
|
-
rDfd = _script.get(ioArgs.url, {
|
|
58
|
-
timeout: args.timeout,
|
|
59
|
-
jsonp: ioArgs.jsonp,
|
|
60
|
-
checkString: args.checkString,
|
|
61
|
-
ioArgs: ioArgs,
|
|
62
|
-
frameDoc: args.frameDoc,
|
|
63
|
-
canAttach: function(rDfd){
|
|
64
|
-
// sync values
|
|
65
|
-
ioArgs.requestId = rDfd.id;
|
|
66
|
-
ioArgs.scriptId = rDfd.scriptId;
|
|
67
|
-
ioArgs.canDelete = rDfd.canDelete;
|
|
68
|
-
|
|
69
|
-
return script._canAttach(ioArgs);
|
|
70
|
-
}
|
|
71
|
-
}, true);
|
|
72
|
-
|
|
73
|
-
// Run _validCheck at the same time dojo/request/watch runs the
|
|
74
|
-
// rDfd.isValid function
|
|
75
|
-
aspect.around(rDfd, "isValid", function(isValid){
|
|
76
|
-
return function(response){
|
|
77
|
-
script._validCheck(dfd);
|
|
78
|
-
return isValid.call(this, response);
|
|
79
|
-
};
|
|
80
|
-
});
|
|
81
|
-
|
|
82
|
-
rDfd.then(function(){
|
|
83
|
-
dfd.resolve(dfd);
|
|
84
|
-
}).otherwise(function(error){
|
|
85
|
-
dfd.ioArgs.error = error;
|
|
86
|
-
dfd.reject(error);
|
|
87
|
-
});
|
|
88
|
-
|
|
89
|
-
return dfd;
|
|
90
|
-
},
|
|
91
|
-
|
|
92
|
-
attach: _script._attach,
|
|
93
|
-
remove: _script._remove,
|
|
94
|
-
|
|
95
|
-
_makeScriptDeferred: function(/*Object*/ args, /*Function?*/ cancel){
|
|
96
|
-
// summary:
|
|
97
|
-
// sets up a Deferred object for an IO request.
|
|
98
|
-
var dfd = xhr._ioSetArgs(args, cancel || this._deferredCancel, this._deferredOk, this._deferredError);
|
|
99
|
-
|
|
100
|
-
var ioArgs = dfd.ioArgs;
|
|
101
|
-
ioArgs.id = kernel._scopeName + "IoScript" + (this._counter++);
|
|
102
|
-
ioArgs.canDelete = false;
|
|
103
|
-
|
|
104
|
-
//Special setup for jsonp case
|
|
105
|
-
ioArgs.jsonp = args.callbackParamName || args.jsonp;
|
|
106
|
-
if(ioArgs.jsonp){
|
|
107
|
-
//Add the jsonp parameter.
|
|
108
|
-
ioArgs.query = ioArgs.query || "";
|
|
109
|
-
if(ioArgs.query.length > 0){
|
|
110
|
-
ioArgs.query += "&";
|
|
111
|
-
}
|
|
112
|
-
ioArgs.query += ioArgs.jsonp +
|
|
113
|
-
"=" + (args.frameDoc ? "parent." : "") +
|
|
114
|
-
kernel._scopeName + ".io.script.jsonp_" + ioArgs.id + "._jsonpCallback";
|
|
115
|
-
|
|
116
|
-
ioArgs.frameDoc = args.frameDoc;
|
|
117
|
-
|
|
118
|
-
//Setup the Deferred to have the jsonp callback.
|
|
119
|
-
ioArgs.canDelete = true;
|
|
120
|
-
dfd._jsonpCallback = this._jsonpCallback;
|
|
121
|
-
this["jsonp_" + ioArgs.id] = dfd;
|
|
122
|
-
}
|
|
123
|
-
// Make sure this runs no matter what happens to clean things up if need be
|
|
124
|
-
dfd.addBoth(function(value){
|
|
125
|
-
if(ioArgs.canDelete){
|
|
126
|
-
if(value instanceof Error){
|
|
127
|
-
// Set up a callback that will clean things up for timeouts and cancels
|
|
128
|
-
script["jsonp_" + ioArgs.id]._jsonpCallback = function(){
|
|
129
|
-
// Delete the cached deferred
|
|
130
|
-
delete script["jsonp_" + ioArgs.id];
|
|
131
|
-
if(ioArgs.requestId){
|
|
132
|
-
// Call the dojo/request/script callback to clean itself up as well
|
|
133
|
-
kernel.global[_script._callbacksProperty][ioArgs.requestId]();
|
|
134
|
-
}
|
|
135
|
-
};
|
|
136
|
-
}else{
|
|
137
|
-
script._addDeadScript(ioArgs);
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
});
|
|
141
|
-
return dfd; // dojo/_base/Deferred
|
|
142
|
-
},
|
|
143
|
-
|
|
144
|
-
_deferredCancel: function(/*Deferred*/ dfd){
|
|
145
|
-
// summary:
|
|
146
|
-
// canceller function for xhr._ioSetArgs call.
|
|
147
|
-
|
|
148
|
-
//DO NOT use "this" and expect it to be script.
|
|
149
|
-
dfd.canceled = true;
|
|
150
|
-
},
|
|
151
|
-
|
|
152
|
-
_deferredOk: function(/*Deferred*/ dfd){
|
|
153
|
-
// summary:
|
|
154
|
-
// okHandler function for xhr._ioSetArgs call.
|
|
155
|
-
|
|
156
|
-
//DO NOT use "this" and expect it to be script.
|
|
157
|
-
var ioArgs = dfd.ioArgs;
|
|
158
|
-
|
|
159
|
-
//Favor JSONP responses, script load events then lastly ioArgs.
|
|
160
|
-
//The ioArgs are goofy, but cannot return the dfd since that stops
|
|
161
|
-
//the callback chain in Deferred. The return value is not that important
|
|
162
|
-
//in that case, probably a checkString case.
|
|
163
|
-
return ioArgs.json || ioArgs.scriptLoaded || ioArgs;
|
|
164
|
-
},
|
|
165
|
-
|
|
166
|
-
_deferredError: function(/*Error*/ error, /*Deferred*/ dfd){
|
|
167
|
-
// summary:
|
|
168
|
-
// errHandler function for xhr._ioSetArgs call.
|
|
169
|
-
|
|
170
|
-
console.log("dojo.io.script error", error);
|
|
171
|
-
return error;
|
|
172
|
-
},
|
|
173
|
-
|
|
174
|
-
_deadScripts: [],
|
|
175
|
-
_counter: 1,
|
|
176
|
-
|
|
177
|
-
_addDeadScript: function(/*Object*/ ioArgs){
|
|
178
|
-
// summary:
|
|
179
|
-
// sets up an entry in the deadScripts array.
|
|
180
|
-
script._deadScripts.push({id: ioArgs.id, frameDoc: ioArgs.frameDoc});
|
|
181
|
-
//Being extra paranoid about leaks:
|
|
182
|
-
ioArgs.frameDoc = null;
|
|
183
|
-
},
|
|
184
|
-
|
|
185
|
-
_validCheck: function(/*Deferred*/ dfd){
|
|
186
|
-
// summary:
|
|
187
|
-
// inflight check function to see if dfd is still valid.
|
|
188
|
-
|
|
189
|
-
// TODO: why isn't dfd accessed?
|
|
190
|
-
|
|
191
|
-
//Do script cleanup here. We wait for one inflight pass
|
|
192
|
-
//to make sure we don't get any weird things by trying to remove a script
|
|
193
|
-
//tag that is part of the call chain (IE 6 has been known to
|
|
194
|
-
//crash in that case).
|
|
195
|
-
var deadScripts = script._deadScripts;
|
|
196
|
-
if(deadScripts && deadScripts.length > 0){
|
|
197
|
-
for(var i = 0; i < deadScripts.length; i++){
|
|
198
|
-
//Remove the script tag
|
|
199
|
-
script.remove(deadScripts[i].id, deadScripts[i].frameDoc);
|
|
200
|
-
//Clean up the deferreds
|
|
201
|
-
delete script["jsonp_" + deadScripts[i].id];
|
|
202
|
-
deadScripts[i].frameDoc = null;
|
|
203
|
-
}
|
|
204
|
-
script._deadScripts = [];
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
return true;
|
|
208
|
-
},
|
|
209
|
-
|
|
210
|
-
_ioCheck: function(dfd){
|
|
211
|
-
// summary:
|
|
212
|
-
// inflight check function to see if IO finished.
|
|
213
|
-
// dfd: Deferred
|
|
214
|
-
var ioArgs = dfd.ioArgs;
|
|
215
|
-
//Check for finished jsonp
|
|
216
|
-
if(ioArgs.json || (ioArgs.scriptLoaded && !ioArgs.args.checkString)){
|
|
217
|
-
return true;
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
//Check for finished "checkString" case.
|
|
221
|
-
var checkString = ioArgs.args.checkString;
|
|
222
|
-
return checkString && eval("typeof(" + checkString + ") != 'undefined'");
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
},
|
|
226
|
-
|
|
227
|
-
_resHandle: function(/*Deferred*/ dfd){
|
|
228
|
-
// summary:
|
|
229
|
-
// inflight function to handle a completed response.
|
|
230
|
-
if(script._ioCheck(dfd)){
|
|
231
|
-
dfd.callback(dfd);
|
|
232
|
-
}else{
|
|
233
|
-
//This path should never happen since the only way we can get
|
|
234
|
-
//to _resHandle is if _ioCheck is true.
|
|
235
|
-
dfd.errback(new Error("inconceivable dojo.io.script._resHandle error"));
|
|
236
|
-
}
|
|
237
|
-
},
|
|
238
|
-
|
|
239
|
-
_canAttach: function(/*===== ioArgs =====*/ ){
|
|
240
|
-
// summary:
|
|
241
|
-
// A method that can be overridden by other modules
|
|
242
|
-
// to control when the script attachment occurs.
|
|
243
|
-
// ioArgs: Object
|
|
244
|
-
return true;
|
|
245
|
-
},
|
|
246
|
-
|
|
247
|
-
_jsonpCallback: function(/*JSON Object*/ json){
|
|
248
|
-
// summary:
|
|
249
|
-
// generic handler for jsonp callback. A pointer to this function
|
|
250
|
-
// is used for all jsonp callbacks. NOTE: the "this" in this
|
|
251
|
-
// function will be the Deferred object that represents the script
|
|
252
|
-
// request.
|
|
253
|
-
this.ioArgs.json = json;
|
|
254
|
-
if(this.ioArgs.requestId){
|
|
255
|
-
kernel.global[_script._callbacksProperty][this.ioArgs.requestId](json);
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
};
|
|
259
|
-
|
|
260
|
-
lang.setObject("dojo.io.script", script);
|
|
261
|
-
|
|
262
|
-
/*=====
|
|
263
|
-
script.attach = function(id, url, frameDocument){
|
|
264
|
-
// summary:
|
|
265
|
-
// creates a new `<script>` tag pointing to the specified URL and
|
|
266
|
-
// adds it to the document.
|
|
267
|
-
// description:
|
|
268
|
-
// Attaches the script element to the DOM. Use this method if you
|
|
269
|
-
// just want to attach a script to the DOM and do not care when or
|
|
270
|
-
// if it loads.
|
|
271
|
-
};
|
|
272
|
-
script.remove = function(id, frameDocument){
|
|
273
|
-
// summary:
|
|
274
|
-
// removes the script element with the given id, from the given frameDocument.
|
|
275
|
-
// If no frameDocument is passed, the current document is used.
|
|
276
|
-
};
|
|
277
|
-
=====*/
|
|
278
|
-
|
|
279
|
-
return script;
|
|
280
|
-
});
|