@ozdao/martyrs 0.2.489 → 0.2.491
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/_virtual/index.cjs +4 -4
- package/dist/_virtual/index.js +4 -4
- package/dist/_virtual/index2.cjs +4 -4
- package/dist/_virtual/index2.js +4 -4
- package/dist/auth.server.cjs +2 -51
- package/dist/auth.server.js +1 -50
- package/dist/builder.cjs +90 -4
- package/dist/builder.js +90 -4
- package/dist/main-BhCqlPMQ.cjs +11 -0
- package/dist/{main-IVRL6IjM.js → main-YBlKbx0g.js} +1308 -1285
- package/dist/martyrs/src/components/Block/Block.vue.cjs +1 -1
- package/dist/martyrs/src/components/Block/Block.vue.js +1 -1
- package/dist/martyrs/src/components/Button/Button.vue2.cjs +48 -21
- package/dist/martyrs/src/components/Button/Button.vue2.cjs.map +1 -1
- package/dist/martyrs/src/components/Button/Button.vue2.js +49 -22
- package/dist/martyrs/src/components/Button/Button.vue2.js.map +1 -1
- package/dist/martyrs/src/components/Chips/{Chips.vue2.cjs → Chips.vue.cjs} +2 -2
- package/dist/martyrs/src/components/Chips/Chips.vue.cjs.map +1 -0
- package/dist/martyrs/src/components/Chips/{Chips.vue2.js → Chips.vue.js} +2 -2
- package/dist/martyrs/src/components/Chips/Chips.vue.js.map +1 -0
- package/dist/martyrs/src/components/Dropdown/{Dropdown.vue.cjs → Dropdown.vue2.cjs} +2 -2
- package/dist/martyrs/src/components/Dropdown/Dropdown.vue2.cjs.map +1 -0
- package/dist/martyrs/src/components/Dropdown/{Dropdown.vue.js → Dropdown.vue2.js} +2 -2
- package/dist/martyrs/src/components/Dropdown/{Dropdown.vue.cjs.map → Dropdown.vue2.js.map} +1 -1
- package/dist/martyrs/src/components/Feed/Carousel.vue.cjs +1 -1
- package/dist/martyrs/src/components/Feed/Carousel.vue.js +1 -1
- package/dist/martyrs/src/components/Feed/Feed.vue.cjs +2 -2
- package/dist/martyrs/src/components/Feed/Feed.vue.js +2 -2
- package/dist/martyrs/src/components/FieldTags/FieldTags.vue.cjs +1 -1
- package/dist/martyrs/src/components/FieldTags/FieldTags.vue.js +1 -1
- package/dist/martyrs/src/components/Loader/{Loader.vue2.cjs → Loader.vue.cjs} +3 -3
- package/dist/martyrs/src/components/Loader/Loader.vue.cjs.map +1 -0
- package/dist/martyrs/src/components/Loader/{Loader.vue2.js → Loader.vue.js} +3 -3
- package/dist/martyrs/src/components/Loader/Loader.vue.js.map +1 -0
- package/dist/martyrs/src/components/LocationMarker/LocationMarker.vue2.cjs +1 -1
- package/dist/martyrs/src/components/LocationMarker/LocationMarker.vue2.js +1 -1
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue2.cjs → Tooltip.vue.cjs} +2 -2
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue2.js.map → Tooltip.vue.cjs.map} +1 -1
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue2.js → Tooltip.vue.js} +2 -2
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue.js.map +1 -0
- package/dist/martyrs/src/components/UploadImageMultiple/UploadImageMultiple.vue.cjs +1 -1
- package/dist/martyrs/src/components/UploadImageMultiple/UploadImageMultiple.vue.js +1 -1
- package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.cjs +2 -2
- package/dist/martyrs/src/modules/auth/views/components/pages/Profile.vue.js +2 -2
- package/dist/martyrs/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
- package/dist/martyrs/src/modules/community/components/blocks/CardBlogpost.vue.js +1 -1
- package/dist/martyrs/src/modules/community/components/pages/BlogPost.vue.cjs +2 -2
- package/dist/martyrs/src/modules/community/components/pages/BlogPost.vue.js +2 -2
- package/dist/martyrs/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
- package/dist/martyrs/src/modules/community/components/pages/CreateBlogPost.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.cjs +1 -1
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EditEvent.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.cjs +3 -3
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.js +3 -3
- package/dist/martyrs/src/modules/events/components/sections/Feed.vue.cjs +1 -1
- package/dist/martyrs/src/modules/events/components/sections/Feed.vue.js +1 -1
- package/dist/martyrs/src/modules/events/components/sections/List.vue.cjs +1 -1
- package/dist/martyrs/src/modules/events/components/sections/List.vue.js +1 -1
- package/dist/martyrs/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
- package/dist/martyrs/src/modules/gallery/components/sections/BackofficeGallery.vue.js +1 -1
- package/dist/martyrs/src/modules/globals/globals.client.cjs +1 -2
- package/dist/martyrs/src/modules/globals/globals.client.cjs.map +1 -1
- package/dist/martyrs/src/modules/globals/globals.client.js +1 -2
- package/dist/martyrs/src/modules/globals/globals.client.js.map +1 -1
- package/dist/martyrs/src/modules/globals/views/classes/globals.i18n.cjs +1 -1
- package/dist/martyrs/src/modules/globals/views/classes/globals.i18n.js +1 -1
- package/dist/martyrs/src/modules/globals/views/components/blocks/CardHeader.vue.cjs +3 -3
- package/dist/martyrs/src/modules/globals/views/components/blocks/CardHeader.vue.js +3 -3
- package/dist/martyrs/src/modules/globals/views/components/blocks/PopupDateSelector.vue.cjs +1 -1
- package/dist/martyrs/src/modules/globals/views/components/blocks/PopupDateSelector.vue.js +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.cjs +10 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.js +10 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.js.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/partials/Navigation.vue.cjs +1 -1
- package/dist/martyrs/src/modules/globals/views/components/partials/Navigation.vue.js +1 -1
- package/dist/martyrs/src/modules/marketplace/views/components/sections/SectionMenu.vue.cjs +1 -1
- package/dist/martyrs/src/modules/marketplace/views/components/sections/SectionMenu.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/forms/ArtistForm.vue.cjs +1 -1
- package/dist/martyrs/src/modules/music/components/forms/ArtistForm.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/layouts/MusicLayout.vue.cjs +2 -2
- package/dist/martyrs/src/modules/music/components/layouts/MusicLayout.vue.js +2 -2
- package/dist/martyrs/src/modules/music/components/pages/Album.vue.cjs +2 -2
- package/dist/martyrs/src/modules/music/components/pages/Album.vue.js +2 -2
- package/dist/martyrs/src/modules/music/components/pages/Artist.vue.cjs +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Artist.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Playlist.vue.cjs +2 -2
- package/dist/martyrs/src/modules/music/components/pages/Playlist.vue.js +2 -2
- package/dist/martyrs/src/modules/music/components/pages/SearchResults.vue.cjs +1 -1
- package/dist/martyrs/src/modules/music/components/pages/SearchResults.vue.js +1 -1
- package/dist/martyrs/src/modules/music/components/pages/Track.vue.cjs +2 -2
- package/dist/martyrs/src/modules/music/components/pages/Track.vue.js +2 -2
- package/dist/martyrs/src/modules/music/components/pages/TrackCreate.vue.cjs +1 -1
- package/dist/martyrs/src/modules/music/components/pages/TrackCreate.vue.js +1 -1
- package/dist/martyrs/src/modules/notifications/components/layouts/NotificationsLayout.vue.cjs +22 -8
- package/dist/martyrs/src/modules/notifications/components/layouts/NotificationsLayout.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/layouts/NotificationsLayout.vue.js +23 -9
- package/dist/martyrs/src/modules/notifications/components/layouts/NotificationsLayout.vue.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/pages/Notifications.vue.cjs +13 -15
- package/dist/martyrs/src/modules/notifications/components/pages/Notifications.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/pages/Notifications.vue.js +14 -16
- package/dist/martyrs/src/modules/notifications/components/pages/Notifications.vue.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationPreferences.vue.cjs +2 -2
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationPreferences.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationPreferences.vue.js +2 -2
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationPreferences.vue.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationsList.vue.cjs +2 -2
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationsList.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationsList.vue.js +2 -2
- package/dist/martyrs/src/modules/notifications/components/sections/NotificationsList.vue.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/notifications.client.cjs +1 -1
- package/dist/martyrs/src/modules/notifications/notifications.client.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/notifications.client.js +7 -7
- package/dist/martyrs/src/modules/notifications/notifications.client.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/router/notifications.router.js +4 -4
- package/dist/martyrs/src/modules/notifications/router/notifications.router.js.map +1 -1
- package/dist/martyrs/src/modules/notifications/store/notifications.store.cjs +7 -10
- package/dist/martyrs/src/modules/notifications/store/notifications.store.cjs.map +1 -1
- package/dist/martyrs/src/modules/notifications/store/notifications.store.js +7 -10
- package/dist/martyrs/src/modules/notifications/store/notifications.store.js.map +1 -1
- package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.cjs +1 -1
- package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/pages/OrderBackoffice.vue.cjs +1 -1
- package/dist/martyrs/src/modules/orders/components/pages/OrderBackoffice.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.cjs +0 -1
- package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.js +0 -1
- package/dist/martyrs/src/modules/orders/components/partials/ShopCart.vue.js.map +1 -1
- package/dist/martyrs/src/modules/orders/components/sections/FormDelivery.vue.cjs +2 -2
- package/dist/martyrs/src/modules/orders/components/sections/FormDelivery.vue.js +2 -2
- package/dist/martyrs/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/blocks/CardOrganization.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/DepartmentEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/DetailsTabSection.vue.cjs +2 -2
- package/dist/martyrs/src/modules/organizations/components/sections/DetailsTabSection.vue.js +2 -2
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Organizations.vue.js +1 -1
- package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.cjs +1 -1
- package/dist/martyrs/src/modules/pages/views/components/blocks/CardPage.vue.js +1 -1
- package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.cjs +1 -1
- package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/blocks/ProductDiscounts.vue.cjs +2 -2
- package/dist/martyrs/src/modules/products/components/blocks/ProductDiscounts.vue.js +2 -2
- package/dist/martyrs/src/modules/products/components/elements/Image360.vue.cjs +1 -1
- package/dist/martyrs/src/modules/products/components/elements/Image360.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Categories.vue.cjs +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Categories.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/pages/CategoryEdit.vue.cjs +2 -2
- package/dist/martyrs/src/modules/products/components/pages/CategoryEdit.vue.js +2 -2
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.cjs +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/pages/ProductRecommmendation.vue.cjs +1 -1
- package/dist/martyrs/src/modules/products/components/pages/ProductRecommmendation.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
- package/dist/martyrs/src/modules/spots/components/blocks/CardSpot.vue.js +1 -1
- package/dist/martyrs/src/modules/spots/components/layouts/Spots.vue.cjs +1 -1
- package/dist/martyrs/src/modules/spots/components/layouts/Spots.vue.js +1 -1
- package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.cjs +3 -3
- package/dist/martyrs/src/modules/wallet/views/components/pages/Wallet.vue.js +3 -3
- package/dist/martyrs.cjs.js +1 -1
- package/dist/martyrs.css +1 -1
- package/dist/martyrs.es.js +1 -1
- package/dist/notifications.server.cjs +142 -44
- package/dist/notifications.server.js +142 -44
- package/dist/orders.server.cjs +155 -102
- package/dist/orders.server.js +155 -102
- package/dist/products.server.cjs +4 -0
- package/dist/products.server.js +4 -0
- package/dist/profile.schema-BGAe5VN5.js +92 -0
- package/dist/profile.schema-pidHrksV.cjs +91 -0
- package/dist/style.css +65 -247
- package/dist/{web-BXhlxo6M.cjs → web-BBmMBRv-.cjs} +1 -1
- package/dist/{web-Czi05iGG.js → web-Dqu-aCL5.js} +1 -1
- package/package.json +1 -1
- package/src/builder/rspack/rspack.config.spa.client.js +46 -1
- package/src/builder/rspack/rspack.config.ssr.client.js +43 -0
- package/src/builder/templates/page.js +1 -1
- package/src/components/Button/Button.vue +230 -196
- package/src/components/Loader/Loader.vue +1 -1
- package/src/modules/auth/controllers/middlewares/visitor.logger.js +22 -0
- package/src/modules/globals/globals.client.js +1 -1
- package/src/modules/globals/views/components/layouts/Client.vue +10 -9
- package/src/modules/notifications/FIXES.md +4 -0
- package/src/modules/notifications/components/layouts/NotificationsLayout.vue +33 -32
- package/src/modules/notifications/components/pages/Notifications.vue +10 -51
- package/src/modules/notifications/components/sections/NotificationPreferences.vue +1 -11
- package/src/modules/notifications/components/sections/NotificationsList.vue +1 -1
- package/src/modules/notifications/controllers/notifications.controller.js +50 -4
- package/src/modules/notifications/notifications.client.js +1 -1
- package/src/modules/notifications/notifications.server.js +18 -7
- package/src/modules/notifications/routes/notifications.routes.js +4 -2
- package/src/modules/notifications/services/notification.service.js +109 -38
- package/src/modules/notifications/services/telegram.service.js +1 -0
- package/src/modules/notifications/services/whatsapp.service.js +1 -0
- package/src/modules/notifications/store/notifications.store.js +25 -16
- package/src/modules/orders/components/partials/ShopCart.vue +0 -1
- package/src/modules/orders/controllers/orders.controller.js +195 -85
- package/src/modules/products/controllers/products.controller.js +4 -0
- package/dist/main-CmuUC0tl.cjs +0 -11
- package/dist/martyrs/src/components/Chips/Chips.vue2.cjs.map +0 -1
- package/dist/martyrs/src/components/Chips/Chips.vue2.js.map +0 -1
- package/dist/martyrs/src/components/Dropdown/Dropdown.vue.js.map +0 -1
- package/dist/martyrs/src/components/Loader/Loader.vue2.cjs.map +0 -1
- package/dist/martyrs/src/components/Loader/Loader.vue2.js.map +0 -1
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue2.cjs.map +0 -1
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/StoreDebugger.vue.cjs +0 -200
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/StoreDebugger.vue.cjs.map +0 -1
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/StoreDebugger.vue.js +0 -200
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/StoreDebugger.vue.js.map +0 -1
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/store-debugger.plugin.cjs +0 -21
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/store-debugger.plugin.cjs.map +0 -1
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/store-debugger.plugin.js +0 -21
- package/dist/martyrs/src/modules/globals/views/plugins/store-debugger/store-debugger.plugin.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/addLeadingZeros.cjs +0 -9
- package/dist/node_modules/date-fns/_lib/addLeadingZeros.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/addLeadingZeros.js +0 -9
- package/dist/node_modules/date-fns/_lib/addLeadingZeros.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/defaultOptions.cjs +0 -8
- package/dist/node_modules/date-fns/_lib/defaultOptions.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/defaultOptions.js +0 -8
- package/dist/node_modules/date-fns/_lib/defaultOptions.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/formatters.cjs +0 -653
- package/dist/node_modules/date-fns/_lib/format/formatters.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/formatters.js +0 -653
- package/dist/node_modules/date-fns/_lib/format/formatters.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/lightFormatters.cjs +0 -63
- package/dist/node_modules/date-fns/_lib/format/lightFormatters.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/lightFormatters.js +0 -63
- package/dist/node_modules/date-fns/_lib/format/lightFormatters.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/longFormatters.cjs +0 -59
- package/dist/node_modules/date-fns/_lib/format/longFormatters.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/format/longFormatters.js +0 -59
- package/dist/node_modules/date-fns/_lib/format/longFormatters.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.cjs +0 -21
- package/dist/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js +0 -21
- package/dist/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/normalizeDates.cjs +0 -12
- package/dist/node_modules/date-fns/_lib/normalizeDates.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/normalizeDates.js +0 -12
- package/dist/node_modules/date-fns/_lib/normalizeDates.js.map +0 -1
- package/dist/node_modules/date-fns/_lib/protectedTokens.cjs +0 -24
- package/dist/node_modules/date-fns/_lib/protectedTokens.cjs.map +0 -1
- package/dist/node_modules/date-fns/_lib/protectedTokens.js +0 -24
- package/dist/node_modules/date-fns/_lib/protectedTokens.js.map +0 -1
- package/dist/node_modules/date-fns/constants.cjs +0 -9
- package/dist/node_modules/date-fns/constants.cjs.map +0 -1
- package/dist/node_modules/date-fns/constants.js +0 -9
- package/dist/node_modules/date-fns/constants.js.map +0 -1
- package/dist/node_modules/date-fns/constructFrom.cjs +0 -13
- package/dist/node_modules/date-fns/constructFrom.cjs.map +0 -1
- package/dist/node_modules/date-fns/constructFrom.js +0 -13
- package/dist/node_modules/date-fns/constructFrom.js.map +0 -1
- package/dist/node_modules/date-fns/differenceInCalendarDays.cjs +0 -21
- package/dist/node_modules/date-fns/differenceInCalendarDays.cjs.map +0 -1
- package/dist/node_modules/date-fns/differenceInCalendarDays.js +0 -21
- package/dist/node_modules/date-fns/differenceInCalendarDays.js.map +0 -1
- package/dist/node_modules/date-fns/format.cjs +0 -80
- package/dist/node_modules/date-fns/format.cjs.map +0 -1
- package/dist/node_modules/date-fns/format.js +0 -80
- package/dist/node_modules/date-fns/format.js.map +0 -1
- package/dist/node_modules/date-fns/getDayOfYear.cjs +0 -14
- package/dist/node_modules/date-fns/getDayOfYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/getDayOfYear.js +0 -14
- package/dist/node_modules/date-fns/getDayOfYear.js.map +0 -1
- package/dist/node_modules/date-fns/getISOWeek.cjs +0 -14
- package/dist/node_modules/date-fns/getISOWeek.cjs.map +0 -1
- package/dist/node_modules/date-fns/getISOWeek.js +0 -14
- package/dist/node_modules/date-fns/getISOWeek.js.map +0 -1
- package/dist/node_modules/date-fns/getISOWeekYear.cjs +0 -27
- package/dist/node_modules/date-fns/getISOWeekYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/getISOWeekYear.js +0 -27
- package/dist/node_modules/date-fns/getISOWeekYear.js.map +0 -1
- package/dist/node_modules/date-fns/getWeek.cjs +0 -14
- package/dist/node_modules/date-fns/getWeek.cjs.map +0 -1
- package/dist/node_modules/date-fns/getWeek.js +0 -14
- package/dist/node_modules/date-fns/getWeek.js.map +0 -1
- package/dist/node_modules/date-fns/getWeekYear.cjs +0 -31
- package/dist/node_modules/date-fns/getWeekYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/getWeekYear.js +0 -31
- package/dist/node_modules/date-fns/getWeekYear.js.map +0 -1
- package/dist/node_modules/date-fns/isDate.cjs +0 -8
- package/dist/node_modules/date-fns/isDate.cjs.map +0 -1
- package/dist/node_modules/date-fns/isDate.js +0 -8
- package/dist/node_modules/date-fns/isDate.js.map +0 -1
- package/dist/node_modules/date-fns/isValid.cjs +0 -10
- package/dist/node_modules/date-fns/isValid.cjs.map +0 -1
- package/dist/node_modules/date-fns/isValid.js +0 -10
- package/dist/node_modules/date-fns/isValid.js.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildFormatLongFn.cjs +0 -11
- package/dist/node_modules/date-fns/locale/_lib/buildFormatLongFn.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildFormatLongFn.js +0 -11
- package/dist/node_modules/date-fns/locale/_lib/buildFormatLongFn.js.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildLocalizeFn.cjs +0 -21
- package/dist/node_modules/date-fns/locale/_lib/buildLocalizeFn.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildLocalizeFn.js +0 -21
- package/dist/node_modules/date-fns/locale/_lib/buildLocalizeFn.js.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildMatchFn.cjs +0 -44
- package/dist/node_modules/date-fns/locale/_lib/buildMatchFn.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildMatchFn.js +0 -44
- package/dist/node_modules/date-fns/locale/_lib/buildMatchFn.js.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildMatchPatternFn.cjs +0 -17
- package/dist/node_modules/date-fns/locale/_lib/buildMatchPatternFn.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js +0 -17
- package/dist/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatDistance.cjs +0 -86
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatDistance.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatDistance.js +0 -86
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatDistance.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatLong.cjs +0 -37
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatLong.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatLong.js +0 -37
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatLong.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatRelative.cjs +0 -13
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatRelative.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatRelative.js +0 -13
- package/dist/node_modules/date-fns/locale/en-US/_lib/formatRelative.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/localize.cjs +0 -165
- package/dist/node_modules/date-fns/locale/en-US/_lib/localize.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/localize.js +0 -165
- package/dist/node_modules/date-fns/locale/en-US/_lib/localize.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/match.cjs +0 -123
- package/dist/node_modules/date-fns/locale/en-US/_lib/match.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US/_lib/match.js +0 -123
- package/dist/node_modules/date-fns/locale/en-US/_lib/match.js.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US.cjs +0 -22
- package/dist/node_modules/date-fns/locale/en-US.cjs.map +0 -1
- package/dist/node_modules/date-fns/locale/en-US.js +0 -22
- package/dist/node_modules/date-fns/locale/en-US.js.map +0 -1
- package/dist/node_modules/date-fns/startOfDay.cjs +0 -11
- package/dist/node_modules/date-fns/startOfDay.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfDay.js +0 -11
- package/dist/node_modules/date-fns/startOfDay.js.map +0 -1
- package/dist/node_modules/date-fns/startOfISOWeek.cjs +0 -9
- package/dist/node_modules/date-fns/startOfISOWeek.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfISOWeek.js +0 -9
- package/dist/node_modules/date-fns/startOfISOWeek.js.map +0 -1
- package/dist/node_modules/date-fns/startOfISOWeekYear.cjs +0 -15
- package/dist/node_modules/date-fns/startOfISOWeekYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfISOWeekYear.js +0 -15
- package/dist/node_modules/date-fns/startOfISOWeekYear.js.map +0 -1
- package/dist/node_modules/date-fns/startOfWeek.cjs +0 -18
- package/dist/node_modules/date-fns/startOfWeek.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfWeek.js +0 -18
- package/dist/node_modules/date-fns/startOfWeek.js.map +0 -1
- package/dist/node_modules/date-fns/startOfWeekYear.cjs +0 -20
- package/dist/node_modules/date-fns/startOfWeekYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfWeekYear.js +0 -20
- package/dist/node_modules/date-fns/startOfWeekYear.js.map +0 -1
- package/dist/node_modules/date-fns/startOfYear.cjs +0 -12
- package/dist/node_modules/date-fns/startOfYear.cjs.map +0 -1
- package/dist/node_modules/date-fns/startOfYear.js +0 -12
- package/dist/node_modules/date-fns/startOfYear.js.map +0 -1
- package/dist/node_modules/date-fns/toDate.cjs +0 -9
- package/dist/node_modules/date-fns/toDate.cjs.map +0 -1
- package/dist/node_modules/date-fns/toDate.js +0 -9
- package/dist/node_modules/date-fns/toDate.js.map +0 -1
- package/dist/profile.schema-DchVS-Jr.js +0 -21
- package/dist/profile.schema-yQuIzngl.cjs +0 -20
|
@@ -1,653 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const getDayOfYear = require("../../getDayOfYear.cjs");
|
|
4
|
-
const getISOWeek = require("../../getISOWeek.cjs");
|
|
5
|
-
const getISOWeekYear = require("../../getISOWeekYear.cjs");
|
|
6
|
-
const getWeek = require("../../getWeek.cjs");
|
|
7
|
-
const getWeekYear = require("../../getWeekYear.cjs");
|
|
8
|
-
const addLeadingZeros = require("../addLeadingZeros.cjs");
|
|
9
|
-
const lightFormatters = require("./lightFormatters.cjs");
|
|
10
|
-
const dayPeriodEnum = {
|
|
11
|
-
midnight: "midnight",
|
|
12
|
-
noon: "noon",
|
|
13
|
-
morning: "morning",
|
|
14
|
-
afternoon: "afternoon",
|
|
15
|
-
evening: "evening",
|
|
16
|
-
night: "night"
|
|
17
|
-
};
|
|
18
|
-
const formatters = {
|
|
19
|
-
// Era
|
|
20
|
-
G: function(date, token, localize) {
|
|
21
|
-
const era = date.getFullYear() > 0 ? 1 : 0;
|
|
22
|
-
switch (token) {
|
|
23
|
-
// AD, BC
|
|
24
|
-
case "G":
|
|
25
|
-
case "GG":
|
|
26
|
-
case "GGG":
|
|
27
|
-
return localize.era(era, { width: "abbreviated" });
|
|
28
|
-
// A, B
|
|
29
|
-
case "GGGGG":
|
|
30
|
-
return localize.era(era, { width: "narrow" });
|
|
31
|
-
// Anno Domini, Before Christ
|
|
32
|
-
case "GGGG":
|
|
33
|
-
default:
|
|
34
|
-
return localize.era(era, { width: "wide" });
|
|
35
|
-
}
|
|
36
|
-
},
|
|
37
|
-
// Year
|
|
38
|
-
y: function(date, token, localize) {
|
|
39
|
-
if (token === "yo") {
|
|
40
|
-
const signedYear = date.getFullYear();
|
|
41
|
-
const year = signedYear > 0 ? signedYear : 1 - signedYear;
|
|
42
|
-
return localize.ordinalNumber(year, { unit: "year" });
|
|
43
|
-
}
|
|
44
|
-
return lightFormatters.lightFormatters.y(date, token);
|
|
45
|
-
},
|
|
46
|
-
// Local week-numbering year
|
|
47
|
-
Y: function(date, token, localize, options) {
|
|
48
|
-
const signedWeekYear = getWeekYear.getWeekYear(date, options);
|
|
49
|
-
const weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear;
|
|
50
|
-
if (token === "YY") {
|
|
51
|
-
const twoDigitYear = weekYear % 100;
|
|
52
|
-
return addLeadingZeros.addLeadingZeros(twoDigitYear, 2);
|
|
53
|
-
}
|
|
54
|
-
if (token === "Yo") {
|
|
55
|
-
return localize.ordinalNumber(weekYear, { unit: "year" });
|
|
56
|
-
}
|
|
57
|
-
return addLeadingZeros.addLeadingZeros(weekYear, token.length);
|
|
58
|
-
},
|
|
59
|
-
// ISO week-numbering year
|
|
60
|
-
R: function(date, token) {
|
|
61
|
-
const isoWeekYear = getISOWeekYear.getISOWeekYear(date);
|
|
62
|
-
return addLeadingZeros.addLeadingZeros(isoWeekYear, token.length);
|
|
63
|
-
},
|
|
64
|
-
// Extended year. This is a single number designating the year of this calendar system.
|
|
65
|
-
// The main difference between `y` and `u` localizers are B.C. years:
|
|
66
|
-
// | Year | `y` | `u` |
|
|
67
|
-
// |------|-----|-----|
|
|
68
|
-
// | AC 1 | 1 | 1 |
|
|
69
|
-
// | BC 1 | 1 | 0 |
|
|
70
|
-
// | BC 2 | 2 | -1 |
|
|
71
|
-
// Also `yy` always returns the last two digits of a year,
|
|
72
|
-
// while `uu` pads single digit years to 2 characters and returns other years unchanged.
|
|
73
|
-
u: function(date, token) {
|
|
74
|
-
const year = date.getFullYear();
|
|
75
|
-
return addLeadingZeros.addLeadingZeros(year, token.length);
|
|
76
|
-
},
|
|
77
|
-
// Quarter
|
|
78
|
-
Q: function(date, token, localize) {
|
|
79
|
-
const quarter = Math.ceil((date.getMonth() + 1) / 3);
|
|
80
|
-
switch (token) {
|
|
81
|
-
// 1, 2, 3, 4
|
|
82
|
-
case "Q":
|
|
83
|
-
return String(quarter);
|
|
84
|
-
// 01, 02, 03, 04
|
|
85
|
-
case "QQ":
|
|
86
|
-
return addLeadingZeros.addLeadingZeros(quarter, 2);
|
|
87
|
-
// 1st, 2nd, 3rd, 4th
|
|
88
|
-
case "Qo":
|
|
89
|
-
return localize.ordinalNumber(quarter, { unit: "quarter" });
|
|
90
|
-
// Q1, Q2, Q3, Q4
|
|
91
|
-
case "QQQ":
|
|
92
|
-
return localize.quarter(quarter, {
|
|
93
|
-
width: "abbreviated",
|
|
94
|
-
context: "formatting"
|
|
95
|
-
});
|
|
96
|
-
// 1, 2, 3, 4 (narrow quarter; could be not numerical)
|
|
97
|
-
case "QQQQQ":
|
|
98
|
-
return localize.quarter(quarter, {
|
|
99
|
-
width: "narrow",
|
|
100
|
-
context: "formatting"
|
|
101
|
-
});
|
|
102
|
-
// 1st quarter, 2nd quarter, ...
|
|
103
|
-
case "QQQQ":
|
|
104
|
-
default:
|
|
105
|
-
return localize.quarter(quarter, {
|
|
106
|
-
width: "wide",
|
|
107
|
-
context: "formatting"
|
|
108
|
-
});
|
|
109
|
-
}
|
|
110
|
-
},
|
|
111
|
-
// Stand-alone quarter
|
|
112
|
-
q: function(date, token, localize) {
|
|
113
|
-
const quarter = Math.ceil((date.getMonth() + 1) / 3);
|
|
114
|
-
switch (token) {
|
|
115
|
-
// 1, 2, 3, 4
|
|
116
|
-
case "q":
|
|
117
|
-
return String(quarter);
|
|
118
|
-
// 01, 02, 03, 04
|
|
119
|
-
case "qq":
|
|
120
|
-
return addLeadingZeros.addLeadingZeros(quarter, 2);
|
|
121
|
-
// 1st, 2nd, 3rd, 4th
|
|
122
|
-
case "qo":
|
|
123
|
-
return localize.ordinalNumber(quarter, { unit: "quarter" });
|
|
124
|
-
// Q1, Q2, Q3, Q4
|
|
125
|
-
case "qqq":
|
|
126
|
-
return localize.quarter(quarter, {
|
|
127
|
-
width: "abbreviated",
|
|
128
|
-
context: "standalone"
|
|
129
|
-
});
|
|
130
|
-
// 1, 2, 3, 4 (narrow quarter; could be not numerical)
|
|
131
|
-
case "qqqqq":
|
|
132
|
-
return localize.quarter(quarter, {
|
|
133
|
-
width: "narrow",
|
|
134
|
-
context: "standalone"
|
|
135
|
-
});
|
|
136
|
-
// 1st quarter, 2nd quarter, ...
|
|
137
|
-
case "qqqq":
|
|
138
|
-
default:
|
|
139
|
-
return localize.quarter(quarter, {
|
|
140
|
-
width: "wide",
|
|
141
|
-
context: "standalone"
|
|
142
|
-
});
|
|
143
|
-
}
|
|
144
|
-
},
|
|
145
|
-
// Month
|
|
146
|
-
M: function(date, token, localize) {
|
|
147
|
-
const month = date.getMonth();
|
|
148
|
-
switch (token) {
|
|
149
|
-
case "M":
|
|
150
|
-
case "MM":
|
|
151
|
-
return lightFormatters.lightFormatters.M(date, token);
|
|
152
|
-
// 1st, 2nd, ..., 12th
|
|
153
|
-
case "Mo":
|
|
154
|
-
return localize.ordinalNumber(month + 1, { unit: "month" });
|
|
155
|
-
// Jan, Feb, ..., Dec
|
|
156
|
-
case "MMM":
|
|
157
|
-
return localize.month(month, {
|
|
158
|
-
width: "abbreviated",
|
|
159
|
-
context: "formatting"
|
|
160
|
-
});
|
|
161
|
-
// J, F, ..., D
|
|
162
|
-
case "MMMMM":
|
|
163
|
-
return localize.month(month, {
|
|
164
|
-
width: "narrow",
|
|
165
|
-
context: "formatting"
|
|
166
|
-
});
|
|
167
|
-
// January, February, ..., December
|
|
168
|
-
case "MMMM":
|
|
169
|
-
default:
|
|
170
|
-
return localize.month(month, { width: "wide", context: "formatting" });
|
|
171
|
-
}
|
|
172
|
-
},
|
|
173
|
-
// Stand-alone month
|
|
174
|
-
L: function(date, token, localize) {
|
|
175
|
-
const month = date.getMonth();
|
|
176
|
-
switch (token) {
|
|
177
|
-
// 1, 2, ..., 12
|
|
178
|
-
case "L":
|
|
179
|
-
return String(month + 1);
|
|
180
|
-
// 01, 02, ..., 12
|
|
181
|
-
case "LL":
|
|
182
|
-
return addLeadingZeros.addLeadingZeros(month + 1, 2);
|
|
183
|
-
// 1st, 2nd, ..., 12th
|
|
184
|
-
case "Lo":
|
|
185
|
-
return localize.ordinalNumber(month + 1, { unit: "month" });
|
|
186
|
-
// Jan, Feb, ..., Dec
|
|
187
|
-
case "LLL":
|
|
188
|
-
return localize.month(month, {
|
|
189
|
-
width: "abbreviated",
|
|
190
|
-
context: "standalone"
|
|
191
|
-
});
|
|
192
|
-
// J, F, ..., D
|
|
193
|
-
case "LLLLL":
|
|
194
|
-
return localize.month(month, {
|
|
195
|
-
width: "narrow",
|
|
196
|
-
context: "standalone"
|
|
197
|
-
});
|
|
198
|
-
// January, February, ..., December
|
|
199
|
-
case "LLLL":
|
|
200
|
-
default:
|
|
201
|
-
return localize.month(month, { width: "wide", context: "standalone" });
|
|
202
|
-
}
|
|
203
|
-
},
|
|
204
|
-
// Local week of year
|
|
205
|
-
w: function(date, token, localize, options) {
|
|
206
|
-
const week = getWeek.getWeek(date, options);
|
|
207
|
-
if (token === "wo") {
|
|
208
|
-
return localize.ordinalNumber(week, { unit: "week" });
|
|
209
|
-
}
|
|
210
|
-
return addLeadingZeros.addLeadingZeros(week, token.length);
|
|
211
|
-
},
|
|
212
|
-
// ISO week of year
|
|
213
|
-
I: function(date, token, localize) {
|
|
214
|
-
const isoWeek = getISOWeek.getISOWeek(date);
|
|
215
|
-
if (token === "Io") {
|
|
216
|
-
return localize.ordinalNumber(isoWeek, { unit: "week" });
|
|
217
|
-
}
|
|
218
|
-
return addLeadingZeros.addLeadingZeros(isoWeek, token.length);
|
|
219
|
-
},
|
|
220
|
-
// Day of the month
|
|
221
|
-
d: function(date, token, localize) {
|
|
222
|
-
if (token === "do") {
|
|
223
|
-
return localize.ordinalNumber(date.getDate(), { unit: "date" });
|
|
224
|
-
}
|
|
225
|
-
return lightFormatters.lightFormatters.d(date, token);
|
|
226
|
-
},
|
|
227
|
-
// Day of year
|
|
228
|
-
D: function(date, token, localize) {
|
|
229
|
-
const dayOfYear = getDayOfYear.getDayOfYear(date);
|
|
230
|
-
if (token === "Do") {
|
|
231
|
-
return localize.ordinalNumber(dayOfYear, { unit: "dayOfYear" });
|
|
232
|
-
}
|
|
233
|
-
return addLeadingZeros.addLeadingZeros(dayOfYear, token.length);
|
|
234
|
-
},
|
|
235
|
-
// Day of week
|
|
236
|
-
E: function(date, token, localize) {
|
|
237
|
-
const dayOfWeek = date.getDay();
|
|
238
|
-
switch (token) {
|
|
239
|
-
// Tue
|
|
240
|
-
case "E":
|
|
241
|
-
case "EE":
|
|
242
|
-
case "EEE":
|
|
243
|
-
return localize.day(dayOfWeek, {
|
|
244
|
-
width: "abbreviated",
|
|
245
|
-
context: "formatting"
|
|
246
|
-
});
|
|
247
|
-
// T
|
|
248
|
-
case "EEEEE":
|
|
249
|
-
return localize.day(dayOfWeek, {
|
|
250
|
-
width: "narrow",
|
|
251
|
-
context: "formatting"
|
|
252
|
-
});
|
|
253
|
-
// Tu
|
|
254
|
-
case "EEEEEE":
|
|
255
|
-
return localize.day(dayOfWeek, {
|
|
256
|
-
width: "short",
|
|
257
|
-
context: "formatting"
|
|
258
|
-
});
|
|
259
|
-
// Tuesday
|
|
260
|
-
case "EEEE":
|
|
261
|
-
default:
|
|
262
|
-
return localize.day(dayOfWeek, {
|
|
263
|
-
width: "wide",
|
|
264
|
-
context: "formatting"
|
|
265
|
-
});
|
|
266
|
-
}
|
|
267
|
-
},
|
|
268
|
-
// Local day of week
|
|
269
|
-
e: function(date, token, localize, options) {
|
|
270
|
-
const dayOfWeek = date.getDay();
|
|
271
|
-
const localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
|
|
272
|
-
switch (token) {
|
|
273
|
-
// Numerical value (Nth day of week with current locale or weekStartsOn)
|
|
274
|
-
case "e":
|
|
275
|
-
return String(localDayOfWeek);
|
|
276
|
-
// Padded numerical value
|
|
277
|
-
case "ee":
|
|
278
|
-
return addLeadingZeros.addLeadingZeros(localDayOfWeek, 2);
|
|
279
|
-
// 1st, 2nd, ..., 7th
|
|
280
|
-
case "eo":
|
|
281
|
-
return localize.ordinalNumber(localDayOfWeek, { unit: "day" });
|
|
282
|
-
case "eee":
|
|
283
|
-
return localize.day(dayOfWeek, {
|
|
284
|
-
width: "abbreviated",
|
|
285
|
-
context: "formatting"
|
|
286
|
-
});
|
|
287
|
-
// T
|
|
288
|
-
case "eeeee":
|
|
289
|
-
return localize.day(dayOfWeek, {
|
|
290
|
-
width: "narrow",
|
|
291
|
-
context: "formatting"
|
|
292
|
-
});
|
|
293
|
-
// Tu
|
|
294
|
-
case "eeeeee":
|
|
295
|
-
return localize.day(dayOfWeek, {
|
|
296
|
-
width: "short",
|
|
297
|
-
context: "formatting"
|
|
298
|
-
});
|
|
299
|
-
// Tuesday
|
|
300
|
-
case "eeee":
|
|
301
|
-
default:
|
|
302
|
-
return localize.day(dayOfWeek, {
|
|
303
|
-
width: "wide",
|
|
304
|
-
context: "formatting"
|
|
305
|
-
});
|
|
306
|
-
}
|
|
307
|
-
},
|
|
308
|
-
// Stand-alone local day of week
|
|
309
|
-
c: function(date, token, localize, options) {
|
|
310
|
-
const dayOfWeek = date.getDay();
|
|
311
|
-
const localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
|
|
312
|
-
switch (token) {
|
|
313
|
-
// Numerical value (same as in `e`)
|
|
314
|
-
case "c":
|
|
315
|
-
return String(localDayOfWeek);
|
|
316
|
-
// Padded numerical value
|
|
317
|
-
case "cc":
|
|
318
|
-
return addLeadingZeros.addLeadingZeros(localDayOfWeek, token.length);
|
|
319
|
-
// 1st, 2nd, ..., 7th
|
|
320
|
-
case "co":
|
|
321
|
-
return localize.ordinalNumber(localDayOfWeek, { unit: "day" });
|
|
322
|
-
case "ccc":
|
|
323
|
-
return localize.day(dayOfWeek, {
|
|
324
|
-
width: "abbreviated",
|
|
325
|
-
context: "standalone"
|
|
326
|
-
});
|
|
327
|
-
// T
|
|
328
|
-
case "ccccc":
|
|
329
|
-
return localize.day(dayOfWeek, {
|
|
330
|
-
width: "narrow",
|
|
331
|
-
context: "standalone"
|
|
332
|
-
});
|
|
333
|
-
// Tu
|
|
334
|
-
case "cccccc":
|
|
335
|
-
return localize.day(dayOfWeek, {
|
|
336
|
-
width: "short",
|
|
337
|
-
context: "standalone"
|
|
338
|
-
});
|
|
339
|
-
// Tuesday
|
|
340
|
-
case "cccc":
|
|
341
|
-
default:
|
|
342
|
-
return localize.day(dayOfWeek, {
|
|
343
|
-
width: "wide",
|
|
344
|
-
context: "standalone"
|
|
345
|
-
});
|
|
346
|
-
}
|
|
347
|
-
},
|
|
348
|
-
// ISO day of week
|
|
349
|
-
i: function(date, token, localize) {
|
|
350
|
-
const dayOfWeek = date.getDay();
|
|
351
|
-
const isoDayOfWeek = dayOfWeek === 0 ? 7 : dayOfWeek;
|
|
352
|
-
switch (token) {
|
|
353
|
-
// 2
|
|
354
|
-
case "i":
|
|
355
|
-
return String(isoDayOfWeek);
|
|
356
|
-
// 02
|
|
357
|
-
case "ii":
|
|
358
|
-
return addLeadingZeros.addLeadingZeros(isoDayOfWeek, token.length);
|
|
359
|
-
// 2nd
|
|
360
|
-
case "io":
|
|
361
|
-
return localize.ordinalNumber(isoDayOfWeek, { unit: "day" });
|
|
362
|
-
// Tue
|
|
363
|
-
case "iii":
|
|
364
|
-
return localize.day(dayOfWeek, {
|
|
365
|
-
width: "abbreviated",
|
|
366
|
-
context: "formatting"
|
|
367
|
-
});
|
|
368
|
-
// T
|
|
369
|
-
case "iiiii":
|
|
370
|
-
return localize.day(dayOfWeek, {
|
|
371
|
-
width: "narrow",
|
|
372
|
-
context: "formatting"
|
|
373
|
-
});
|
|
374
|
-
// Tu
|
|
375
|
-
case "iiiiii":
|
|
376
|
-
return localize.day(dayOfWeek, {
|
|
377
|
-
width: "short",
|
|
378
|
-
context: "formatting"
|
|
379
|
-
});
|
|
380
|
-
// Tuesday
|
|
381
|
-
case "iiii":
|
|
382
|
-
default:
|
|
383
|
-
return localize.day(dayOfWeek, {
|
|
384
|
-
width: "wide",
|
|
385
|
-
context: "formatting"
|
|
386
|
-
});
|
|
387
|
-
}
|
|
388
|
-
},
|
|
389
|
-
// AM or PM
|
|
390
|
-
a: function(date, token, localize) {
|
|
391
|
-
const hours = date.getHours();
|
|
392
|
-
const dayPeriodEnumValue = hours / 12 >= 1 ? "pm" : "am";
|
|
393
|
-
switch (token) {
|
|
394
|
-
case "a":
|
|
395
|
-
case "aa":
|
|
396
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
397
|
-
width: "abbreviated",
|
|
398
|
-
context: "formatting"
|
|
399
|
-
});
|
|
400
|
-
case "aaa":
|
|
401
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
402
|
-
width: "abbreviated",
|
|
403
|
-
context: "formatting"
|
|
404
|
-
}).toLowerCase();
|
|
405
|
-
case "aaaaa":
|
|
406
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
407
|
-
width: "narrow",
|
|
408
|
-
context: "formatting"
|
|
409
|
-
});
|
|
410
|
-
case "aaaa":
|
|
411
|
-
default:
|
|
412
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
413
|
-
width: "wide",
|
|
414
|
-
context: "formatting"
|
|
415
|
-
});
|
|
416
|
-
}
|
|
417
|
-
},
|
|
418
|
-
// AM, PM, midnight, noon
|
|
419
|
-
b: function(date, token, localize) {
|
|
420
|
-
const hours = date.getHours();
|
|
421
|
-
let dayPeriodEnumValue;
|
|
422
|
-
if (hours === 12) {
|
|
423
|
-
dayPeriodEnumValue = dayPeriodEnum.noon;
|
|
424
|
-
} else if (hours === 0) {
|
|
425
|
-
dayPeriodEnumValue = dayPeriodEnum.midnight;
|
|
426
|
-
} else {
|
|
427
|
-
dayPeriodEnumValue = hours / 12 >= 1 ? "pm" : "am";
|
|
428
|
-
}
|
|
429
|
-
switch (token) {
|
|
430
|
-
case "b":
|
|
431
|
-
case "bb":
|
|
432
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
433
|
-
width: "abbreviated",
|
|
434
|
-
context: "formatting"
|
|
435
|
-
});
|
|
436
|
-
case "bbb":
|
|
437
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
438
|
-
width: "abbreviated",
|
|
439
|
-
context: "formatting"
|
|
440
|
-
}).toLowerCase();
|
|
441
|
-
case "bbbbb":
|
|
442
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
443
|
-
width: "narrow",
|
|
444
|
-
context: "formatting"
|
|
445
|
-
});
|
|
446
|
-
case "bbbb":
|
|
447
|
-
default:
|
|
448
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
449
|
-
width: "wide",
|
|
450
|
-
context: "formatting"
|
|
451
|
-
});
|
|
452
|
-
}
|
|
453
|
-
},
|
|
454
|
-
// in the morning, in the afternoon, in the evening, at night
|
|
455
|
-
B: function(date, token, localize) {
|
|
456
|
-
const hours = date.getHours();
|
|
457
|
-
let dayPeriodEnumValue;
|
|
458
|
-
if (hours >= 17) {
|
|
459
|
-
dayPeriodEnumValue = dayPeriodEnum.evening;
|
|
460
|
-
} else if (hours >= 12) {
|
|
461
|
-
dayPeriodEnumValue = dayPeriodEnum.afternoon;
|
|
462
|
-
} else if (hours >= 4) {
|
|
463
|
-
dayPeriodEnumValue = dayPeriodEnum.morning;
|
|
464
|
-
} else {
|
|
465
|
-
dayPeriodEnumValue = dayPeriodEnum.night;
|
|
466
|
-
}
|
|
467
|
-
switch (token) {
|
|
468
|
-
case "B":
|
|
469
|
-
case "BB":
|
|
470
|
-
case "BBB":
|
|
471
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
472
|
-
width: "abbreviated",
|
|
473
|
-
context: "formatting"
|
|
474
|
-
});
|
|
475
|
-
case "BBBBB":
|
|
476
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
477
|
-
width: "narrow",
|
|
478
|
-
context: "formatting"
|
|
479
|
-
});
|
|
480
|
-
case "BBBB":
|
|
481
|
-
default:
|
|
482
|
-
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
483
|
-
width: "wide",
|
|
484
|
-
context: "formatting"
|
|
485
|
-
});
|
|
486
|
-
}
|
|
487
|
-
},
|
|
488
|
-
// Hour [1-12]
|
|
489
|
-
h: function(date, token, localize) {
|
|
490
|
-
if (token === "ho") {
|
|
491
|
-
let hours = date.getHours() % 12;
|
|
492
|
-
if (hours === 0) hours = 12;
|
|
493
|
-
return localize.ordinalNumber(hours, { unit: "hour" });
|
|
494
|
-
}
|
|
495
|
-
return lightFormatters.lightFormatters.h(date, token);
|
|
496
|
-
},
|
|
497
|
-
// Hour [0-23]
|
|
498
|
-
H: function(date, token, localize) {
|
|
499
|
-
if (token === "Ho") {
|
|
500
|
-
return localize.ordinalNumber(date.getHours(), { unit: "hour" });
|
|
501
|
-
}
|
|
502
|
-
return lightFormatters.lightFormatters.H(date, token);
|
|
503
|
-
},
|
|
504
|
-
// Hour [0-11]
|
|
505
|
-
K: function(date, token, localize) {
|
|
506
|
-
const hours = date.getHours() % 12;
|
|
507
|
-
if (token === "Ko") {
|
|
508
|
-
return localize.ordinalNumber(hours, { unit: "hour" });
|
|
509
|
-
}
|
|
510
|
-
return addLeadingZeros.addLeadingZeros(hours, token.length);
|
|
511
|
-
},
|
|
512
|
-
// Hour [1-24]
|
|
513
|
-
k: function(date, token, localize) {
|
|
514
|
-
let hours = date.getHours();
|
|
515
|
-
if (hours === 0) hours = 24;
|
|
516
|
-
if (token === "ko") {
|
|
517
|
-
return localize.ordinalNumber(hours, { unit: "hour" });
|
|
518
|
-
}
|
|
519
|
-
return addLeadingZeros.addLeadingZeros(hours, token.length);
|
|
520
|
-
},
|
|
521
|
-
// Minute
|
|
522
|
-
m: function(date, token, localize) {
|
|
523
|
-
if (token === "mo") {
|
|
524
|
-
return localize.ordinalNumber(date.getMinutes(), { unit: "minute" });
|
|
525
|
-
}
|
|
526
|
-
return lightFormatters.lightFormatters.m(date, token);
|
|
527
|
-
},
|
|
528
|
-
// Second
|
|
529
|
-
s: function(date, token, localize) {
|
|
530
|
-
if (token === "so") {
|
|
531
|
-
return localize.ordinalNumber(date.getSeconds(), { unit: "second" });
|
|
532
|
-
}
|
|
533
|
-
return lightFormatters.lightFormatters.s(date, token);
|
|
534
|
-
},
|
|
535
|
-
// Fraction of second
|
|
536
|
-
S: function(date, token) {
|
|
537
|
-
return lightFormatters.lightFormatters.S(date, token);
|
|
538
|
-
},
|
|
539
|
-
// Timezone (ISO-8601. If offset is 0, output is always `'Z'`)
|
|
540
|
-
X: function(date, token, _localize) {
|
|
541
|
-
const timezoneOffset = date.getTimezoneOffset();
|
|
542
|
-
if (timezoneOffset === 0) {
|
|
543
|
-
return "Z";
|
|
544
|
-
}
|
|
545
|
-
switch (token) {
|
|
546
|
-
// Hours and optional minutes
|
|
547
|
-
case "X":
|
|
548
|
-
return formatTimezoneWithOptionalMinutes(timezoneOffset);
|
|
549
|
-
// Hours, minutes and optional seconds without `:` delimiter
|
|
550
|
-
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
551
|
-
// so this token always has the same output as `XX`
|
|
552
|
-
case "XXXX":
|
|
553
|
-
case "XX":
|
|
554
|
-
return formatTimezone(timezoneOffset);
|
|
555
|
-
// Hours, minutes and optional seconds with `:` delimiter
|
|
556
|
-
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
557
|
-
// so this token always has the same output as `XXX`
|
|
558
|
-
case "XXXXX":
|
|
559
|
-
case "XXX":
|
|
560
|
-
// Hours and minutes with `:` delimiter
|
|
561
|
-
default:
|
|
562
|
-
return formatTimezone(timezoneOffset, ":");
|
|
563
|
-
}
|
|
564
|
-
},
|
|
565
|
-
// Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)
|
|
566
|
-
x: function(date, token, _localize) {
|
|
567
|
-
const timezoneOffset = date.getTimezoneOffset();
|
|
568
|
-
switch (token) {
|
|
569
|
-
// Hours and optional minutes
|
|
570
|
-
case "x":
|
|
571
|
-
return formatTimezoneWithOptionalMinutes(timezoneOffset);
|
|
572
|
-
// Hours, minutes and optional seconds without `:` delimiter
|
|
573
|
-
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
574
|
-
// so this token always has the same output as `xx`
|
|
575
|
-
case "xxxx":
|
|
576
|
-
case "xx":
|
|
577
|
-
return formatTimezone(timezoneOffset);
|
|
578
|
-
// Hours, minutes and optional seconds with `:` delimiter
|
|
579
|
-
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
580
|
-
// so this token always has the same output as `xxx`
|
|
581
|
-
case "xxxxx":
|
|
582
|
-
case "xxx":
|
|
583
|
-
// Hours and minutes with `:` delimiter
|
|
584
|
-
default:
|
|
585
|
-
return formatTimezone(timezoneOffset, ":");
|
|
586
|
-
}
|
|
587
|
-
},
|
|
588
|
-
// Timezone (GMT)
|
|
589
|
-
O: function(date, token, _localize) {
|
|
590
|
-
const timezoneOffset = date.getTimezoneOffset();
|
|
591
|
-
switch (token) {
|
|
592
|
-
// Short
|
|
593
|
-
case "O":
|
|
594
|
-
case "OO":
|
|
595
|
-
case "OOO":
|
|
596
|
-
return "GMT" + formatTimezoneShort(timezoneOffset, ":");
|
|
597
|
-
// Long
|
|
598
|
-
case "OOOO":
|
|
599
|
-
default:
|
|
600
|
-
return "GMT" + formatTimezone(timezoneOffset, ":");
|
|
601
|
-
}
|
|
602
|
-
},
|
|
603
|
-
// Timezone (specific non-location)
|
|
604
|
-
z: function(date, token, _localize) {
|
|
605
|
-
const timezoneOffset = date.getTimezoneOffset();
|
|
606
|
-
switch (token) {
|
|
607
|
-
// Short
|
|
608
|
-
case "z":
|
|
609
|
-
case "zz":
|
|
610
|
-
case "zzz":
|
|
611
|
-
return "GMT" + formatTimezoneShort(timezoneOffset, ":");
|
|
612
|
-
// Long
|
|
613
|
-
case "zzzz":
|
|
614
|
-
default:
|
|
615
|
-
return "GMT" + formatTimezone(timezoneOffset, ":");
|
|
616
|
-
}
|
|
617
|
-
},
|
|
618
|
-
// Seconds timestamp
|
|
619
|
-
t: function(date, token, _localize) {
|
|
620
|
-
const timestamp = Math.trunc(+date / 1e3);
|
|
621
|
-
return addLeadingZeros.addLeadingZeros(timestamp, token.length);
|
|
622
|
-
},
|
|
623
|
-
// Milliseconds timestamp
|
|
624
|
-
T: function(date, token, _localize) {
|
|
625
|
-
return addLeadingZeros.addLeadingZeros(+date, token.length);
|
|
626
|
-
}
|
|
627
|
-
};
|
|
628
|
-
function formatTimezoneShort(offset, delimiter = "") {
|
|
629
|
-
const sign = offset > 0 ? "-" : "+";
|
|
630
|
-
const absOffset = Math.abs(offset);
|
|
631
|
-
const hours = Math.trunc(absOffset / 60);
|
|
632
|
-
const minutes = absOffset % 60;
|
|
633
|
-
if (minutes === 0) {
|
|
634
|
-
return sign + String(hours);
|
|
635
|
-
}
|
|
636
|
-
return sign + String(hours) + delimiter + addLeadingZeros.addLeadingZeros(minutes, 2);
|
|
637
|
-
}
|
|
638
|
-
function formatTimezoneWithOptionalMinutes(offset, delimiter) {
|
|
639
|
-
if (offset % 60 === 0) {
|
|
640
|
-
const sign = offset > 0 ? "-" : "+";
|
|
641
|
-
return sign + addLeadingZeros.addLeadingZeros(Math.abs(offset) / 60, 2);
|
|
642
|
-
}
|
|
643
|
-
return formatTimezone(offset, delimiter);
|
|
644
|
-
}
|
|
645
|
-
function formatTimezone(offset, delimiter = "") {
|
|
646
|
-
const sign = offset > 0 ? "-" : "+";
|
|
647
|
-
const absOffset = Math.abs(offset);
|
|
648
|
-
const hours = addLeadingZeros.addLeadingZeros(Math.trunc(absOffset / 60), 2);
|
|
649
|
-
const minutes = addLeadingZeros.addLeadingZeros(absOffset % 60, 2);
|
|
650
|
-
return sign + hours + delimiter + minutes;
|
|
651
|
-
}
|
|
652
|
-
exports.formatters = formatters;
|
|
653
|
-
//# sourceMappingURL=formatters.cjs.map
|