{"version":3,"sources":["webpack:///./src/views/NotificationsIndex.vue?3c9f","webpack:///./src/components/NotificationProfile.vue?72da","webpack:///./src/components/NotificationProfile.vue","webpack:///./src/components/NotificationProfile.vue?b39f","webpack:///./src/components/NotificationProfile.vue?f9b9","webpack:///./src/views/NotificationsIndex.vue","webpack:///./src/views/NotificationsIndex.vue?1829","webpack:///./src/views/NotificationsIndex.vue?b010","webpack:///./src/components/NotificationsSettings.vue?deca","webpack:///./src/components/NotificationSettingDetail.vue?bbce","webpack:///./src/components/NotificationSettingDetail.vue","webpack:///./src/components/NotificationSettingDetail.vue?916a","webpack:///./src/components/NotificationSettingDetail.vue?7aa6","webpack:///./src/components/NotificationsSettings.vue","webpack:///./src/components/NotificationsSettings.vue?8390","webpack:///./src/components/NotificationsSettings.vue?50e6","webpack:///./src/components/NotificationsSettings.vue?a9f9"],"names":["render","_vm","this","_h","$createElement","_c","_self","ref","attrs","toolbar","notificationsPaginating","scopedSlots","_u","key","fn","staticClass","notifications","length","$refs","notificationsList","_e","filter","on","onFilterSelected","tools","proxy","selectedNotification","notificationsPlaceholder","notificationsTile","staticRenderFns","notification","data","title","_f","created_at","read_at","text","$event","button","callback","_v","_s","Vue","extend","components","PersonShowTitle","mixins","mixin","props","type","Object","required","mounted","notificationButton","methods","action","params","exec","includes","window","open","$store","getters","isApp","csvhelper","importShowReport","actionText","getProps","downloadCsv","displayButton","isMobile","watch","component","VBtn","VCol","VRow","FilterButton","NotificationProfile","selected","display","value","options","img","content","left","icon","back","tooltip","permission","right","beforeDestroy","commit","page","dispatch","settings","$route","query","popNotificationSettings","id","find","x","computed","mapGetters","list","iList","notificationsParams","get","set","val","notificationsSelectedNotification","unread","notificationsUnreadCount","color","$colors","mdPurple","dark","hidden","multiSelected","outlined","small","dismissMultiple","resetMultiple","deleteMultiple","disabled","$vuetify","breakpoint","xsOnly","dismissAll","l","result","ids","map","multiSelectReset","n","isDeleted","deleteNotification","dismissNotification","Date","toUTCString","notificationActions","listAction","IListActionType","menu","resetNotification","actionContent","leftIcon","notificationIcon","line1","line2","onNotificationSelected","override","isSame","isNew","width","closeable","closeOnSubmit","paginateNotifications","nextPage","shouldPaginate","notificationsLastPage","readAt","scrollPositionLeft","position","bottom","VSpacer","staticStyle","class","switchMessage","model","messageSetting","$$v","$set","expression","switchGeneral","generalSetting","loading","showMore","emailNotifications","toggleNotification","pushNotifications","browserNotifications","submit","smAndDown","toProperCase","_l","module","i","category","item","j","onChange","name","expand","Array","String","$emit","VSwitch","LoadingMask","NotificationSettingDetailComponent","generalNotification","email","push","browser","messageNotification","totalNotifications","currentMembership","email_notifications","messages","enabled","push_notifications","browser_notifications","checkNotificationPromise","Notification","requestPermission","then","e","goToBrowserNotifications","s","bool","toggleAllNotifications","selector","keys","payload","response","message","forEach","idx","items","nIdx","notifs","obj","filtered","total","y","VCard","VCardText","VCardTitle"],"mappings":"8HAAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,gBAAgB,CAACE,IAAI,oBAAoBC,MAAM,CAAC,QAAU,GAAG,QAAUP,EAAIQ,QAAQ,OAASR,EAAIS,yBAAyBC,YAAYV,EAAIW,GAAG,CAAC,CAACC,IAAI,WAAWC,GAAG,WAAW,MAAO,CAACT,EAAG,QAAQ,CAACU,YAAY,YAAYP,MAAM,CAAC,aAAa,GAAG,QAAU,MAAM,MAAQ,WAAW,CAAEP,EAAW,QAAEI,EAAG,sBAAsB,CAACG,MAAM,CAAC,OAAsC,IAA7BP,EAAIe,cAAcC,OAAa,OAAShB,EAAIiB,MAAMC,qBAAqBlB,EAAImB,KAAKf,EAAG,gBAAgB,CAACU,YAAY,OAAOP,MAAM,CAAC,OAASP,EAAIoB,QAAQC,GAAG,CAAC,cAAgBrB,EAAIsB,oBAAoBlB,EAAG,YAAYA,EAAG,kBAAkB,CAACG,MAAM,CAAC,QAAUP,EAAIuB,MAAM,QAAU,UA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;return _c('page-template',{ref:\"notificationsPage\",attrs:{\"divider\":\"\",\"toolbar\":_vm.toolbar,\"loader\":_vm.notificationsPaginating},scopedSlots:_vm._u([{key:\"left-top\",fn:function(){return [_c('v-row',{staticClass:\"py-3 pr-3\",attrs:{\"no-gutters\":\"\",\"justify\":\"end\",\"align\":\"center\"}},[(_vm.mounted)?_c('i-list-multi-select',{attrs:{\"hidden\":_vm.notifications.length === 0,\"target\":_vm.$refs.notificationsList}}):_vm._e(),_c('filter-button',{staticClass:\"ml-4\",attrs:{\"filter\":_vm.filter},on:{\"filterChanged\":_vm.onFilterSelected}}),_c('v-spacer'),_c('tri-panel-tools',{attrs:{\"buttons\":_vm.tools,\"justify\":\"end\"}})],1)]},proxy:true},(_vm.selectedNotification)?{key:\"content\",fn:function(){return [_c('notification-profile',{attrs:{\"notification\":_vm.selectedNotification}})]},proxy:true}:null],null,true)},[_c('i-list',{ref:\"notificationsList\",attrs:{\"id\":\"notificationsList\",\"selectable\":\"\",\"items\":_vm.notifications,\"placeholder\":_vm.notificationsPlaceholder,\"selected\":_vm.selectedNotification,\"tile\":_vm.notificationsTile()}})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('v-col',[_c('person-show-title',{attrs:{\"icon\":\"mdi-bell\",\"title\":\"Notification\"}}),_c('person-show-item',{attrs:{\"full-width\":\"\",\"display\":\"Title:\",\"value\":_vm.notification.data.title}}),_c('person-show-item',{attrs:{\"full-width\":\"\",\"display\":\"Created:\",\"value\":_vm._f(\"dateTime\")(_vm.notification.created_at)}}),(_vm.notification.read_at)?_c('person-show-item',{attrs:{\"full-width\":\"\",\"display\":\"Read At:\",\"value\":_vm._f(\"dateTime\")(_vm.notification.read_at)}}):_vm._e(),_c('person-show-item',{attrs:{\"textarea\":\"\",\"full-width\":\"\",\"noWrap\":\"\",\"display\":\"Message:\",\"value\":_vm.notification.data.text}}),(_vm.button)?_c('v-row',{staticClass:\"pa-3\",attrs:{\"no-gutters\":\"\",\"justify\":\"center\"}},[_c('v-btn',{attrs:{\"color\":\"primary\"},on:{\"click\":function($event){return _vm.button.callback()}}},[_vm._v(\" \"+_vm._s(_vm.button.text)+\" \")])],1):_vm._e()],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport Vue, { PropType } from 'vue'\nimport mixin from '../mixins/notifications-mixin'\nimport Notification from '@/types/Notification.interface'\nimport PersonShowTitle from '@/components/PersonShowTitle.vue'\nimport csvhelper from '@/plugins/csvhelper'\n\nexport default Vue.extend({\n components: { PersonShowTitle },\n mixins: [mixin],\n props: {\n notification: {\n type: Object as PropType,\n required: true\n }\n },\n data() {\n return {\n button: null\n }\n },\n mounted() {\n // Set the notification button\n this.button = this.notificationButton(this.notification)\n },\n methods: {\n action(): void {\n // Grab the action from our selected notification\n const action = this.notification.data.action\n\n // If no action, do nothing\n if (!action) return\n\n // Else, grab the params and exec\n const params = action.params\n const exec = action.exec\n\n // If this params is a string and contains http, execute the link\n if (typeof params === 'string' && params.includes('http')) {\n window.open(params, this.$store.getters.isApp ? '_system' : '_blank')\n }\n\n // Else, if the exec is for our csv report then open it\n else if (exec === 'importShowReport') {\n csvhelper.importShowReport(params)\n }\n },\n actionText(): string {\n // If we don't have a selected notification then return null\n if (!this.notification) return null\n\n // Get our exec from the notification\n const exec = window.getProps(\n this.notification,\n ['data', 'action', 'exec'],\n ''\n )\n\n // Return the text\n return (\n {\n downloadCsv: 'Download CSV',\n importShowReport: 'Download Full Import Report'\n }[exec] || 'Action'\n )\n },\n displayButton(): boolean {\n // If we are on mobile, don't show\n if (this.$store.getters.isMobile()) return false\n\n // If we are on iOS, don't show\n if (this.$store.getters.isApp) return false\n\n // If the actiontext does not match, don't show\n if (\n this.actionText !== 'Download CSV' &&\n this.actionText !== 'Download Full Import Report'\n )\n return false\n\n // Else, return true\n return true\n }\n },\n watch: {\n notification() {\n // Update the notification button\n this.button = this.notificationButton(this.notification)\n }\n }\n})\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationProfile.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationProfile.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./NotificationProfile.vue?vue&type=template&id=444cd8de&\"\nimport script from \"./NotificationProfile.vue?vue&type=script&lang=ts&\"\nexport * from \"./NotificationProfile.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCol } from 'vuetify/lib/components/VGrid';\nimport { VRow } from 'vuetify/lib/components/VGrid';\ninstallComponents(component, {VBtn,VCol,VRow})\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n// Libraries\nimport Vue from 'vue'\nimport { mapGetters } from 'vuex'\nimport mixin from '@/mixins/notifications-mixin'\nimport moment from 'moment'\n\n// Types\nimport Notification from '@/types/Notification.interface'\nimport { NotificationParams } from '@/types/PaginationParams.interface'\nimport { NotificationFilterParams } from '@/types/FilterParams.interface'\nimport Button from '@/types/components/Button.interface'\nimport IList from '@/types/components/IList.interface'\nimport ScrollPosition from '@/types/components/ScrollPosition.interface'\nimport IListTile from '@/types/components/IListTile.interface'\nimport IListAction, { IListActionType } from '@/types/components/IListAction.interface'\nimport IListIcon from '@/types/components/IListIcon.interface'\n\n// Components\nimport FilterButton from '@/components/FilterButton.vue'\nimport NotificationProfile from '@/components/NotificationProfile.vue'\n\nexport default Vue.extend({\n components: { FilterButton, NotificationProfile },\n mixins: [mixin],\n data() {\n return {\n // The notifications list filter button\n filter: {\n selected: {\n display: 'All',\n key: 'type',\n value: 'all'\n },\n options: [\n {\n display: 'All',\n key: 'type',\n value: 'all'\n },\n {\n display: 'Messages',\n key: 'type',\n value: 'message'\n },\n {\n display: 'Notifications',\n key: 'type',\n value: 'general'\n },\n {\n display: 'Mentions',\n key: 'type',\n value: 'mention'\n }\n ]\n },\n // Determines if we are ready to use the component\n mounted: false,\n // Placeholder for our lists\n notificationsPlaceholder: {\n img: 'noNotifications',\n content: 'No Notifications to Display'\n },\n toolbar: {\n title: 'Notifications',\n left: [\n {\n title: 'Back',\n icon: 'mdi-chevron-left',\n back: '/settings',\n tooltip: 'Back',\n permission: 0\n }\n ],\n right: []\n }\n }\n },\n beforeDestroy() {\n // Unset any filters and return to the original state\n this.$store.commit('notificationsParamsSet', { page: 1, type: 'all' })\n\n // Re-paginate\n this.$store.dispatch('notificationsPaginate')\n },\n async mounted() {\n // Grab our settings query\n const settings = this.$route.query.settings\n\n // If settings is set then open our notification settings popup\n if (settings) this.popNotificationSettings()\n\n // Grab our id\n const id = this.$route.query.id\n\n // If there is an id attached, find the selected notification\n if (id) this.$store.dispatch('notificationsSelectedNotificationGet', id)\n\n // Check if we have a type query param\n const type = this.$route.query.type\n\n // If we do, then lets change to that type\n if (type) {\n // Find our filter matching this type\n const filter = this.filter.options.find((x) => x.value === type)\n\n // Set our filter selected\n this.filter.selected = filter\n\n // Change our filter\n this.onFilterSelected(filter)\n }\n\n // We finished everything so we are now mounted\n this.mounted = true\n },\n computed: {\n ...mapGetters([\n 'notifications',\n 'notificationsPaginating',\n 'notificationsLastPage',\n 'scrollPositionLeft'\n ]),\n // The notifications IList (used for multi-select)\n list(): IList {\n return this.$store.getters.iList('notificationsList')\n },\n // The pagination params currently loaded\n notificationsParams: {\n get() {\n return this.$store.getters.notificationsParams\n },\n set(val: NotificationParams) {\n this.$store.commit('notificationsParamsSet', val)\n }\n },\n // The currrently selected notification\n selectedNotification: {\n get(): Notification {\n return this.$store.getters.notificationsSelectedNotification\n },\n set(val: Notification): void {\n this.$store.commit('notificationsSelectedNotificationSet', val)\n }\n },\n // The buttons displayed in the upper right\n tools(): Button[] {\n // Count unread notifications\n const unread = this.$store.getters.notificationsUnreadCount\n\n return [\n {\n text: 'Mark Selected Read',\n color: this.$colors.mdPurple,\n dark: true,\n hidden: !this.list || this.list.multiSelected.length === 0,\n icon: 'bi-bookmark-check',\n outlined: true,\n small: true,\n callback: () => this.dismissMultiple()\n },\n {\n text: 'Mark Selected Unread',\n color: this.$colors.mdPurple,\n dark: true,\n hidden: !this.list || this.list.multiSelected.length === 0,\n icon: 'bi-bookmark-dash',\n outlined: true,\n small: true,\n callback: () => this.resetMultiple()\n },\n {\n text: 'Delete Selected',\n color: this.$colors.mdPurple,\n dark: true,\n hidden: !this.list || this.list.multiSelected.length === 0,\n icon: 'bi-trash',\n outlined: true,\n small: true,\n callback: () => this.deleteMultiple()\n },\n {\n text: 'Mark All As Read',\n color: this.$colors.mdPurple,\n dark: true,\n disabled: unread === 0,\n icon: this.$vuetify.breakpoint.xsOnly ? 'bi-card-checklist' : '',\n hidden: unread === 0 || this.list?.multiSelected.length > 0,\n outlined: true,\n small: true,\n callback: () => this.dismissAll()\n },\n {\n text: 'Notification Settings',\n color: this.$colors.mdPurple,\n dark: true,\n icon: this.$vuetify.breakpoint.xsOnly ? 'bi-gear-wide-connected' : '',\n hidden: this.list?.multiSelected.length > 0,\n small: true,\n callback: () => this.popNotificationSettings()\n }\n ]\n }\n },\n methods: {\n // Soft delete multiple notifications (used with multi-select)\n deleteMultiple(): void {\n // Grab our multi-selected notifications\n const notifications = this.list.multiSelected\n\n // Get the length of the multiselected list\n const l = notifications.length\n\n // If the length is zero, do nothing\n if (l === 0) return\n\n // Else, pop a confirm dialog\n this.$store.dispatch('dialogOpen', {\n type: 'CONFIRM',\n title: 'Confirm Delete',\n text: `Are you sure you want to delete (${l}) notifications?`,\n icon: 'mdi-alert-circle',\n callback: async (result: boolean): Promise => {\n // If the user answered 'NO', do nothing\n if (!result) return\n\n // Else, create an array of ids that will be deleted\n const ids = notifications.map((x) => x.id)\n\n // Deselect everything\n this.$refs.notificationsList.multiSelectReset()\n\n // Remove notification from our list (for instance ui response)\n this.$store.commit('notificationsRemove', ids)\n\n // Get the selected notification\n const n = this.selectedNotification\n\n // Check if the selected notification was deleted\n const isDeleted = n && ids.includes(n.id)\n\n // If the selected notification was deleted, remove it\n if (isDeleted) this.selectedNotification = null\n\n // Send our changes to the server\n await this.$store.dispatch('notificationsDelete', ids)\n\n // If all notifications were deleted...\n if (this.notifications.length === 0) {\n // Repaginate the list (we use onFilterSelected to preserve the currently selected filter)\n this.onFilterSelected(this.filter.selected, true)\n }\n }\n })\n },\n // Soft delete a single notification\n deleteNotification(notification: Notification): void {\n // Pop a confirm dialog\n this.$store.dispatch('dialogOpen', {\n type: 'CONFIRM',\n title: 'Confirm Delete',\n text: 'Are you sure you want to delete this notification?',\n icon: 'mdi-alert-circle',\n callback: (result: boolean): void => {\n // If the dialog result is false (ie NO), do nothing\n if (!result) return\n\n // Else, assemble our request payload\n const ids = [notification.id]\n\n // Send the request to the API\n this.$store.dispatch('notificationsDelete', ids)\n\n // Remove notification from our list (for instance ui response)\n this.$store.commit('notificationsRemove', ids)\n\n // Get the selected notification\n const n = this.selectedNotification\n\n // Check if the selected notification was deleted\n const isDeleted = n && n.id === notification.id\n\n // If the selected Notification was deleted, set null\n if (isDeleted) this.selectedNotification = null\n }\n })\n },\n // Dismiss all unread notifications\n dismissAll(): void {\n // Get confirmation from the user before dismissing all\n this.$store.dispatch('dialogOpen', {\n type: 'CONFIRM',\n title: 'Mark All As Read?',\n text: 'Are you sure you want to mark all your notifications as read?',\n icon: 'mdi-alert-circle',\n callback: (result: boolean) => {\n // If the user answered 'NO' in the dialog, do nothing\n if (!result) return\n\n // Else, dismiss the notifications (for instant ui response)\n for (const n of this.notifications) n.read_at = true\n\n // Send the request to the API\n this.$store.dispatch('notificationsDismissAll')\n\n // Deselect everything\n this.$refs.notificationsList.multiSelectReset()\n }\n })\n },\n // Dismiss multiple notifications (used with multi-select)\n dismissMultiple(): void {\n // Grab our multi-selected notifications\n const notifications = this.list.multiSelected\n\n // Get only unread notifications (sometimes people select notifications that have already been read)\n const unread = notifications.filter((x) => !x.read_at)\n\n // If unread notifications do NOT exist, no need to send an API request, just reset multiselect\n if (unread.length === 0)\n return this.$refs.notificationsList.multiSelectReset()\n\n // Else, update the notifications (for instant UI responsiveness)\n for (const n of unread) n.read_at = true\n\n // Create and array of ids that will be dismisses\n const ids = unread.map((x) => x.id)\n\n // Send our payload\n this.$store.dispatch('notificationsDismiss', ids)\n\n // Deselect everything\n this.$refs.notificationsList.multiSelectReset()\n },\n // Dismiss a single notification\n dismissNotification(notification: Notification): void {\n // Check if the notification is unread\n const unread = !notification.read_at\n\n // If the notification is unread, dismiss it\n if (unread) {\n // Set the notification read (for instant UI responsiveness)\n notification.read_at = new Date().toUTCString()\n\n // Send changes to the server\n this.$store.dispatch('notificationsDismiss', [notification.id])\n }\n },\n // Define the buttons shown on the right side of the IList tile\n notificationActions(notification: Notification): IListAction {\n // Create our IListAction\n const listAction: IListAction = {\n type: IListActionType.menu,\n menu: [\n {\n text: 'Mark as Read',\n icon: 'bi-bookmark-check',\n color: this.$colors.mdPurple,\n hidden: notification.read_at != null,\n callback: () => this.dismissNotification(notification)\n },\n {\n text: 'Mark Unread',\n icon: 'bi-bookmark-dash',\n color: this.$colors.mdPurple,\n hidden: notification.read_at == null,\n callback: () => this.resetNotification(notification)\n },\n {\n text: 'Delete',\n icon: 'bi-trash',\n color: this.$colors.mdPurple,\n callback: () => this.deleteNotification(notification)\n }\n ]\n }\n\n // Return our action\n return listAction\n },\n // Define the notification IList tile\n notificationsTile(): IListTile {\n return {\n actionContent: (n: Notification): IListAction =>\n this.notificationActions(n),\n leftIcon: (n: Notification): IListIcon => this.notificationIcon(n),\n line1: (n: Notification): string => n.data.title,\n line2: (n: Notification): string => n.data.text,\n callback: (n: Notification) => this.onNotificationSelected(n)\n }\n },\n // Handle the filter selected event (override = true will force pagination)\n onFilterSelected(filter: NotificationFilterParams, override: boolean): void {\n // Grab the key and value from our filter\n const key = filter.key\n const value = filter.value\n\n // Get our current params\n const params = this.notificationsParams\n\n // Check if we currently have this filter applied\n const isSame = params[key] === value\n\n // If the filter is the same (AND NOT override), don't do anything\n if (isSame && !override) return\n\n // Else, apply this to our params\n params[key] = value\n\n // Also set page to 1 since we changed filter\n params.page = 1\n\n // Update pagination params (our computed setter will apply this in the store)\n this.notificationsParams = params\n\n // Deselect multiselected items\n this.$refs.notificationsList.multiSelectReset()\n\n // Deselect selected notification\n this.selectedNotification = null\n\n // The filter was changed so we should paginate the new filter\n this.$store.dispatch('notificationsPaginate')\n },\n // Handle the notification selected event\n onNotificationSelected(notification: Notification): void {\n // Get our current selected notification\n const selected = this.selectedNotification\n\n // Check if the notification is different from the currently selected notification\n const isNew = !selected || selected.id != notification.id\n\n // If it is NOT new then do nothing\n if (!isNew) return\n\n // Check if the notification is unread\n const unread = !notification.read_at\n\n // If the notification is unread, dismiss it (since the user is viewing the notification we automatically dismiss it)\n if (unread) this.dismissNotification(notification)\n\n // Set the selected notification\n this.selectedNotification = notification\n },\n // Pop the user notifications settings dialog\n popNotificationSettings(): void {\n this.$store.dispatch('dialogOpen', {\n type: 'APP',\n component: 'notifications-settings',\n width: '775px',\n closeable: true,\n closeOnSubmit: true\n })\n },\n // Paginate notification using the current pagination params\n paginateNotifications(): void {\n // Get current pagination params\n const params = this.notificationsParams\n\n // Determine the next page\n const nextPage = params.page + 1\n\n // Determine is the page exists, or we're already at the end of pagination\n const shouldPaginate = nextPage <= this.notificationsLastPage\n\n // If we should NOT paginate, do nothing\n if (!shouldPaginate) return\n\n // Else, update pagination params\n params.page = nextPage\n this.$store.commit('notificationsParamsSet', params)\n\n // Paginate the next page\n this.$store.dispatch('notificationsPaginate')\n },\n // Mark a single notification as 'Unread' (ie reset the notification)\n resetNotification(notification: Notification) {\n // Set the notification to unread (for instant UI responsiveness)\n notification.read_at = null\n\n // Send changes to the server\n this.$store.dispatch('notificationsReset', [notification.id])\n },\n // Mark selected notifications as 'Unread' (ie reset the notifications)\n resetMultiple() {\n // Grab our multi-selected notifications\n const notifications = this.list.multiSelected\n\n // Get only read notifications (sometimes people select notifications that are already unread)\n const readAt = notifications.filter((x) => x.read_at)\n\n // If readAt notifications do NOT exist, no need to send an API request, just reset multiselect\n if (readAt.length === 0)\n return this.$refs.notificationsList.multiSelectReset()\n\n // Else, reset the notifications\n for (const n of readAt) n.read_at = null\n\n // Commit changes to store (for instant UI responsiveness)\n this.$store.commit('notificationsPush', readAt)\n\n // Create and array of ids that will be dismisses\n const ids = readAt.map((x) => x.id)\n\n // Send our payload\n this.$store.dispatch('notificationsReset', ids)\n\n // Deselect everything\n this.$refs.notificationsList.multiSelectReset()\n }\n },\n watch: {\n scrollPositionLeft(position: ScrollPosition): void {\n if (!this.notificationsPaginating && position.bottom)\n this.paginateNotifications()\n }\n }\n})\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationsIndex.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationsIndex.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./NotificationsIndex.vue?vue&type=template&id=1adcd788&\"\nimport script from \"./NotificationsIndex.vue?vue&type=script&lang=ts&\"\nexport * from \"./NotificationsIndex.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VRow } from 'vuetify/lib/components/VGrid';\nimport { VSpacer } from 'vuetify/lib/components/VGrid';\ninstallComponents(component, {VRow,VSpacer})\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('v-card',{attrs:{\"flat\":\"\",\"width\":\"775px\"}},[_c('v-card-title',{staticClass:\"d-flex justify-center mt-8\",staticStyle:{\"text-decoration\":\"underline\",\"text-align\":\"center\",\"font-weight\":\"800\",\"font-size\":\"36px\"}},[_vm._v(\" Notification Settings \")]),_c('v-card-text',[_c('v-row',{class:_vm.$vuetify.breakpoint.xsOnly ? 'flex-column' : 'flex-row',attrs:{\"no-gutters\":\"\"}},[_c('v-col',{staticClass:\"pa-6\",attrs:{\"cols\":_vm.$vuetify.breakpoint.xsOnly ? 12 : 6}},[_c('v-row',{staticClass:\"flex-column\",attrs:{\"no-gutters\":\"\"}},[_c('v-col',{staticClass:\"headline font-weight-black\",staticStyle:{\"color\":\"#4D4D4D\"}},[_vm._v(\" New Message Notifications \")]),_c('v-col',{staticClass:\"font-weight-regular subtitle-2\",staticStyle:{\"line-height\":\"22px\"}},[_vm._v(\" How would you like to get notified about new messages? \")]),(_vm.messageSetting)?_c('v-col',[_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchMessage($event, 'email')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Email \")])]},proxy:true}],null,false,2332456883),model:{value:(_vm.messageSetting.email),callback:function ($$v) {_vm.$set(_vm.messageSetting, \"email\", $$v)},expression:\"messageSetting.email\"}}),_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchMessage($event, 'push')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Push Notification \")])]},proxy:true}],null,false,276437676),model:{value:(_vm.messageSetting.push),callback:function ($$v) {_vm.$set(_vm.messageSetting, \"push\", $$v)},expression:\"messageSetting.push\"}}),_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchMessage($event, 'browser')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Browser \")])]},proxy:true}],null,false,1126754995),model:{value:(_vm.messageSetting.browser),callback:function ($$v) {_vm.$set(_vm.messageSetting, \"browser\", $$v)},expression:\"messageSetting.browser\"}})],1):_c('loading-mask')],1)],1),_c('v-col',{staticClass:\"pa-6\",attrs:{\"cols\":_vm.$vuetify.breakpoint.xsOnly ? 12 : 6}},[_c('v-row',{staticClass:\"flex-column\",attrs:{\"no-gutters\":\"\"}},[_c('v-col',{staticClass:\"headline font-weight-black\",staticStyle:{\"color\":\"#4D4D4D\"}},[_vm._v(\" General Notifications \")]),_c('v-col',{staticClass:\"font-weight-regular subtitle-2\",staticStyle:{\"line-height\":\"22px\"}},[_vm._v(\" Manage general notification settings for all non-message notifications like \\\"Sync complete, CSV upload successful, Form Submitted, User Activated\\\". NOTE some notifications will always be sent like password reset and user invite. \")]),(_vm.generalSetting)?_c('v-col',[_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchGeneral($event, 'email')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Email \")])]},proxy:true}],null,false,2332456883),model:{value:(_vm.generalSetting.email),callback:function ($$v) {_vm.$set(_vm.generalSetting, \"email\", $$v)},expression:\"generalSetting.email\"}}),_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchGeneral($event, 'push')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Push Notification \")])]},proxy:true}],null,false,276437676),model:{value:(_vm.generalSetting.push),callback:function ($$v) {_vm.$set(_vm.generalSetting, \"push\", $$v)},expression:\"generalSetting.push\"}}),_c('v-switch',{attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.switchGeneral($event, 'browser')}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-label\"},[_vm._v(\" Browser \")])]},proxy:true}],null,false,1126754995),model:{value:(_vm.generalSetting.browser),callback:function ($$v) {_vm.$set(_vm.generalSetting, \"browser\", $$v)},expression:\"generalSetting.browser\"}})],1):_c('loading-mask')],1)],1),_c('v-col',{staticClass:\"d-flex flex-column justify-center align-center mb-6\",attrs:{\"cols\":\"12\"}},[_c('v-btn',{staticClass:\"caption\",staticStyle:{\"border-radius\":\"8px\"},attrs:{\"depressed\":\"\",\"text\":\"\",\"color\":\"primary\",\"loading\":_vm.loading,\"disabled\":_vm.loading},on:{\"click\":function($event){_vm.showMore = !_vm.showMore}}},[_vm._v(\" \"+_vm._s(_vm.showMore ? 'Less Details' : 'More Details')+\" \")])],1),(_vm.showMore)?_c('notification-setting-detail',{attrs:{\"notifications\":_vm.emailNotifications,\"type\":\"email\"},on:{\"toggleNotification\":_vm.toggleNotification}}):_vm._e(),(_vm.showMore)?_c('notification-setting-detail',{attrs:{\"notifications\":_vm.pushNotifications,\"type\":\"push\"},on:{\"toggleNotification\":_vm.toggleNotification}}):_vm._e(),(_vm.showMore)?_c('notification-setting-detail',{attrs:{\"notifications\":_vm.browserNotifications,\"type\":\"browser\"},on:{\"toggleNotification\":_vm.toggleNotification}}):_vm._e(),_c('v-col',{staticClass:\"d-flex flex-column justify-center align-center mb-6\",attrs:{\"cols\":\"12\"}},[_c('v-btn',{staticStyle:{\"border-radius\":\"8px\"},attrs:{\"depressed\":\"\",\"color\":\"primary\",\"loading\":_vm.loading,\"disabled\":_vm.loading},on:{\"click\":_vm.submit}},[_vm._v(\" Save changes \")])],1)],1)],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('v-col',{attrs:{\"cols\":_vm.$vuetify.breakpoint.smAndDown ? 12 : 4}},[_c('v-col',{staticClass:\"title font-weight-black text-center\",staticStyle:{\"color\":\"#4D4D4D\"}},[_vm._v(\" \"+_vm._s(_vm.type.toProperCase())+\" Notifications \")]),(_vm.expand)?_c('v-row',{staticClass:\"flex-column\",attrs:{\"no-gutters\":\"\"}},[_vm._l((_vm.notifications),function(module,i){return [_c('v-col',{key:(\"curr-email-headline-\" + i),staticClass:\"subtitle-1 font-weight-black\",staticStyle:{\"color\":\"#4D4D4D\"}},[_vm._v(\" \"+_vm._s(module.category.toProperCase())+\" \")]),_vm._l((module.items),function(item,j){return [_c('v-switch',{key:(\"curr-email-\" + i + \"-\" + j),staticStyle:{\"height\":\"30px\"},attrs:{\"dense\":\"\",\"inset\":\"\",\"color\":\"primary\"},on:{\"change\":function($event){return _vm.onChange($event, item.id, module.category)}},scopedSlots:_vm._u([{key:\"label\",fn:function(){return [_c('span',{staticClass:\"switch-extra-label\"},[_vm._v(\" \"+_vm._s(item.name)+\" \")])]},proxy:true}],null,true),model:{value:(item.enabled),callback:function ($$v) {_vm.$set(item, \"enabled\", $$v)},expression:\"item.enabled\"}})]})]})],2):_vm._e(),_c('v-col',{staticClass:\"d-flex flex-column justify-center align-center mb-6\",attrs:{\"cols\":\"12\"}},[_c('v-btn',{staticClass:\"caption\",staticStyle:{\"border-radius\":\"8px\"},attrs:{\"depressed\":\"\",\"text\":\"\",\"color\":\"primary\"},on:{\"click\":function($event){_vm.expand = !_vm.expand}}},[_vm._v(\" \"+_vm._s(_vm.expand ? 'Collapse' : 'Expand')+\" \")])],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { NotificationCategory } from '@/types/Notification.interface'\nimport { NotificationToggle } from '@/types/NotificationSetting.interface'\nimport Vue from 'vue'\nexport default Vue.extend({\n props: {\n notifications: {\n required: true,\n type: Array\n },\n type: {\n required: true,\n type: String\n }\n },\n data() {\n return {\n expand: false\n }\n },\n methods: {\n onChange(val: boolean, key: string, module: NotificationCategory): void {\n this.$emit('toggleNotification', {\n type: this.type,\n category: module,\n key: key,\n val: val\n } as NotificationToggle)\n }\n }\n})\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationSettingDetail.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationSettingDetail.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./NotificationSettingDetail.vue?vue&type=template&id=61b8701d&\"\nimport script from \"./NotificationSettingDetail.vue?vue&type=script&lang=ts&\"\nexport * from \"./NotificationSettingDetail.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCol } from 'vuetify/lib/components/VGrid';\nimport { VRow } from 'vuetify/lib/components/VGrid';\nimport { VSwitch } from 'vuetify/lib/components/VSwitch';\ninstallComponents(component, {VBtn,VCol,VRow,VSwitch})\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport Vue from 'vue'\nimport NotificationSetting, {\n NotificationSettingDetail,\n NotificationToggle\n} from '@/types/NotificationSetting.interface'\nimport { mapGetters } from 'vuex'\nimport LoadingMask from '@/components/LoadingMask.vue'\nimport NotificationSettingDetailComponent from '@/components/NotificationSettingDetail.vue'\nexport default Vue.extend({\n components: {\n LoadingMask,\n 'notification-setting-detail': NotificationSettingDetailComponent\n },\n data() {\n return {\n generalNotification: {\n email: true,\n push: true,\n browser: true\n },\n loading: false,\n messageNotification: {\n email: true,\n push: true,\n browser: true\n },\n showMore: false\n }\n },\n computed: {\n ...mapGetters([\n 'browserNotifications',\n 'currentMembership',\n 'emailNotifications',\n 'isApp',\n 'productTier',\n 'pushNotifications',\n 'tenantMemberships'\n ]),\n generalSetting(): object {\n // If there is no current membership. return null\n if (\n !this.emailNotifications ||\n !this.pushNotifications ||\n !this.browserNotifications\n )\n return null\n\n // Check if our enabled matches the total\n const email = this.totalNotifications('email')\n const push = this.totalNotifications('push')\n const browser = this.totalNotifications('browser')\n\n // Return the total setting\n return { email: email, push: push, browser: browser }\n },\n messageSetting(): object {\n // If there is no current membership. return null\n if (!this.currentMembership) return null\n\n // Else, search their email notifications for all notifications that have module 'messages'\n const email = this.currentMembership.email_notifications.messages.enabled\n\n // Get all push notifications for messages\n const push = this.currentMembership.push_notifications.messages.enabled\n\n // Get all browser notifications for messages\n const browser = this.currentMembership.browser_notifications.messages.enabled\n\n // Return the total setting\n return { email: email, push: push, browser: browser }\n }\n },\n methods: {\n // Check browser notification permission\n checkNotificationPromise() {\n try {\n Notification.requestPermission().then()\n } catch (e) {\n return false\n }\n return true\n },\n goToBrowserNotifications(): void {\n // Have the browser ask for notification permission\n this.checkNotificationPromise()\n\n // Get the current status of browser notifications\n const s = Notification.permission === 'granted' ? 'enabled' : 'disabled'\n\n // Assemble the message text\n const text = `Browser notifications must be enabled/disabled in your browser settings. Steps to enable/disable these will vary by browser. Your browser notifications are currently ${s}`\n\n // Pop a message\n this.$store.dispatch('dialogOpen', {\n type: 'MESSAGE',\n title: 'Browser Notifications',\n text: text,\n icon: 'mdi-web',\n color: 'primary'\n })\n },\n switchGeneral(bool: boolean, type: string) {\n // Toggle our sets\n this.toggleAllNotifications(bool, type)\n\n // Construct our type selector\n const selector = `${type}_notifications`\n\n // Grab all of our keys\n const keys = Object.keys(this.currentMembership[selector])\n\n // Iterate through our keys\n for (let i = 0; i < keys.length; i++) {\n // If the key is NOT messages, then set the enabled\n if (keys[i] !== 'messages')\n this.currentMembership[selector][keys[i]].enabled = bool\n }\n },\n switchMessage(bool: boolean, type: string) {\n // Toggle our sets\n this.toggleAllNotifications(bool, type, true)\n\n // Construct our type selector\n const selector = `${type}_notifications`\n\n // Update our overall\n this.currentMembership[selector].messages.enabled = bool\n },\n async submit(): Promise {\n // Our payload is just the current membership\n const payload = this.currentMembership\n\n // Start the loading spinner\n this.loading = true\n\n // Send our request\n const response = await this.$store.dispatch('tenantMembershipsPut', payload)\n\n // Stop the loading spinner\n this.loading = false\n\n // If the request failed, do nothing\n if (!response) return\n\n // Check if browser settings were checked\n const browser = this.generalSetting.browser || this.messageSetting.browser\n\n // If browser is checked for any of them, notify the user IF they are not on mobile\n if (browser && !this.isApp) this.goToBrowserNotifications()\n\n // Else, close our dialog\n this.$emit('submit')\n },\n toggleAllNotifications(\n bool: boolean,\n type: string,\n message: boolean = false\n ): void {\n // Iterate through our type of notification\n this[`${type}Notifications`].forEach(\n (item: NotificationSetting, idx: number) => {\n // Reference to our category\n const category = item.category\n\n // If message is true, we skip if module is not message\n if (message && item.category !== 'messages') return\n // Else, if message is FALSE, we skip if module IS message\n else if (!message && item.category === 'messages') return\n\n // Iterate through our items for this module\n item.items.forEach((n: NotificationSettingDetail, nIdx: number) => {\n // Create our selector on our current membership\n const selector = `${type}_notifications`\n\n // Our notifications based on selector\n const notifs = this.currentMembership[selector]\n\n // Check if this notificaiton exists\n if (notifs[category].items[n.id]) {\n // If it exists, then set it\n this.currentMembership[selector][category].items[\n n.id\n ].enabled = bool\n }\n // Set our display as well\n this[`${type}Notifications`][idx].items[nIdx].enabled = bool\n })\n }\n )\n },\n toggleNotification(obj: NotificationToggle): void {\n // Toggle based on this deep selector\n this.currentMembership[`${obj.type}_notifications`][obj.category].items[\n obj.key\n ].enabled = obj.val\n },\n totalNotifications(type: string, message: boolean = false): boolean {\n // Grab our notifications for this type\n const notifs = this[`${type}Notifications`]\n\n // Get a filtered amount to only include enabled categories\n const filtered = notifs.filter((x) => {\n // If message is false, then we let this pass if category is messages\n if (!message && x.category === 'messages') return true\n\n // Else, we have to filter the items\n const total = x.items.filter((y) => {\n // Check for the enabled flag\n return y.enabled\n })\n\n // If our total length is greater than 0, return true\n return total.length > 0\n })\n\n // This is true if our filtered amount is equivalent to the base\n return filtered.length === notifs.length\n }\n }\n})\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationsSettings.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--13-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationsSettings.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./NotificationsSettings.vue?vue&type=template&id=73e37ff9&\"\nimport script from \"./NotificationsSettings.vue?vue&type=script&lang=ts&\"\nexport * from \"./NotificationsSettings.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./NotificationsSettings.vue?vue&type=style&index=0&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VCardText } from 'vuetify/lib/components/VCard';\nimport { VCardTitle } from 'vuetify/lib/components/VCard';\nimport { VCol } from 'vuetify/lib/components/VGrid';\nimport { VRow } from 'vuetify/lib/components/VGrid';\nimport { VSwitch } from 'vuetify/lib/components/VSwitch';\ninstallComponents(component, {VBtn,VCard,VCardText,VCardTitle,VCol,VRow,VSwitch})\n","export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./NotificationsSettings.vue?vue&type=style&index=0&lang=css&\""],"sourceRoot":""}