@ionic/core 8.8.6-dev.11777572994.1147595d → 8.8.6-nightly.20260501
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/components/index.js +1 -1
- package/components/ion-action-sheet.js +1 -1
- package/components/ion-alert.js +1 -1
- package/components/ion-back-button.js +1 -1
- package/components/ion-button.js +1 -1
- package/components/ion-card.js +1 -1
- package/components/ion-chip.js +1 -1
- package/components/ion-datetime-button.js +1 -1
- package/components/ion-datetime.js +1 -1
- package/components/ion-fab-button.js +1 -1
- package/components/ion-infinite-scroll-content.js +1 -1
- package/components/ion-input-password-toggle.js +1 -1
- package/components/ion-item-option.js +1 -1
- package/components/ion-item.js +1 -1
- package/components/ion-loading.js +1 -1
- package/components/ion-menu-button.js +1 -1
- package/components/ion-menu.js +1 -1
- package/components/ion-modal.js +1 -1
- package/components/ion-picker-legacy-column.d.ts +11 -0
- package/components/ion-picker-legacy-column.js +4 -0
- package/components/ion-picker-legacy.d.ts +11 -0
- package/components/ion-picker-legacy.js +4 -0
- package/components/ion-popover.js +1 -1
- package/components/ion-progress-bar.js +1 -1
- package/components/ion-radio.js +1 -1
- package/components/ion-range.js +1 -1
- package/components/ion-refresher-content.js +1 -1
- package/components/ion-refresher.js +1 -1
- package/components/ion-reorder-group.js +1 -1
- package/components/ion-reorder.js +1 -1
- package/components/ion-ripple-effect.js +1 -1
- package/components/ion-router-link.js +1 -1
- package/components/ion-router-outlet.js +1 -1
- package/components/ion-row.js +1 -1
- package/components/ion-searchbar.js +1 -1
- package/components/ion-segment-button.js +1 -1
- package/components/ion-segment-content.js +1 -1
- package/components/ion-segment-view.js +1 -1
- package/components/ion-segment.js +1 -1
- package/components/ion-select-modal.js +1 -1
- package/components/ion-select-option.js +1 -1
- package/components/ion-select-popover.js +1 -1
- package/components/ion-select.js +1 -1
- package/components/ion-skeleton-text.js +1 -1
- package/components/ion-spinner.js +1 -1
- package/components/ion-split-pane.js +1 -1
- package/components/ion-tab-bar.js +1 -1
- package/components/ion-tab-button.js +1 -1
- package/components/ion-tab.js +1 -1
- package/components/ion-tabs.js +1 -1
- package/components/ion-text.js +1 -1
- package/components/ion-textarea.js +1 -1
- package/components/ion-thumbnail.js +1 -1
- package/components/ion-title.js +1 -1
- package/components/ion-toast.js +1 -1
- package/components/ion-toggle.js +1 -1
- package/components/ion-toolbar.js +1 -1
- package/components/p-1KVKSLu5.js +4 -0
- package/components/{p-DbISMmiI.js → p-BSB38Tek.js} +1 -1
- package/components/{p-CDXBV7oG.js → p-BTeL5HCK.js} +1 -1
- package/components/p-BegtE7nr.js +4 -0
- package/components/{p-Ct3FLpwo.js → p-BlNv564p.js} +1 -1
- package/components/p-CH0NYjKq.js +4 -0
- package/components/{p-DL2W2mt3.js → p-CgfaEEem.js} +1 -1
- package/components/p-Cq8cQ0NL.js +4 -0
- package/components/{p-nPoOPlPt.js → p-Cyxa_4PV.js} +1 -1
- package/components/{p-OOMJP0jy.js → p-D-cP12ZN.js} +1 -1
- package/components/p-DHsZWn1l.js +4 -0
- package/components/{p-BeL7B3Bb.js → p-DJMZehmW.js} +1 -1
- package/components/p-DUqnmRFi.js +4 -0
- package/components/{p-DrIm1s9R.js → p-fpbh6w3f.js} +1 -1
- package/components/{p-DxXmSp9Y.js → p-kvaDs24J.js} +1 -1
- package/dist/cjs/index.cjs.js +2 -1
- package/dist/cjs/ion-action-sheet.cjs.entry.js +4 -8
- package/dist/cjs/ion-alert.cjs.entry.js +3 -7
- package/dist/cjs/ion-app_8.cjs.entry.js +9 -23
- package/dist/cjs/ion-avatar_3.cjs.entry.js +1 -1
- package/dist/cjs/ion-col_3.cjs.entry.js +1 -1
- package/dist/cjs/{ion-datetime.cjs.entry.js → ion-datetime_3.cjs.entry.js} +639 -1
- package/dist/cjs/ion-item_8.cjs.entry.js +2 -2
- package/dist/cjs/ion-loading.cjs.entry.js +3 -7
- package/dist/cjs/ion-menu_3.cjs.entry.js +1 -1
- package/dist/cjs/ion-modal.cjs.entry.js +5 -9
- package/dist/cjs/ion-popover.cjs.entry.js +3 -7
- package/dist/cjs/ion-progress-bar.cjs.entry.js +1 -1
- package/dist/cjs/ion-radio_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-range.cjs.entry.js +3 -3
- package/dist/cjs/ion-refresher_2.cjs.entry.js +2 -2
- package/dist/cjs/ion-reorder_2.cjs.entry.js +2 -2
- package/dist/cjs/ion-ripple-effect.cjs.entry.js +1 -1
- package/dist/cjs/ion-route_4.cjs.entry.js +2 -2
- package/dist/cjs/ion-searchbar.cjs.entry.js +4 -4
- package/dist/cjs/ion-segment-content.cjs.entry.js +1 -1
- package/dist/cjs/ion-segment-view.cjs.entry.js +2 -2
- package/dist/cjs/ion-segment_2.cjs.entry.js +4 -4
- package/dist/cjs/ion-select-modal.cjs.entry.js +2 -2
- package/dist/cjs/ion-select_3.cjs.entry.js +5 -5
- package/dist/cjs/ion-spinner.cjs.entry.js +1 -1
- package/dist/cjs/ion-split-pane.cjs.entry.js +2 -2
- package/dist/cjs/ion-tab-bar_2.cjs.entry.js +4 -4
- package/dist/cjs/ion-tab_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-text.cjs.entry.js +2 -2
- package/dist/cjs/ion-textarea.cjs.entry.js +2 -2
- package/dist/cjs/ion-toast.cjs.entry.js +3 -3
- package/dist/cjs/ion-toggle.cjs.entry.js +3 -3
- package/dist/cjs/ionic.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{overlays-DIfHxkst.js → overlays-C2jiBSNQ.js} +7 -26
- package/dist/collection/collection-manifest.json +9 -5
- package/dist/collection/components/action-sheet/action-sheet.js +4 -8
- package/dist/collection/components/alert/alert.js +3 -7
- package/dist/collection/components/loading/loading.js +3 -7
- package/dist/collection/components/modal/modal.js +5 -9
- package/dist/collection/components/picker-legacy/animations/ios.enter.js +27 -0
- package/dist/collection/components/picker-legacy/animations/ios.leave.js +23 -0
- package/dist/collection/components/picker-legacy/picker-interface.js +1 -0
- package/dist/collection/components/picker-legacy/picker.ios.css +300 -0
- package/dist/collection/components/picker-legacy/picker.js +890 -0
- package/dist/collection/components/picker-legacy/picker.md.css +287 -0
- package/dist/collection/components/picker-legacy-column/picker-column.ios.css +231 -0
- package/dist/collection/components/picker-legacy-column/picker-column.js +422 -0
- package/dist/collection/components/picker-legacy-column/picker-column.md.css +222 -0
- package/dist/collection/components/picker-legacy-column/test/test.utils.js +43 -0
- package/dist/collection/components/popover/popover.js +3 -7
- package/dist/collection/components/progress-bar/progress-bar.js +1 -1
- package/dist/collection/components/radio/radio.js +4 -4
- package/dist/collection/components/range/range.js +3 -3
- package/dist/collection/components/refresher/refresher.js +1 -1
- package/dist/collection/components/refresher-content/refresher-content.js +1 -1
- package/dist/collection/components/reorder/reorder.js +1 -1
- package/dist/collection/components/reorder-group/reorder-group.js +1 -1
- package/dist/collection/components/ripple-effect/ripple-effect.js +1 -1
- package/dist/collection/components/router-link/router-link.js +2 -2
- package/dist/collection/components/router-outlet/router-outlet.js +5 -38
- package/dist/collection/components/row/row.js +1 -1
- package/dist/collection/components/searchbar/searchbar.js +4 -4
- package/dist/collection/components/segment/segment.js +2 -2
- package/dist/collection/components/segment-button/segment-button.js +2 -2
- package/dist/collection/components/segment-content/segment-content.js +1 -1
- package/dist/collection/components/segment-view/segment-view.js +2 -2
- package/dist/collection/components/select/select.js +2 -2
- package/dist/collection/components/select-modal/select-modal.js +1 -1
- package/dist/collection/components/select-option/select-option.js +1 -1
- package/dist/collection/components/select-popover/select-popover.js +1 -1
- package/dist/collection/components/skeleton-text/skeleton-text.js +2 -2
- package/dist/collection/components/spinner/spinner.js +1 -1
- package/dist/collection/components/split-pane/split-pane.js +2 -2
- package/dist/collection/components/tab/tab.js +2 -2
- package/dist/collection/components/tab-bar/tab-bar.js +2 -2
- package/dist/collection/components/tab-button/tab-button.js +2 -2
- package/dist/collection/components/tabs/tabs.js +1 -1
- package/dist/collection/components/text/text.js +2 -2
- package/dist/collection/components/textarea/textarea.js +2 -2
- package/dist/collection/components/thumbnail/thumbnail.js +1 -1
- package/dist/collection/components/title/title.js +2 -2
- package/dist/collection/components/toast/toast.js +2 -2
- package/dist/collection/components/toggle/toggle.js +3 -3
- package/dist/collection/components/toolbar/toolbar.js +2 -2
- package/dist/collection/index.js +1 -1
- package/dist/collection/utils/overlays.js +6 -25
- package/dist/docs.json +941 -28
- package/dist/esm/{index-AlrZKoWR.js → index-DV3sJJW8.js} +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/ion-accordion_2.entry.js +1 -1
- package/dist/esm/ion-action-sheet.entry.js +4 -8
- package/dist/esm/ion-alert.entry.js +3 -7
- package/dist/esm/ion-app_8.entry.js +9 -23
- package/dist/esm/ion-avatar_3.entry.js +1 -1
- package/dist/esm/ion-back-button.entry.js +1 -1
- package/dist/esm/ion-breadcrumb_2.entry.js +1 -1
- package/dist/esm/ion-col_3.entry.js +1 -1
- package/dist/esm/{ion-datetime.entry.js → ion-datetime_3.entry.js} +641 -5
- package/dist/esm/ion-fab_3.entry.js +1 -1
- package/dist/esm/ion-input-password-toggle.entry.js +1 -1
- package/dist/esm/ion-input.entry.js +1 -1
- package/dist/esm/ion-item_8.entry.js +3 -3
- package/dist/esm/ion-loading.entry.js +3 -7
- package/dist/esm/ion-menu_3.entry.js +2 -2
- package/dist/esm/ion-modal.entry.js +5 -9
- package/dist/esm/ion-popover.entry.js +3 -7
- package/dist/esm/ion-progress-bar.entry.js +1 -1
- package/dist/esm/ion-radio_2.entry.js +3 -3
- package/dist/esm/ion-range.entry.js +3 -3
- package/dist/esm/ion-refresher_2.entry.js +3 -3
- package/dist/esm/ion-reorder_2.entry.js +3 -3
- package/dist/esm/ion-ripple-effect.entry.js +1 -1
- package/dist/esm/ion-route_4.entry.js +2 -2
- package/dist/esm/ion-searchbar.entry.js +5 -5
- package/dist/esm/ion-segment-content.entry.js +1 -1
- package/dist/esm/ion-segment-view.entry.js +2 -2
- package/dist/esm/ion-segment_2.entry.js +4 -4
- package/dist/esm/ion-select-modal.entry.js +2 -2
- package/dist/esm/ion-select_3.entry.js +6 -6
- package/dist/esm/ion-spinner.entry.js +1 -1
- package/dist/esm/ion-split-pane.entry.js +2 -2
- package/dist/esm/ion-tab-bar_2.entry.js +4 -4
- package/dist/esm/ion-tab_2.entry.js +3 -3
- package/dist/esm/ion-text.entry.js +2 -2
- package/dist/esm/ion-textarea.entry.js +2 -2
- package/dist/esm/ion-toast.entry.js +3 -3
- package/dist/esm/ion-toggle.entry.js +4 -4
- package/dist/esm/ionic.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{overlays-BDGzTP3L.js → overlays-F8GHPo-e.js} +7 -26
- package/dist/html.html-data.json +59 -4
- package/dist/ionic/index.esm.js +1 -1
- package/dist/ionic/ionic.esm.js +1 -1
- package/dist/ionic/{p-f17d05e3.entry.js → p-031b76f7.entry.js} +1 -1
- package/dist/ionic/{p-ede28b71.entry.js → p-07506134.entry.js} +1 -1
- package/dist/ionic/{p-e9dd191b.entry.js → p-084c25b2.entry.js} +1 -1
- package/dist/ionic/{p-fed27c64.entry.js → p-0d8b5c38.entry.js} +1 -1
- package/dist/ionic/p-16813ce7.entry.js +4 -0
- package/dist/ionic/p-1b02923f.entry.js +4 -0
- package/dist/ionic/{p-898f9d11.entry.js → p-1b169fb6.entry.js} +1 -1
- package/dist/ionic/p-23fac490.entry.js +4 -0
- package/dist/ionic/{p-7fe42b71.entry.js → p-28a9e720.entry.js} +1 -1
- package/dist/ionic/{p-3b58996c.entry.js → p-294f4bb5.entry.js} +1 -1
- package/dist/ionic/{p-f7762013.entry.js → p-2a68388b.entry.js} +1 -1
- package/dist/ionic/p-2f5a8140.entry.js +4 -0
- package/dist/ionic/{p-34b3a309.entry.js → p-2fd110aa.entry.js} +1 -1
- package/dist/ionic/{p-4ed63122.entry.js → p-301c43f8.entry.js} +1 -1
- package/dist/ionic/p-4c67ce4c.entry.js +4 -0
- package/dist/ionic/p-51c11c47.entry.js +4 -0
- package/dist/ionic/p-53f750a5.entry.js +4 -0
- package/dist/ionic/p-6b701daa.entry.js +4 -0
- package/dist/ionic/{p-19adf785.entry.js → p-7620be24.entry.js} +1 -1
- package/dist/ionic/{p-18b5d5ff.entry.js → p-771b27a5.entry.js} +1 -1
- package/dist/ionic/p-7ca71c83.entry.js +4 -0
- package/dist/ionic/{p-66494f9b.entry.js → p-80cac7a2.entry.js} +1 -1
- package/dist/ionic/{p-506038d3.entry.js → p-8fda6a62.entry.js} +1 -1
- package/dist/ionic/{p-7f269aff.entry.js → p-9cbc6f1f.entry.js} +1 -1
- package/dist/ionic/{p-b6f16f18.entry.js → p-9cdbabbb.entry.js} +1 -1
- package/dist/ionic/p-DTPR1Wpn.js +4 -0
- package/dist/ionic/{p-AlrZKoWR.js → p-DV3sJJW8.js} +1 -1
- package/dist/ionic/{p-dc198c3a.entry.js → p-a84f2d21.entry.js} +1 -1
- package/dist/ionic/{p-b8f4a31c.entry.js → p-aa812c4b.entry.js} +1 -1
- package/dist/ionic/{p-30f5ad9e.entry.js → p-b325a113.entry.js} +1 -1
- package/dist/ionic/p-b5ea8cdd.entry.js +4 -0
- package/dist/ionic/{p-1d2163ad.entry.js → p-bcaa827e.entry.js} +1 -1
- package/dist/ionic/{p-6e99ae8d.entry.js → p-c3cce9d8.entry.js} +1 -1
- package/dist/ionic/{p-b553828c.entry.js → p-d4e8b473.entry.js} +1 -1
- package/dist/ionic/p-e0287f41.entry.js +4 -0
- package/dist/ionic/{p-6da572e7.entry.js → p-e863ffe8.entry.js} +1 -1
- package/dist/ionic/p-f2deaceb.entry.js +4 -0
- package/dist/ionic/{p-460fbe5b.entry.js → p-f69a5f71.entry.js} +1 -1
- package/dist/ionic/{p-4ea520a4.entry.js → p-f8186550.entry.js} +1 -1
- package/dist/ionic/{p-8a3a936b.entry.js → p-fdbc90d4.entry.js} +1 -1
- package/dist/types/components/picker-legacy/animations/ios.enter.d.ts +5 -0
- package/dist/types/components/picker-legacy/animations/ios.leave.d.ts +5 -0
- package/dist/types/components/picker-legacy/picker-interface.d.ts +52 -0
- package/dist/types/components/picker-legacy/picker.d.ts +158 -0
- package/dist/types/components/picker-legacy-column/picker-column.d.ts +46 -0
- package/dist/types/components/picker-legacy-column/test/test.utils.d.ts +9 -0
- package/dist/types/components/router-outlet/router-outlet.d.ts +0 -7
- package/dist/types/components.d.ts +272 -9
- package/dist/types/index.d.ts +1 -1
- package/dist/types/interface.d.ts +1 -0
- package/dist/types/utils/config.d.ts +8 -0
- package/dist/types/utils/overlays.d.ts +9 -11
- package/hydrate/index.js +788 -164
- package/hydrate/index.mjs +788 -164
- package/package.json +3 -3
- package/components/p-BHlzkIpO.js +0 -4
- package/components/p-Bg7NsGS9.js +0 -4
- package/components/p-CWpbvhwY.js +0 -4
- package/components/p-DBHdZu4y.js +0 -4
- package/components/p-DPdqO7R6.js +0 -4
- package/dist/ionic/p-2089f9cb.entry.js +0 -4
- package/dist/ionic/p-4c8d8c55.entry.js +0 -4
- package/dist/ionic/p-4f3a8ccf.entry.js +0 -4
- package/dist/ionic/p-528d4c1d.entry.js +0 -4
- package/dist/ionic/p-5430ae94.entry.js +0 -4
- package/dist/ionic/p-5c2cc090.entry.js +0 -4
- package/dist/ionic/p-6406d5a9.entry.js +0 -4
- package/dist/ionic/p-7f9db51b.entry.js +0 -4
- package/dist/ionic/p-Csx_Ej2k.js +0 -4
- package/dist/ionic/p-a39db980.entry.js +0 -4
- package/dist/ionic/p-b5e3e1f7.entry.js +0 -4
- package/dist/ionic/p-cce0cd26.entry.js +0 -4
- package/dist/ionic/p-d92ba088.entry.js +0 -4
|
@@ -6,16 +6,20 @@
|
|
|
6
6
|
var index = require('./index-CqT-2gKy.js');
|
|
7
7
|
var focusVisible = require('./focus-visible-CCvKiLh3.js');
|
|
8
8
|
var helpers = require('./helpers-CxTYJdbT.js');
|
|
9
|
-
var overlays = require('./overlays-
|
|
9
|
+
var overlays = require('./overlays-C2jiBSNQ.js');
|
|
10
10
|
var dir = require('./dir-Cn0z1rJH.js');
|
|
11
11
|
var theme = require('./theme-CeDs6Hcv.js');
|
|
12
12
|
var index$1 = require('./index-DqmRDbxg.js');
|
|
13
13
|
var ionicGlobal = require('./ionic-global-Bc3kJi1Z.js');
|
|
14
14
|
var data = require('./data-BYlBjkMU.js');
|
|
15
|
+
var lockController = require('./lock-controller-aDB9wrEf.js');
|
|
16
|
+
var animation = require('./animation-Dg4yiuR2.js');
|
|
17
|
+
var haptic = require('./haptic-ClPPQ_PS.js');
|
|
15
18
|
require('./index-DkNv4J_i.js');
|
|
16
19
|
require('./hardware-back-button-C4rMJ5uI.js');
|
|
17
20
|
require('./framework-delegate-CRgp8o_p.js');
|
|
18
21
|
require('./gesture-controller-dtqlP_q4.js');
|
|
22
|
+
require('./capacitor-DmA66EwP.js');
|
|
19
23
|
|
|
20
24
|
const isYearDisabled = (refYear, minParts, maxParts) => {
|
|
21
25
|
if (minParts && minParts.year > refYear) {
|
|
@@ -1966,4 +1970,638 @@ Datetime.style = {
|
|
|
1966
1970
|
md: datetimeMdCss()
|
|
1967
1971
|
};
|
|
1968
1972
|
|
|
1973
|
+
/**
|
|
1974
|
+
* iOS Picker Enter Animation
|
|
1975
|
+
*/
|
|
1976
|
+
const iosEnterAnimation = (baseEl) => {
|
|
1977
|
+
const baseAnimation = animation.createAnimation();
|
|
1978
|
+
const backdropAnimation = animation.createAnimation();
|
|
1979
|
+
const wrapperAnimation = animation.createAnimation();
|
|
1980
|
+
backdropAnimation
|
|
1981
|
+
.addElement(baseEl.querySelector('ion-backdrop'))
|
|
1982
|
+
.fromTo('opacity', 0.01, 'var(--backdrop-opacity)')
|
|
1983
|
+
.beforeStyles({
|
|
1984
|
+
'pointer-events': 'none',
|
|
1985
|
+
})
|
|
1986
|
+
.afterClearStyles(['pointer-events']);
|
|
1987
|
+
wrapperAnimation
|
|
1988
|
+
.addElement(baseEl.querySelector('.picker-wrapper'))
|
|
1989
|
+
.fromTo('transform', 'translateY(100%)', 'translateY(0%)');
|
|
1990
|
+
return baseAnimation
|
|
1991
|
+
.addElement(baseEl)
|
|
1992
|
+
.easing('cubic-bezier(.36,.66,.04,1)')
|
|
1993
|
+
.duration(400)
|
|
1994
|
+
.addAnimation([backdropAnimation, wrapperAnimation]);
|
|
1995
|
+
};
|
|
1996
|
+
|
|
1997
|
+
/**
|
|
1998
|
+
* iOS Picker Leave Animation
|
|
1999
|
+
*/
|
|
2000
|
+
const iosLeaveAnimation = (baseEl) => {
|
|
2001
|
+
const baseAnimation = animation.createAnimation();
|
|
2002
|
+
const backdropAnimation = animation.createAnimation();
|
|
2003
|
+
const wrapperAnimation = animation.createAnimation();
|
|
2004
|
+
backdropAnimation
|
|
2005
|
+
.addElement(baseEl.querySelector('ion-backdrop'))
|
|
2006
|
+
.fromTo('opacity', 'var(--backdrop-opacity)', 0.01);
|
|
2007
|
+
wrapperAnimation
|
|
2008
|
+
.addElement(baseEl.querySelector('.picker-wrapper'))
|
|
2009
|
+
.fromTo('transform', 'translateY(0%)', 'translateY(100%)');
|
|
2010
|
+
return baseAnimation
|
|
2011
|
+
.addElement(baseEl)
|
|
2012
|
+
.easing('cubic-bezier(.36,.66,.04,1)')
|
|
2013
|
+
.duration(400)
|
|
2014
|
+
.addAnimation([backdropAnimation, wrapperAnimation]);
|
|
2015
|
+
};
|
|
2016
|
+
|
|
2017
|
+
const pickerIosCss = () => `.sc-ion-picker-legacy-ios-h{--border-radius:0;--border-style:solid;--min-width:auto;--width:100%;--max-width:500px;--min-height:auto;--max-height:auto;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;top:0;display:block;position:absolute;width:100%;height:100%;outline:none;font-family:var(--ion-font-family, inherit);contain:strict;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:1001}.sc-ion-picker-legacy-ios-h{inset-inline-start:0}.overlay-hidden.sc-ion-picker-legacy-ios-h{display:none}.picker-wrapper.sc-ion-picker-legacy-ios{border-radius:var(--border-radius);left:0;right:0;bottom:0;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto;margin-top:auto;margin-bottom:auto;-webkit-transform:translate3d(0, 100%, 0);transform:translate3d(0, 100%, 0);display:-ms-flexbox;display:flex;position:absolute;-ms-flex-direction:column;flex-direction:column;width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);contain:strict;overflow:hidden;z-index:10}.picker-toolbar.sc-ion-picker-legacy-ios{width:100%;background:transparent;contain:strict;z-index:1}.picker-button.sc-ion-picker-legacy-ios{border:0;font-family:inherit}.picker-button.sc-ion-picker-legacy-ios:active,.picker-button.sc-ion-picker-legacy-ios:focus{outline:none}.picker-columns.sc-ion-picker-legacy-ios{display:-ms-flexbox;display:flex;position:relative;-ms-flex-pack:center;justify-content:center;margin-bottom:var(--ion-safe-area-bottom, 0);contain:strict;overflow:hidden}.picker-above-highlight.sc-ion-picker-legacy-ios,.picker-below-highlight.sc-ion-picker-legacy-ios{display:none;pointer-events:none}.sc-ion-picker-legacy-ios-h{--background:var(--ion-background-color, #fff);--border-width:1px 0 0;--border-color:var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-250, var(--ion-background-color-step-250, #c8c7cc))));--height:260px;--backdrop-opacity:var(--ion-backdrop-opacity, 0.26);color:var(--ion-item-color, var(--ion-text-color, #000))}.picker-toolbar.sc-ion-picker-legacy-ios{display:-ms-flexbox;display:flex;height:44px;border-bottom:0.55px solid var(--border-color)}.picker-toolbar-button.sc-ion-picker-legacy-ios{-ms-flex:1;flex:1;text-align:end}.picker-toolbar-button.sc-ion-picker-legacy-ios:last-child .picker-button.sc-ion-picker-legacy-ios{font-weight:600}.picker-toolbar-button.sc-ion-picker-legacy-ios:first-child{font-weight:normal;text-align:start}.picker-button.sc-ion-picker-legacy-ios,.picker-button.ion-activated.sc-ion-picker-legacy-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;-webkit-padding-start:1em;padding-inline-start:1em;-webkit-padding-end:1em;padding-inline-end:1em;padding-top:0;padding-bottom:0;height:44px;background:transparent;color:var(--ion-color-primary, #0054e9);font-size:16px}.picker-columns.sc-ion-picker-legacy-ios{height:215px;-webkit-perspective:1000px;perspective:1000px}.picker-above-highlight.sc-ion-picker-legacy-ios{top:0;-webkit-transform:translate3d(0, 0, 90px);transform:translate3d(0, 0, 90px);display:block;position:absolute;width:100%;height:81px;border-bottom:1px solid var(--border-color);background:-webkit-gradient(linear, left top, left bottom, color-stop(20%, var(--background, var(--ion-background-color, #fff))), to(rgba(var(--background-rgb, var(--ion-background-color-rgb, 255, 255, 255)), 0.8)));background:linear-gradient(to bottom, var(--background, var(--ion-background-color, #fff)) 20%, rgba(var(--background-rgb, var(--ion-background-color-rgb, 255, 255, 255)), 0.8) 100%);z-index:10}.picker-above-highlight.sc-ion-picker-legacy-ios{inset-inline-start:0}.picker-below-highlight.sc-ion-picker-legacy-ios{top:115px;-webkit-transform:translate3d(0, 0, 90px);transform:translate3d(0, 0, 90px);display:block;position:absolute;width:100%;height:119px;border-top:1px solid var(--border-color);background:-webkit-gradient(linear, left bottom, left top, color-stop(30%, var(--background, var(--ion-background-color, #fff))), to(rgba(var(--background-rgb, var(--ion-background-color-rgb, 255, 255, 255)), 0.8)));background:linear-gradient(to top, var(--background, var(--ion-background-color, #fff)) 30%, rgba(var(--background-rgb, var(--ion-background-color-rgb, 255, 255, 255)), 0.8) 100%);z-index:11}.picker-below-highlight.sc-ion-picker-legacy-ios{inset-inline-start:0}`;
|
|
2018
|
+
|
|
2019
|
+
const pickerMdCss = () => `.sc-ion-picker-legacy-md-h{--border-radius:0;--border-style:solid;--min-width:auto;--width:100%;--max-width:500px;--min-height:auto;--max-height:auto;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;top:0;display:block;position:absolute;width:100%;height:100%;outline:none;font-family:var(--ion-font-family, inherit);contain:strict;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:1001}.sc-ion-picker-legacy-md-h{inset-inline-start:0}.overlay-hidden.sc-ion-picker-legacy-md-h{display:none}.picker-wrapper.sc-ion-picker-legacy-md{border-radius:var(--border-radius);left:0;right:0;bottom:0;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto;margin-top:auto;margin-bottom:auto;-webkit-transform:translate3d(0, 100%, 0);transform:translate3d(0, 100%, 0);display:-ms-flexbox;display:flex;position:absolute;-ms-flex-direction:column;flex-direction:column;width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);contain:strict;overflow:hidden;z-index:10}.picker-toolbar.sc-ion-picker-legacy-md{width:100%;background:transparent;contain:strict;z-index:1}.picker-button.sc-ion-picker-legacy-md{border:0;font-family:inherit}.picker-button.sc-ion-picker-legacy-md:active,.picker-button.sc-ion-picker-legacy-md:focus{outline:none}.picker-columns.sc-ion-picker-legacy-md{display:-ms-flexbox;display:flex;position:relative;-ms-flex-pack:center;justify-content:center;margin-bottom:var(--ion-safe-area-bottom, 0);contain:strict;overflow:hidden}.picker-above-highlight.sc-ion-picker-legacy-md,.picker-below-highlight.sc-ion-picker-legacy-md{display:none;pointer-events:none}.sc-ion-picker-legacy-md-h{--background:var(--ion-background-color, #fff);--border-width:0.55px 0 0;--border-color:var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-150, var(--ion-background-color-step-150, rgba(0, 0, 0, 0.13)))));--height:260px;--backdrop-opacity:var(--ion-backdrop-opacity, 0.26);color:var(--ion-item-color, var(--ion-text-color, #000))}.picker-toolbar.sc-ion-picker-legacy-md{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;height:44px}.picker-button.sc-ion-picker-legacy-md,.picker-button.ion-activated.sc-ion-picker-legacy-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;-webkit-padding-start:1.1em;padding-inline-start:1.1em;-webkit-padding-end:1.1em;padding-inline-end:1.1em;padding-top:0;padding-bottom:0;height:44px;background:transparent;color:var(--ion-color-primary, #0054e9);font-size:14px;font-weight:500;text-transform:uppercase;-webkit-box-shadow:none;box-shadow:none}.picker-columns.sc-ion-picker-legacy-md{height:216px;-webkit-perspective:1800px;perspective:1800px}.picker-above-highlight.sc-ion-picker-legacy-md{top:0;-webkit-transform:translate3d(0, 0, 90px);transform:translate3d(0, 0, 90px);position:absolute;width:100%;height:81px;border-bottom:1px solid var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-150, var(--ion-background-color-step-150, rgba(0, 0, 0, 0.13)))));background:-webkit-gradient(linear, left top, left bottom, color-stop(20%, var(--ion-background-color, #fff)), to(rgba(var(--ion-background-color-rgb, 255, 255, 255), 0.8)));background:linear-gradient(to bottom, var(--ion-background-color, #fff) 20%, rgba(var(--ion-background-color-rgb, 255, 255, 255), 0.8) 100%);z-index:10}.picker-above-highlight.sc-ion-picker-legacy-md{inset-inline-start:0}.picker-below-highlight.sc-ion-picker-legacy-md{top:115px;-webkit-transform:translate3d(0, 0, 90px);transform:translate3d(0, 0, 90px);position:absolute;width:100%;height:119px;border-top:1px solid var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-150, var(--ion-background-color-step-150, rgba(0, 0, 0, 0.13)))));background:-webkit-gradient(linear, left bottom, left top, color-stop(30%, var(--ion-background-color, #fff)), to(rgba(var(--ion-background-color-rgb, 255, 255, 255), 0.8)));background:linear-gradient(to top, var(--ion-background-color, #fff) 30%, rgba(var(--ion-background-color-rgb, 255, 255, 255), 0.8) 100%);z-index:11}.picker-below-highlight.sc-ion-picker-legacy-md{inset-inline-start:0}`;
|
|
2020
|
+
|
|
2021
|
+
const Picker = class {
|
|
2022
|
+
constructor(hostRef) {
|
|
2023
|
+
index.registerInstance(this, hostRef);
|
|
2024
|
+
this.didPresent = index.createEvent(this, "ionPickerDidPresent", 7);
|
|
2025
|
+
this.willPresent = index.createEvent(this, "ionPickerWillPresent", 7);
|
|
2026
|
+
this.willDismiss = index.createEvent(this, "ionPickerWillDismiss", 7);
|
|
2027
|
+
this.didDismiss = index.createEvent(this, "ionPickerDidDismiss", 7);
|
|
2028
|
+
this.didPresentShorthand = index.createEvent(this, "didPresent", 7);
|
|
2029
|
+
this.willPresentShorthand = index.createEvent(this, "willPresent", 7);
|
|
2030
|
+
this.willDismissShorthand = index.createEvent(this, "willDismiss", 7);
|
|
2031
|
+
this.didDismissShorthand = index.createEvent(this, "didDismiss", 7);
|
|
2032
|
+
this.delegateController = overlays.createDelegateController(this);
|
|
2033
|
+
this.lockController = lockController.createLockController();
|
|
2034
|
+
this.triggerController = overlays.createTriggerController();
|
|
2035
|
+
this.presented = false;
|
|
2036
|
+
/** @internal */
|
|
2037
|
+
this.hasController = false;
|
|
2038
|
+
/**
|
|
2039
|
+
* If `true`, the keyboard will be automatically dismissed when the overlay is presented.
|
|
2040
|
+
*/
|
|
2041
|
+
this.keyboardClose = true;
|
|
2042
|
+
/**
|
|
2043
|
+
* Array of buttons to be displayed at the top of the picker.
|
|
2044
|
+
*/
|
|
2045
|
+
this.buttons = [];
|
|
2046
|
+
/**
|
|
2047
|
+
* Array of columns to be displayed in the picker.
|
|
2048
|
+
*/
|
|
2049
|
+
this.columns = [];
|
|
2050
|
+
/**
|
|
2051
|
+
* Number of milliseconds to wait before dismissing the picker.
|
|
2052
|
+
*/
|
|
2053
|
+
this.duration = 0;
|
|
2054
|
+
/**
|
|
2055
|
+
* If `true`, a backdrop will be displayed behind the picker.
|
|
2056
|
+
*/
|
|
2057
|
+
this.showBackdrop = true;
|
|
2058
|
+
/**
|
|
2059
|
+
* If `true`, the picker will be dismissed when the backdrop is clicked.
|
|
2060
|
+
*/
|
|
2061
|
+
this.backdropDismiss = true;
|
|
2062
|
+
/**
|
|
2063
|
+
* If `true`, the picker will animate.
|
|
2064
|
+
*/
|
|
2065
|
+
this.animated = true;
|
|
2066
|
+
/**
|
|
2067
|
+
* If `true`, the picker will open. If `false`, the picker will close.
|
|
2068
|
+
* Use this if you need finer grained control over presentation, otherwise
|
|
2069
|
+
* just use the pickerController or the `trigger` property.
|
|
2070
|
+
* Note: `isOpen` will not automatically be set back to `false` when
|
|
2071
|
+
* the picker dismisses. You will need to do that in your code.
|
|
2072
|
+
*/
|
|
2073
|
+
this.isOpen = false;
|
|
2074
|
+
this.onBackdropTap = () => {
|
|
2075
|
+
this.dismiss(undefined, overlays.BACKDROP);
|
|
2076
|
+
};
|
|
2077
|
+
this.dispatchCancelHandler = (ev) => {
|
|
2078
|
+
const role = ev.detail.role;
|
|
2079
|
+
if (overlays.isCancel(role)) {
|
|
2080
|
+
const cancelButton = this.buttons.find((b) => b.role === 'cancel');
|
|
2081
|
+
this.callButtonHandler(cancelButton);
|
|
2082
|
+
}
|
|
2083
|
+
};
|
|
2084
|
+
}
|
|
2085
|
+
onIsOpenChange(newValue, oldValue) {
|
|
2086
|
+
if (newValue === true && oldValue === false) {
|
|
2087
|
+
this.present();
|
|
2088
|
+
}
|
|
2089
|
+
else if (newValue === false && oldValue === true) {
|
|
2090
|
+
this.dismiss();
|
|
2091
|
+
}
|
|
2092
|
+
}
|
|
2093
|
+
triggerChanged() {
|
|
2094
|
+
const { trigger, el, triggerController } = this;
|
|
2095
|
+
if (trigger) {
|
|
2096
|
+
triggerController.addClickListener(el, trigger);
|
|
2097
|
+
}
|
|
2098
|
+
}
|
|
2099
|
+
connectedCallback() {
|
|
2100
|
+
overlays.prepareOverlay(this.el);
|
|
2101
|
+
this.triggerChanged();
|
|
2102
|
+
}
|
|
2103
|
+
disconnectedCallback() {
|
|
2104
|
+
this.triggerController.removeClickListener();
|
|
2105
|
+
}
|
|
2106
|
+
componentWillLoad() {
|
|
2107
|
+
var _a;
|
|
2108
|
+
if (!((_a = this.htmlAttributes) === null || _a === void 0 ? void 0 : _a.id)) {
|
|
2109
|
+
overlays.setOverlayId(this.el);
|
|
2110
|
+
}
|
|
2111
|
+
}
|
|
2112
|
+
componentDidLoad() {
|
|
2113
|
+
index.printIonWarning('[ion-picker-legacy] - ion-picker-legacy and ion-picker-legacy-column have been deprecated in favor of new versions of the ion-picker and ion-picker-column components. These new components display inline with your page content allowing for more presentation flexibility than before.', this.el);
|
|
2114
|
+
/**
|
|
2115
|
+
* If picker was rendered with isOpen="true"
|
|
2116
|
+
* then we should open picker immediately.
|
|
2117
|
+
*/
|
|
2118
|
+
if (this.isOpen === true) {
|
|
2119
|
+
helpers.raf(() => this.present());
|
|
2120
|
+
}
|
|
2121
|
+
/**
|
|
2122
|
+
* When binding values in frameworks such as Angular
|
|
2123
|
+
* it is possible for the value to be set after the Web Component
|
|
2124
|
+
* initializes but before the value watcher is set up in Stencil.
|
|
2125
|
+
* As a result, the watcher callback may not be fired.
|
|
2126
|
+
* We work around this by manually calling the watcher
|
|
2127
|
+
* callback when the component has loaded and the watcher
|
|
2128
|
+
* is configured.
|
|
2129
|
+
*/
|
|
2130
|
+
this.triggerChanged();
|
|
2131
|
+
}
|
|
2132
|
+
/**
|
|
2133
|
+
* Present the picker overlay after it has been created.
|
|
2134
|
+
*/
|
|
2135
|
+
async present() {
|
|
2136
|
+
const unlock = await this.lockController.lock();
|
|
2137
|
+
await this.delegateController.attachViewToDom();
|
|
2138
|
+
await overlays.present(this, 'pickerEnter', iosEnterAnimation, iosEnterAnimation, undefined);
|
|
2139
|
+
if (this.duration > 0) {
|
|
2140
|
+
this.durationTimeout = setTimeout(() => this.dismiss(), this.duration);
|
|
2141
|
+
}
|
|
2142
|
+
unlock();
|
|
2143
|
+
}
|
|
2144
|
+
/**
|
|
2145
|
+
* Dismiss the picker overlay after it has been presented.
|
|
2146
|
+
*
|
|
2147
|
+
* @param data Any data to emit in the dismiss events.
|
|
2148
|
+
* @param role The role of the element that is dismissing the picker.
|
|
2149
|
+
* This can be useful in a button handler for determining which button was
|
|
2150
|
+
* clicked to dismiss the picker.
|
|
2151
|
+
* Some examples include: ``"cancel"`, `"destructive"`, "selected"`, and `"backdrop"`.
|
|
2152
|
+
*/
|
|
2153
|
+
async dismiss(data, role) {
|
|
2154
|
+
const unlock = await this.lockController.lock();
|
|
2155
|
+
if (this.durationTimeout) {
|
|
2156
|
+
clearTimeout(this.durationTimeout);
|
|
2157
|
+
}
|
|
2158
|
+
const dismissed = await overlays.dismiss(this, data, role, 'pickerLeave', iosLeaveAnimation, iosLeaveAnimation);
|
|
2159
|
+
if (dismissed) {
|
|
2160
|
+
this.delegateController.removeViewFromDom();
|
|
2161
|
+
}
|
|
2162
|
+
unlock();
|
|
2163
|
+
return dismissed;
|
|
2164
|
+
}
|
|
2165
|
+
/**
|
|
2166
|
+
* Returns a promise that resolves when the picker did dismiss.
|
|
2167
|
+
*/
|
|
2168
|
+
onDidDismiss() {
|
|
2169
|
+
return overlays.eventMethod(this.el, 'ionPickerDidDismiss');
|
|
2170
|
+
}
|
|
2171
|
+
/**
|
|
2172
|
+
* Returns a promise that resolves when the picker will dismiss.
|
|
2173
|
+
*/
|
|
2174
|
+
onWillDismiss() {
|
|
2175
|
+
return overlays.eventMethod(this.el, 'ionPickerWillDismiss');
|
|
2176
|
+
}
|
|
2177
|
+
/**
|
|
2178
|
+
* Get the column that matches the specified name.
|
|
2179
|
+
*
|
|
2180
|
+
* @param name The name of the column.
|
|
2181
|
+
*/
|
|
2182
|
+
getColumn(name) {
|
|
2183
|
+
return Promise.resolve(this.columns.find((column) => column.name === name));
|
|
2184
|
+
}
|
|
2185
|
+
async buttonClick(button) {
|
|
2186
|
+
const role = button.role;
|
|
2187
|
+
if (overlays.isCancel(role)) {
|
|
2188
|
+
return this.dismiss(undefined, role);
|
|
2189
|
+
}
|
|
2190
|
+
const shouldDismiss = await this.callButtonHandler(button);
|
|
2191
|
+
if (shouldDismiss) {
|
|
2192
|
+
return this.dismiss(this.getSelected(), button.role);
|
|
2193
|
+
}
|
|
2194
|
+
return Promise.resolve();
|
|
2195
|
+
}
|
|
2196
|
+
async callButtonHandler(button) {
|
|
2197
|
+
if (button) {
|
|
2198
|
+
// a handler has been provided, execute it
|
|
2199
|
+
// pass the handler the values from the inputs
|
|
2200
|
+
const rtn = await overlays.safeCall(button.handler, this.getSelected());
|
|
2201
|
+
if (rtn === false) {
|
|
2202
|
+
// if the return value of the handler is false then do not dismiss
|
|
2203
|
+
return false;
|
|
2204
|
+
}
|
|
2205
|
+
}
|
|
2206
|
+
return true;
|
|
2207
|
+
}
|
|
2208
|
+
getSelected() {
|
|
2209
|
+
const selected = {};
|
|
2210
|
+
this.columns.forEach((col, index) => {
|
|
2211
|
+
const selectedColumn = col.selectedIndex !== undefined ? col.options[col.selectedIndex] : undefined;
|
|
2212
|
+
selected[col.name] = {
|
|
2213
|
+
text: selectedColumn ? selectedColumn.text : undefined,
|
|
2214
|
+
value: selectedColumn ? selectedColumn.value : undefined,
|
|
2215
|
+
columnIndex: index,
|
|
2216
|
+
};
|
|
2217
|
+
});
|
|
2218
|
+
return selected;
|
|
2219
|
+
}
|
|
2220
|
+
render() {
|
|
2221
|
+
const { htmlAttributes } = this;
|
|
2222
|
+
const mode = ionicGlobal.getIonMode(this);
|
|
2223
|
+
return (index.h(index.Host, Object.assign({ key: '80f66d33780d8a1352d24be9cb63a0cc03d01ab5', "aria-modal": "true", tabindex: "-1" }, htmlAttributes, { style: {
|
|
2224
|
+
zIndex: `${20000 + this.overlayIndex}`,
|
|
2225
|
+
}, class: Object.assign({ [mode]: true,
|
|
2226
|
+
// Used internally for styling
|
|
2227
|
+
[`picker-${mode}`]: true, 'overlay-hidden': true }, theme.getClassMap(this.cssClass)), onIonBackdropTap: this.onBackdropTap, onIonPickerWillDismiss: this.dispatchCancelHandler }), index.h("ion-backdrop", { key: '97fb8e10ba08b197610cb8c0cdea61103883d55f', visible: this.showBackdrop, tappable: this.backdropDismiss }), index.h("div", { key: 'b3969cb6fbf7153623d14e3ca1493d3370efb211', tabindex: "0", "aria-hidden": "true" }), index.h("div", { key: '299268483c3727e698d9135bfdf40349a7050ac1', class: "picker-wrapper ion-overlay-wrapper", role: "dialog" }, index.h("div", { key: '95394de3ef691899b7dbf416f56fd3e86bbdce3f', class: "picker-toolbar" }, this.buttons.map((b) => (index.h("div", { class: buttonWrapperClass(b) }, index.h("button", { type: "button", onClick: () => this.buttonClick(b), class: buttonClass(b) }, b.text))))), index.h("div", { key: '05f18bb8d00dc0e22f691b7e41f90f729a6c66d7', class: "picker-columns" }, index.h("div", { key: '4a8fdf224effc0af67fd413e2e6aca8a78d1cf43', class: "picker-above-highlight" }), this.presented && this.columns.map((c) => index.h("ion-picker-legacy-column", { col: c })), index.h("div", { key: 'e50a31db45e3f39e9d0fed36a21be9257eec09bf', class: "picker-below-highlight" }))), index.h("div", { key: '5a78cb2176ac807ea0c195c6b76cd0e8eef9d4c0', tabindex: "0", "aria-hidden": "true" })));
|
|
2228
|
+
}
|
|
2229
|
+
get el() { return index.getElement(this); }
|
|
2230
|
+
static get watchers() { return {
|
|
2231
|
+
"isOpen": [{
|
|
2232
|
+
"onIsOpenChange": 0
|
|
2233
|
+
}],
|
|
2234
|
+
"trigger": [{
|
|
2235
|
+
"triggerChanged": 0
|
|
2236
|
+
}]
|
|
2237
|
+
}; }
|
|
2238
|
+
};
|
|
2239
|
+
const buttonWrapperClass = (button) => {
|
|
2240
|
+
return {
|
|
2241
|
+
[`picker-toolbar-${button.role}`]: button.role !== undefined,
|
|
2242
|
+
'picker-toolbar-button': true,
|
|
2243
|
+
};
|
|
2244
|
+
};
|
|
2245
|
+
const buttonClass = (button) => {
|
|
2246
|
+
return Object.assign({ 'picker-button': true, 'ion-activatable': true }, theme.getClassMap(button.cssClass));
|
|
2247
|
+
};
|
|
2248
|
+
Picker.style = {
|
|
2249
|
+
ios: pickerIosCss(),
|
|
2250
|
+
md: pickerMdCss()
|
|
2251
|
+
};
|
|
2252
|
+
|
|
2253
|
+
const pickerColumnIosCss = () => `.picker-col{display:-ms-flexbox;display:flex;position:relative;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;height:100%;-webkit-box-sizing:content-box;box-sizing:content-box;contain:content}.picker-opts{position:relative;-ms-flex:1;flex:1;max-width:100%}.picker-opt{top:0;display:block;position:absolute;width:100%;border:0;text-align:center;text-overflow:ellipsis;white-space:nowrap;contain:strict;overflow:hidden;will-change:transform}.picker-opt{inset-inline-start:0}.picker-opt.picker-opt-disabled{pointer-events:none}.picker-opt-disabled{opacity:0}.picker-opts-left{-ms-flex-pack:start;justify-content:flex-start}.picker-opts-right{-ms-flex-pack:end;justify-content:flex-end}.picker-opt:active,.picker-opt:focus{outline:none}.picker-prefix{position:relative;-ms-flex:1;flex:1;text-align:end;white-space:nowrap}.picker-suffix{position:relative;-ms-flex:1;flex:1;text-align:start;white-space:nowrap}.picker-col{-webkit-padding-start:4px;padding-inline-start:4px;-webkit-padding-end:4px;padding-inline-end:4px;padding-top:0;padding-bottom:0;-webkit-transform-style:preserve-3d;transform-style:preserve-3d}.picker-prefix,.picker-suffix,.picker-opts{top:77px;-webkit-transform-style:preserve-3d;transform-style:preserve-3d;color:inherit;font-size:20px;line-height:42px;pointer-events:none}.picker-opt{padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;-webkit-transform-origin:center center;transform-origin:center center;height:46px;-webkit-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-transition-timing-function:ease-out;transition-timing-function:ease-out;background:transparent;color:inherit;font-size:20px;line-height:42px;-webkit-backface-visibility:hidden;backface-visibility:hidden;pointer-events:auto}:host-context([dir=rtl]) .picker-opt{-webkit-transform-origin:calc(100% - center) center;transform-origin:calc(100% - center) center}[dir=rtl] .picker-opt{-webkit-transform-origin:calc(100% - center) center;transform-origin:calc(100% - center) center}@supports selector(:dir(rtl)){.picker-opt:dir(rtl){-webkit-transform-origin:calc(100% - center) center;transform-origin:calc(100% - center) center}}`;
|
|
2254
|
+
|
|
2255
|
+
const pickerColumnMdCss = () => `.picker-col{display:-ms-flexbox;display:flex;position:relative;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;height:100%;-webkit-box-sizing:content-box;box-sizing:content-box;contain:content}.picker-opts{position:relative;-ms-flex:1;flex:1;max-width:100%}.picker-opt{top:0;display:block;position:absolute;width:100%;border:0;text-align:center;text-overflow:ellipsis;white-space:nowrap;contain:strict;overflow:hidden;will-change:transform}.picker-opt{inset-inline-start:0}.picker-opt.picker-opt-disabled{pointer-events:none}.picker-opt-disabled{opacity:0}.picker-opts-left{-ms-flex-pack:start;justify-content:flex-start}.picker-opts-right{-ms-flex-pack:end;justify-content:flex-end}.picker-opt:active,.picker-opt:focus{outline:none}.picker-prefix{position:relative;-ms-flex:1;flex:1;text-align:end;white-space:nowrap}.picker-suffix{position:relative;-ms-flex:1;flex:1;text-align:start;white-space:nowrap}.picker-col{-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:8px;padding-inline-end:8px;padding-top:0;padding-bottom:0;-webkit-transform-style:preserve-3d;transform-style:preserve-3d}.picker-prefix,.picker-suffix,.picker-opts{top:77px;-webkit-transform-style:preserve-3d;transform-style:preserve-3d;color:inherit;font-size:22px;line-height:42px;pointer-events:none}.picker-opt{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;height:43px;-webkit-transition-timing-function:ease-out;transition-timing-function:ease-out;background:transparent;color:inherit;font-size:22px;line-height:42px;-webkit-backface-visibility:hidden;backface-visibility:hidden;pointer-events:auto}.picker-prefix,.picker-suffix,.picker-opt.picker-opt-selected{color:var(--ion-color-primary, #0054e9)}`;
|
|
2256
|
+
|
|
2257
|
+
const PickerColumnCmp = class {
|
|
2258
|
+
constructor(hostRef) {
|
|
2259
|
+
index.registerInstance(this, hostRef);
|
|
2260
|
+
this.ionPickerColChange = index.createEvent(this, "ionPickerColChange", 7);
|
|
2261
|
+
this.optHeight = 0;
|
|
2262
|
+
this.rotateFactor = 0;
|
|
2263
|
+
this.scaleFactor = 1;
|
|
2264
|
+
this.velocity = 0;
|
|
2265
|
+
this.y = 0;
|
|
2266
|
+
this.noAnimate = true;
|
|
2267
|
+
// `colDidChange` is a flag that gets set when the column is changed
|
|
2268
|
+
// dynamically. When this flag is set, the column will refresh
|
|
2269
|
+
// after the component re-renders to incorporate the new column data.
|
|
2270
|
+
// This is necessary because `this.refresh` queries for the option elements,
|
|
2271
|
+
// so it needs to wait for the latest elements to be available in the DOM.
|
|
2272
|
+
// Ex: column is created with 3 options. User updates the column data
|
|
2273
|
+
// to have 5 options. The column will still think it only has 3 options.
|
|
2274
|
+
this.colDidChange = false;
|
|
2275
|
+
}
|
|
2276
|
+
colChanged() {
|
|
2277
|
+
this.colDidChange = true;
|
|
2278
|
+
}
|
|
2279
|
+
async connectedCallback() {
|
|
2280
|
+
let pickerRotateFactor = 0;
|
|
2281
|
+
let pickerScaleFactor = 0.81;
|
|
2282
|
+
const mode = ionicGlobal.getIonMode(this);
|
|
2283
|
+
if (mode === 'ios') {
|
|
2284
|
+
pickerRotateFactor = -0.46;
|
|
2285
|
+
pickerScaleFactor = 1;
|
|
2286
|
+
}
|
|
2287
|
+
this.rotateFactor = pickerRotateFactor;
|
|
2288
|
+
this.scaleFactor = pickerScaleFactor;
|
|
2289
|
+
this.gesture = (await Promise.resolve().then(function () { return require('./index-CAvQ7Tka.js'); })).createGesture({
|
|
2290
|
+
el: this.el,
|
|
2291
|
+
gestureName: 'picker-swipe',
|
|
2292
|
+
gesturePriority: 100,
|
|
2293
|
+
threshold: 0,
|
|
2294
|
+
passive: false,
|
|
2295
|
+
onStart: (ev) => this.onStart(ev),
|
|
2296
|
+
onMove: (ev) => this.onMove(ev),
|
|
2297
|
+
onEnd: (ev) => this.onEnd(ev),
|
|
2298
|
+
});
|
|
2299
|
+
this.gesture.enable();
|
|
2300
|
+
// Options have not been initialized yet
|
|
2301
|
+
// Animation must be disabled through the `noAnimate` flag
|
|
2302
|
+
// Otherwise, the options will render
|
|
2303
|
+
// at the top of the column and transition down
|
|
2304
|
+
this.tmrId = setTimeout(() => {
|
|
2305
|
+
this.noAnimate = false;
|
|
2306
|
+
// After initialization, `refresh()` will be called
|
|
2307
|
+
// At this point, animation will be enabled. The options will
|
|
2308
|
+
// animate as they are being selected.
|
|
2309
|
+
this.refresh(true);
|
|
2310
|
+
}, 250);
|
|
2311
|
+
}
|
|
2312
|
+
componentDidLoad() {
|
|
2313
|
+
this.onDomChange();
|
|
2314
|
+
}
|
|
2315
|
+
componentDidUpdate() {
|
|
2316
|
+
// Options may have changed since last update.
|
|
2317
|
+
if (this.colDidChange) {
|
|
2318
|
+
// Animation must be disabled through the `onDomChange` parameter.
|
|
2319
|
+
// Otherwise, the recently added options will render
|
|
2320
|
+
// at the top of the column and transition down
|
|
2321
|
+
this.onDomChange(true, false);
|
|
2322
|
+
this.colDidChange = false;
|
|
2323
|
+
}
|
|
2324
|
+
}
|
|
2325
|
+
disconnectedCallback() {
|
|
2326
|
+
if (this.rafId !== undefined)
|
|
2327
|
+
cancelAnimationFrame(this.rafId);
|
|
2328
|
+
if (this.tmrId)
|
|
2329
|
+
clearTimeout(this.tmrId);
|
|
2330
|
+
if (this.gesture) {
|
|
2331
|
+
this.gesture.destroy();
|
|
2332
|
+
this.gesture = undefined;
|
|
2333
|
+
}
|
|
2334
|
+
}
|
|
2335
|
+
emitColChange() {
|
|
2336
|
+
this.ionPickerColChange.emit(this.col);
|
|
2337
|
+
}
|
|
2338
|
+
setSelected(selectedIndex, duration) {
|
|
2339
|
+
// if there is a selected index, then figure out it's y position
|
|
2340
|
+
// if there isn't a selected index, then just use the top y position
|
|
2341
|
+
const y = selectedIndex > -1 ? -(selectedIndex * this.optHeight) : 0;
|
|
2342
|
+
this.velocity = 0;
|
|
2343
|
+
// set what y position we're at
|
|
2344
|
+
if (this.rafId !== undefined)
|
|
2345
|
+
cancelAnimationFrame(this.rafId);
|
|
2346
|
+
this.update(y, duration, true);
|
|
2347
|
+
this.emitColChange();
|
|
2348
|
+
}
|
|
2349
|
+
update(y, duration, saveY) {
|
|
2350
|
+
if (!this.optsEl) {
|
|
2351
|
+
return;
|
|
2352
|
+
}
|
|
2353
|
+
// ensure we've got a good round number :)
|
|
2354
|
+
let translateY = 0;
|
|
2355
|
+
let translateZ = 0;
|
|
2356
|
+
const { col, rotateFactor } = this;
|
|
2357
|
+
const prevSelected = col.selectedIndex;
|
|
2358
|
+
const selectedIndex = (col.selectedIndex = this.indexForY(-y));
|
|
2359
|
+
const durationStr = duration === 0 ? '' : duration + 'ms';
|
|
2360
|
+
const scaleStr = `scale(${this.scaleFactor})`;
|
|
2361
|
+
const children = this.optsEl.children;
|
|
2362
|
+
for (let i = 0; i < children.length; i++) {
|
|
2363
|
+
const button = children[i];
|
|
2364
|
+
const opt = col.options[i];
|
|
2365
|
+
const optOffset = i * this.optHeight + y;
|
|
2366
|
+
let transform = '';
|
|
2367
|
+
if (rotateFactor !== 0) {
|
|
2368
|
+
const rotateX = optOffset * rotateFactor;
|
|
2369
|
+
if (Math.abs(rotateX) <= 90) {
|
|
2370
|
+
translateY = 0;
|
|
2371
|
+
translateZ = 90;
|
|
2372
|
+
transform = `rotateX(${rotateX}deg) `;
|
|
2373
|
+
}
|
|
2374
|
+
else {
|
|
2375
|
+
translateY = -9999;
|
|
2376
|
+
}
|
|
2377
|
+
}
|
|
2378
|
+
else {
|
|
2379
|
+
translateZ = 0;
|
|
2380
|
+
translateY = optOffset;
|
|
2381
|
+
}
|
|
2382
|
+
const selected = selectedIndex === i;
|
|
2383
|
+
transform += `translate3d(0px,${translateY}px,${translateZ}px) `;
|
|
2384
|
+
if (this.scaleFactor !== 1 && !selected) {
|
|
2385
|
+
transform += scaleStr;
|
|
2386
|
+
}
|
|
2387
|
+
// Update transition duration
|
|
2388
|
+
if (this.noAnimate) {
|
|
2389
|
+
opt.duration = 0;
|
|
2390
|
+
button.style.transitionDuration = '';
|
|
2391
|
+
}
|
|
2392
|
+
else if (duration !== opt.duration) {
|
|
2393
|
+
opt.duration = duration;
|
|
2394
|
+
button.style.transitionDuration = durationStr;
|
|
2395
|
+
}
|
|
2396
|
+
// Update transform
|
|
2397
|
+
if (transform !== opt.transform) {
|
|
2398
|
+
opt.transform = transform;
|
|
2399
|
+
}
|
|
2400
|
+
button.style.transform = transform;
|
|
2401
|
+
/**
|
|
2402
|
+
* Ensure that the select column
|
|
2403
|
+
* item has the selected class
|
|
2404
|
+
*/
|
|
2405
|
+
opt.selected = selected;
|
|
2406
|
+
if (selected) {
|
|
2407
|
+
button.classList.add(PICKER_OPT_SELECTED);
|
|
2408
|
+
}
|
|
2409
|
+
else {
|
|
2410
|
+
button.classList.remove(PICKER_OPT_SELECTED);
|
|
2411
|
+
}
|
|
2412
|
+
}
|
|
2413
|
+
this.col.prevSelected = prevSelected;
|
|
2414
|
+
if (saveY) {
|
|
2415
|
+
this.y = y;
|
|
2416
|
+
}
|
|
2417
|
+
if (this.lastIndex !== selectedIndex) {
|
|
2418
|
+
// have not set a last index yet
|
|
2419
|
+
haptic.hapticSelectionChanged();
|
|
2420
|
+
this.lastIndex = selectedIndex;
|
|
2421
|
+
}
|
|
2422
|
+
}
|
|
2423
|
+
decelerate() {
|
|
2424
|
+
if (this.velocity !== 0) {
|
|
2425
|
+
// still decelerating
|
|
2426
|
+
this.velocity *= DECELERATION_FRICTION;
|
|
2427
|
+
// do not let it go slower than a velocity of 1
|
|
2428
|
+
this.velocity = this.velocity > 0 ? Math.max(this.velocity, 1) : Math.min(this.velocity, -1);
|
|
2429
|
+
let y = this.y + this.velocity;
|
|
2430
|
+
if (y > this.minY) {
|
|
2431
|
+
// whoops, it's trying to scroll up farther than the options we have!
|
|
2432
|
+
y = this.minY;
|
|
2433
|
+
this.velocity = 0;
|
|
2434
|
+
}
|
|
2435
|
+
else if (y < this.maxY) {
|
|
2436
|
+
// gahh, it's trying to scroll down farther than we can!
|
|
2437
|
+
y = this.maxY;
|
|
2438
|
+
this.velocity = 0;
|
|
2439
|
+
}
|
|
2440
|
+
this.update(y, 0, true);
|
|
2441
|
+
const notLockedIn = Math.round(y) % this.optHeight !== 0 || Math.abs(this.velocity) > 1;
|
|
2442
|
+
if (notLockedIn) {
|
|
2443
|
+
// isn't locked in yet, keep decelerating until it is
|
|
2444
|
+
this.rafId = requestAnimationFrame(() => this.decelerate());
|
|
2445
|
+
}
|
|
2446
|
+
else {
|
|
2447
|
+
this.velocity = 0;
|
|
2448
|
+
this.emitColChange();
|
|
2449
|
+
haptic.hapticSelectionEnd();
|
|
2450
|
+
}
|
|
2451
|
+
}
|
|
2452
|
+
else if (this.y % this.optHeight !== 0) {
|
|
2453
|
+
// needs to still get locked into a position so options line up
|
|
2454
|
+
const currentPos = Math.abs(this.y % this.optHeight);
|
|
2455
|
+
// create a velocity in the direction it needs to scroll
|
|
2456
|
+
this.velocity = currentPos > this.optHeight / 2 ? 1 : -1;
|
|
2457
|
+
this.decelerate();
|
|
2458
|
+
}
|
|
2459
|
+
}
|
|
2460
|
+
indexForY(y) {
|
|
2461
|
+
return Math.min(Math.max(Math.abs(Math.round(y / this.optHeight)), 0), this.col.options.length - 1);
|
|
2462
|
+
}
|
|
2463
|
+
onStart(detail) {
|
|
2464
|
+
// We have to prevent default in order to block scrolling under the picker
|
|
2465
|
+
// but we DO NOT have to stop propagation, since we still want
|
|
2466
|
+
// some "click" events to capture
|
|
2467
|
+
if (detail.event.cancelable) {
|
|
2468
|
+
detail.event.preventDefault();
|
|
2469
|
+
}
|
|
2470
|
+
detail.event.stopPropagation();
|
|
2471
|
+
haptic.hapticSelectionStart();
|
|
2472
|
+
// reset everything
|
|
2473
|
+
if (this.rafId !== undefined)
|
|
2474
|
+
cancelAnimationFrame(this.rafId);
|
|
2475
|
+
const options = this.col.options;
|
|
2476
|
+
let minY = options.length - 1;
|
|
2477
|
+
let maxY = 0;
|
|
2478
|
+
for (let i = 0; i < options.length; i++) {
|
|
2479
|
+
if (!options[i].disabled) {
|
|
2480
|
+
minY = Math.min(minY, i);
|
|
2481
|
+
maxY = Math.max(maxY, i);
|
|
2482
|
+
}
|
|
2483
|
+
}
|
|
2484
|
+
this.minY = -(minY * this.optHeight);
|
|
2485
|
+
this.maxY = -(maxY * this.optHeight);
|
|
2486
|
+
}
|
|
2487
|
+
onMove(detail) {
|
|
2488
|
+
if (detail.event.cancelable) {
|
|
2489
|
+
detail.event.preventDefault();
|
|
2490
|
+
}
|
|
2491
|
+
detail.event.stopPropagation();
|
|
2492
|
+
// update the scroll position relative to pointer start position
|
|
2493
|
+
let y = this.y + detail.deltaY;
|
|
2494
|
+
if (y > this.minY) {
|
|
2495
|
+
// scrolling up higher than scroll area
|
|
2496
|
+
y = Math.pow(y, 0.8);
|
|
2497
|
+
this.bounceFrom = y;
|
|
2498
|
+
}
|
|
2499
|
+
else if (y < this.maxY) {
|
|
2500
|
+
// scrolling down below scroll area
|
|
2501
|
+
y += Math.pow(this.maxY - y, 0.9);
|
|
2502
|
+
this.bounceFrom = y;
|
|
2503
|
+
}
|
|
2504
|
+
else {
|
|
2505
|
+
this.bounceFrom = 0;
|
|
2506
|
+
}
|
|
2507
|
+
this.update(y, 0, false);
|
|
2508
|
+
}
|
|
2509
|
+
onEnd(detail) {
|
|
2510
|
+
if (this.bounceFrom > 0) {
|
|
2511
|
+
// bounce back up
|
|
2512
|
+
this.update(this.minY, 100, true);
|
|
2513
|
+
this.emitColChange();
|
|
2514
|
+
return;
|
|
2515
|
+
}
|
|
2516
|
+
else if (this.bounceFrom < 0) {
|
|
2517
|
+
// bounce back down
|
|
2518
|
+
this.update(this.maxY, 100, true);
|
|
2519
|
+
this.emitColChange();
|
|
2520
|
+
return;
|
|
2521
|
+
}
|
|
2522
|
+
this.velocity = helpers.clamp(-90, detail.velocityY * 23, MAX_PICKER_SPEED);
|
|
2523
|
+
if (this.velocity === 0 && detail.deltaY === 0) {
|
|
2524
|
+
const opt = detail.event.target.closest('.picker-opt');
|
|
2525
|
+
if (opt === null || opt === void 0 ? void 0 : opt.hasAttribute('opt-index')) {
|
|
2526
|
+
this.setSelected(parseInt(opt.getAttribute('opt-index'), 10), TRANSITION_DURATION);
|
|
2527
|
+
}
|
|
2528
|
+
}
|
|
2529
|
+
else {
|
|
2530
|
+
this.y += detail.deltaY;
|
|
2531
|
+
if (Math.abs(detail.velocityY) < 0.05) {
|
|
2532
|
+
const isScrollingUp = detail.deltaY > 0;
|
|
2533
|
+
const optHeightFraction = (Math.abs(this.y) % this.optHeight) / this.optHeight;
|
|
2534
|
+
if (isScrollingUp && optHeightFraction > 0.5) {
|
|
2535
|
+
this.velocity = Math.abs(this.velocity) * -1;
|
|
2536
|
+
}
|
|
2537
|
+
else if (!isScrollingUp && optHeightFraction <= 0.5) {
|
|
2538
|
+
this.velocity = Math.abs(this.velocity);
|
|
2539
|
+
}
|
|
2540
|
+
}
|
|
2541
|
+
this.decelerate();
|
|
2542
|
+
}
|
|
2543
|
+
}
|
|
2544
|
+
refresh(forceRefresh, animated) {
|
|
2545
|
+
var _a;
|
|
2546
|
+
let min = this.col.options.length - 1;
|
|
2547
|
+
let max = 0;
|
|
2548
|
+
const options = this.col.options;
|
|
2549
|
+
for (let i = 0; i < options.length; i++) {
|
|
2550
|
+
if (!options[i].disabled) {
|
|
2551
|
+
min = Math.min(min, i);
|
|
2552
|
+
max = Math.max(max, i);
|
|
2553
|
+
}
|
|
2554
|
+
}
|
|
2555
|
+
/**
|
|
2556
|
+
* Only update selected value if column has a
|
|
2557
|
+
* velocity of 0. If it does not, then the
|
|
2558
|
+
* column is animating might land on
|
|
2559
|
+
* a value different than the value at
|
|
2560
|
+
* selectedIndex
|
|
2561
|
+
*/
|
|
2562
|
+
if (this.velocity !== 0) {
|
|
2563
|
+
return;
|
|
2564
|
+
}
|
|
2565
|
+
const selectedIndex = helpers.clamp(min, (_a = this.col.selectedIndex) !== null && _a !== void 0 ? _a : 0, max);
|
|
2566
|
+
if (this.col.prevSelected !== selectedIndex || forceRefresh) {
|
|
2567
|
+
const y = selectedIndex * this.optHeight * -1;
|
|
2568
|
+
const duration = animated ? TRANSITION_DURATION : 0;
|
|
2569
|
+
this.velocity = 0;
|
|
2570
|
+
this.update(y, duration, true);
|
|
2571
|
+
}
|
|
2572
|
+
}
|
|
2573
|
+
onDomChange(forceRefresh, animated) {
|
|
2574
|
+
const colEl = this.optsEl;
|
|
2575
|
+
if (colEl) {
|
|
2576
|
+
// DOM READ
|
|
2577
|
+
// We perfom a DOM read over a rendered item, this needs to happen after the first render or after the column has changed
|
|
2578
|
+
this.optHeight = colEl.firstElementChild ? colEl.firstElementChild.clientHeight : 0;
|
|
2579
|
+
}
|
|
2580
|
+
this.refresh(forceRefresh, animated);
|
|
2581
|
+
}
|
|
2582
|
+
render() {
|
|
2583
|
+
const col = this.col;
|
|
2584
|
+
const mode = ionicGlobal.getIonMode(this);
|
|
2585
|
+
return (index.h(index.Host, { key: '86125e95f18837dfd021db01777d72a1562d8ee3', class: Object.assign({ [mode]: true, 'picker-col': true, 'picker-opts-left': this.col.align === 'left', 'picker-opts-right': this.col.align === 'right' }, theme.getClassMap(col.cssClass)), style: {
|
|
2586
|
+
'max-width': this.col.columnWidth,
|
|
2587
|
+
} }, col.prefix && (index.h("div", { key: 'b0f3d39e0bd128781066ffefb7a1e40d12a9e76d', class: "picker-prefix", style: { width: col.prefixWidth } }, col.prefix)), index.h("div", { key: '0b106ac4d56916eaaa7f09d1b68348b3754b7bba', class: "picker-opts", style: { maxWidth: col.optionsWidth }, ref: (el) => (this.optsEl = el) }, col.options.map((o, index$1) => (index.h("button", { "aria-label": o.ariaLabel, class: { 'picker-opt': true, 'picker-opt-disabled': !!o.disabled }, "opt-index": index$1 }, o.text)))), col.suffix && (index.h("div", { key: '00ff2f9dbb4561787e5a5223327c6a2a33f8362e', class: "picker-suffix", style: { width: col.suffixWidth } }, col.suffix))));
|
|
2588
|
+
}
|
|
2589
|
+
get el() { return index.getElement(this); }
|
|
2590
|
+
static get watchers() { return {
|
|
2591
|
+
"col": [{
|
|
2592
|
+
"colChanged": 0
|
|
2593
|
+
}]
|
|
2594
|
+
}; }
|
|
2595
|
+
};
|
|
2596
|
+
const PICKER_OPT_SELECTED = 'picker-opt-selected';
|
|
2597
|
+
const DECELERATION_FRICTION = 0.97;
|
|
2598
|
+
const MAX_PICKER_SPEED = 90;
|
|
2599
|
+
const TRANSITION_DURATION = 150;
|
|
2600
|
+
PickerColumnCmp.style = {
|
|
2601
|
+
ios: pickerColumnIosCss(),
|
|
2602
|
+
md: pickerColumnMdCss()
|
|
2603
|
+
};
|
|
2604
|
+
|
|
1969
2605
|
exports.ion_datetime = Datetime;
|
|
2606
|
+
exports.ion_picker_legacy = Picker;
|
|
2607
|
+
exports.ion_picker_legacy_column = PickerColumnCmp;
|