From 5c1f21cee023b566e01fecd1e13550304a0d1768 Mon Sep 17 00:00:00 2001 From: PMKuipers Date: Mon, 3 Jun 2024 23:24:16 +0200 Subject: [PATCH] ESLint Code cleanup --- Gruntfile.js | 40 +- README.md | 4 +- .../bootstrap-vue/bootstrap-vue.min.js.map | 2 +- amd/build/cfg-grades.min.js | 2 +- amd/build/cfg-grades.min.js.map | 2 +- amd/build/downloader.min.js.map | 2 +- amd/build/modedit-modal.min.js | 2 +- amd/build/modedit-modal.min.js.map | 2 +- amd/build/page-coach.min.js | 2 +- amd/build/page-coach.min.js.map | 2 +- amd/build/page-edit-plan.min.js.map | 2 +- amd/build/page-invitemanager.min.js | 2 +- amd/build/page-invitemanager.min.js.map | 2 +- amd/build/page-myreport.min.js | 2 +- amd/build/page-myreport.min.js.map | 2 +- amd/build/page-result-overview.min.js | 2 +- amd/build/page-result-overview.min.js.map | 2 +- amd/build/page-view-plan.min.js | 2 +- amd/build/page-view-plan.min.js.map | 2 +- amd/build/primary-nav-tools.min.js | 2 +- amd/build/primary-nav-tools.min.js.map | 2 +- amd/build/report-viewer-components.min.js | 2 +- amd/build/report-viewer-components.min.js.map | 2 +- amd/build/simpleline/css-calc.min.js.map | 2 +- amd/build/simpleline/simpleline.min.js.map | 2 +- amd/build/studyplan-editor-components.min.js | 2 +- .../studyplan-editor-components.min.js.map | 2 +- amd/build/studyplan-processor.min.js | 2 +- amd/build/studyplan-processor.min.js.map | 2 +- amd/build/studyplan-report-components.min.js | 2 +- .../studyplan-report-components.min.js.map | 2 +- amd/build/treestudyplan-components.min.js | 2 +- amd/build/treestudyplan-components.min.js.map | 2 +- amd/build/util/browserbuttonevents.min.js.map | 2 +- amd/build/util/css-calc.min.js.map | 2 +- amd/build/util/date-helper.min.js | 2 +- amd/build/util/date-helper.min.js.map | 2 +- amd/build/util/debounce.min.js.map | 2 +- amd/build/util/debugger.min.js | 2 +- amd/build/util/debugger.min.js.map | 2 +- amd/build/util/fittext-vue.min.js | 2 +- amd/build/util/fittext-vue.min.js.map | 2 +- amd/build/util/fitty.min.js.map | 2 +- amd/build/util/formfields.min.js | 2 +- amd/build/util/formfields.min.js.map | 2 +- amd/build/util/mform-helper.min.js.map | 2 +- amd/build/util/premium.min.js | 2 +- amd/build/util/premium.min.js.map | 2 +- amd/build/util/psidebar-vue.min.js.map | 2 +- amd/build/util/settings.min.js | 2 +- amd/build/util/settings.min.js.map | 2 +- amd/build/util/string-helper.min.js | 2 +- amd/build/util/string-helper.min.js.map | 2 +- amd/build/util/svgarc.min.js | 2 +- amd/build/util/svgarc.min.js.map | 2 +- .../vue-easy-dnd/reflect-metadata.min.js.map | 2 +- .../vue-class-component.min.js.map | 2 +- .../vue-property-decorator.min.js.map | 2 +- amd/build/vue/prod/vue.min.js.map | 2 +- amd/build/vue/vue.min.js | 2 +- amd/build/vue/vue.min.js.map | 2 +- amd/src/bootstrap-vue/bootstrap-vue.js | 1 + amd/src/cfg-grades.js | 38 +- amd/src/downloader.js | 30 +- amd/src/modedit-modal.js | 52 +- amd/src/page-coach.js | 130 +- amd/src/page-edit-plan.js | 18 +- amd/src/page-invitemanager.js | 29 +- amd/src/page-myreport.js | 18 +- amd/src/page-result-overview.js | 45 +- amd/src/page-view-plan.js | 169 +- amd/src/primary-nav-tools.js | 14 +- amd/src/report-viewer-components.js | 170 +- amd/src/simpleline/css-calc.js | 4 +- amd/src/simpleline/simpleline.js | 4 +- amd/src/studyplan-editor-components.js | 88 +- amd/src/studyplan-processor.js | 71 +- amd/src/studyplan-report-components.js | 222 +- amd/src/treestudyplan-components.js | 166 +- amd/src/util/browserbuttonevents.js | 31 +- amd/src/util/css-calc.js | 47 +- amd/src/util/date-helper.js | 67 +- amd/src/util/debounce.js | 17 +- amd/src/util/debugger.js | 41 +- amd/src/util/fittext-vue.js | 22 +- amd/src/util/fitty.js | 2 +- amd/src/util/formfields.js | 11 +- amd/src/util/mform-helper.js | 65 +- amd/src/util/premium.js | 19 +- amd/src/util/psidebar-vue.js | 62 +- amd/src/util/settings.js | 13 +- amd/src/util/string-helper.js | 43 +- amd/src/util/svgarc.js | 40 +- amd/src/util/textfit.js | 251 - amd/src/vue-easy-dnd/reflect-metadata.js | 2 +- amd/src/vue-easy-dnd/vue-class-component.js | 2 +- .../vue-easy-dnd/vue-property-decorator.js | 2 +- amd/src/vue/prod/vue.js | 2 +- amd/src/vue/vue.js | 11905 +--------------- build.php | 2 - classes/associationservice.php | 2 +- classes/badgeinfo.php | 5 +- classes/cascadeusersync.php | 3 +- classes/completionscanner.php | 2 +- classes/corecompletioninfo.php | 4 +- classes/coursecompetencyinfo.php | 4 +- classes/courseinfo.php | 10 +- classes/gradeinfo.php | 14 +- classes/gradingscanner.php | 2 +- classes/local/randomimage.php | 3 +- classes/premium.php | 4 +- classes/studyline.php | 33 +- classes/studyplan.php | 2 +- classes/studyplanservice.php | 2 +- css/devstyles.css | 12 +- edit-plan.php | 2 +- lang/en/local_treestudyplan.php | 1 - lang/nl/local_treestudyplan.php | 1 - lib.php | 2 +- myreport.php | 2 +- scss/bootstraptweaking.scss | 3 +- scss/colors.scss | 4 +- scss/generic.scss | 3 +- scss/invitemanager.scss | 5 +- scss/psidebar.scss | 7 +- scss/readme-moodle.txt | 9 +- scss/studyplan-report.scss | 44 +- scss/studyplan.scss | 129 +- scss/studyplancard.scss | 16 +- styles.css | 12 +- templates/form/element_text_integer.mustache | 24 +- version.php | 4 +- view-plan.php | 4 +- 133 files changed, 1170 insertions(+), 13281 deletions(-) delete mode 100644 amd/src/util/textfit.js diff --git a/Gruntfile.js b/Gruntfile.js index 9c4668d..0d98777 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -1,3 +1,4 @@ +/* eslint no-console: "off" */ // This file is part of Moodle - http://moodle.org/ // // Moodle is free software: you can redistribute it and/or modify @@ -22,7 +23,6 @@ * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ - /** * Grunt configuration. * @@ -34,48 +34,48 @@ module.exports = function(grunt) { const sass = require('sass'); // Import grunt configuration for moodle base - process.chdir("../.."); // change dir to moodle base + process.chdir("../.."); // Change dir to moodle base require(path.resolve(`./Gruntfile.js`))(grunt); // Run Gruntfile module from moodle base - grunt.registerTask('scssplugin','Compile scss/styles.sccs into styles.css and css/devstyles.css', () => { + grunt.registerTask('scssplugin', 'Compile scss/styles.sccs into styles.css and css/devstyles.css', () => { const devoutput = 'css/devstyles.css'; const prodoutput = 'styles.css'; // Get full path of compenent and scss folder - const componentPath = path.join(grunt.moodleEnv.gruntFilePath,grunt.moodleEnv.componentDirectory); - const scssPath = path.join(componentPath, 'scss','styles.scss'); + const componentPath = path.join(grunt.moodleEnv.gruntFilePath, grunt.moodleEnv.componentDirectory); + const scssPath = path.join(componentPath, 'scss', 'styles.scss'); console.log(`Compiling ${scssPath} including any imported files therein`); process.chdir(path.join(componentPath, 'scss')); const result = sass.compile(scssPath); - if ( result ) { + if (result) { console.info("got result"); // Some regex processing to match moodle stylelint styles - // change tab indent to 4 instead of 2 - let css = result.css.replace(/^ ([^ ])/gm ," $1"); + // Change tab indent to 4 instead of 2 + let css = result.css.replace(/^ {2}([^ ])/gm, " $1"); - // insert a newline after every comma in a css selector + // Insert a newline after every comma in a css selector // (only combined selectors will get that long) - css = css.replace(/^[^ ].*[\{,]$/gm , (m) => { // Find CSS selector lines - return m.replace(/, /g,",\n"); // replace comma followed by space with comma newline + css = css.replace(/^[^ ].*[{,]$/gm, (m) => { // Find CSS selector lines + return m.replace(/, /g, ",\n"); // Replace comma followed by space with comma newline }); - // replace hex color codes with lowercase (convenience function since I don't really care for the hex codes lowercase only rule) + // Replace hex color codes with lowercase. const hexCodeToLower = (match, m1, m2) => { - return '#'+m1.toLowerCase()+m2; - } - css = css.replace(/#([A-F0-9a-f]{3})([^A-F0-9a-f]?)/gm , hexCodeToLower); // 3 digit color codes - css = css.replace(/#([A-F0-9a-f]{6})([^A-F0-9a-f]?)/gm , hexCodeToLower); // 6 digit color codes - css = css.replace(/#([A-F0-9a-f]{8})([^A-F0-9a-f]?)/gm , hexCodeToLower); // 8 digit color codes (with alpha) + return '#' + m1.toLowerCase() + m2; + }; + css = css.replace(/#([A-F0-9a-f]{3})([^A-F0-9a-f]?)/gm, hexCodeToLower); // 3 digit color codes + css = css.replace(/#([A-F0-9a-f]{6})([^A-F0-9a-f]?)/gm, hexCodeToLower); // 6 digit color codes + css = css.replace(/#([A-F0-9a-f]{8})([^A-F0-9a-f]?)/gm, hexCodeToLower); // 8 digit color codes (with alpha) // All other errors should really be fixed in the scss files :) - [devoutput,prodoutput].forEach((output) => { + [devoutput, prodoutput].forEach((output) => { console.info(`Storing ${output}`); - grunt.file.write(path.join(componentPath, output),css); + grunt.file.write(path.join(componentPath, output), css); }); } @@ -92,7 +92,7 @@ module.exports = function(grunt) { }); // Remove gherkinlint from the startup list, since it exits with an error because of errors in moodle's own code - grunt.moodleEnv.startupTasks.splice(grunt.moodleEnv.startupTasks.indexOf("gherkinlint"),1); + grunt.moodleEnv.startupTasks.splice(grunt.moodleEnv.startupTasks.indexOf("gherkinlint"), 1); // Add the 'scssplugin' task as a startup task. grunt.moodleEnv.startupTasks.push('scssplugin'); diff --git a/README.md b/README.md index 5648354..32c91a8 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,13 @@ # Moodle studyplan plugin -Plugin to organize a curriculum into an easy to read graphical respresentation of courses and student progress therein. +Plugin to organize a curriculum into an easy to read graphical representation of courses and student progress therein. The studyplan plugin extends Moodle with the ability to show students and teachers an overview of their curriculum and results therein. By showing students an easy to read graphical overview of their progress over multiple courses, students are more in control of their own learning process than by just listing results alone ## Installing -Install the plugin by adding the zip file manually to the installed plugins in your moodle version +Install the plugin by adding the zip file manually to the installed plugins in your Moodle version ## Configuration post install diff --git a/amd/build/bootstrap-vue/bootstrap-vue.min.js.map b/amd/build/bootstrap-vue/bootstrap-vue.min.js.map index f1e269f..eba486e 100644 --- a/amd/build/bootstrap-vue/bootstrap-vue.min.js.map +++ b/amd/build/bootstrap-vue/bootstrap-vue.min.js.map @@ -1 +1 @@ -{"version":3,"file":"bootstrap-vue.min.js","sources":["../../src/bootstrap-vue/bootstrap-vue.js"],"sourcesContent":["/*!\n * BootstrapVue 2.23.1\n *\n * @link https://bootstrap-vue.org\n * @source https://github.com/bootstrap-vue/bootstrap-vue\n * @copyright (c) 2016-2022 BootstrapVue\n * @license MIT\n * https://github.com/bootstrap-vue/bootstrap-vue/blob/master/LICENSE\n */\n\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('../vue/vue')) :\n typeof define === 'function' && define.amd ? define(['../vue/vue'], factory) :\n (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.bootstrapVue = factory(global.Vue));\n}(this, (function (Vue) { 'use strict';\n\n function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }\n\n var Vue__default = /*#__PURE__*/_interopDefaultLegacy(Vue);\n\n function ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n enumerableOnly && (symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n })), keys.push.apply(keys, symbols);\n }\n\n return keys;\n }\n\n function _objectSpread2$3(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = null != arguments[i] ? arguments[i] : {};\n i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n\n return target;\n }\n\n function _typeof$1(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof$1 = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof$1(obj);\n }\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n }\n\n function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n }\n\n function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n Object.defineProperty(subClass, \"prototype\", {\n value: Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n }),\n writable: false\n });\n if (superClass) _setPrototypeOf(subClass, superClass);\n }\n\n function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n }\n\n function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n }\n\n function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n }\n\n function _construct(Parent, args, Class) {\n if (_isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) _setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n }\n\n function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n }\n\n function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !_isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return _construct(Class, arguments, _getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return _setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n }\n\n function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n\n return target;\n }\n\n function _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n\n var target = _objectWithoutPropertiesLoose(source, excluded);\n\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n }\n\n function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n }\n\n function _possibleConstructorReturn(self, call) {\n if (call && (typeof call === \"object\" || typeof call === \"function\")) {\n return call;\n } else if (call !== void 0) {\n throw new TypeError(\"Derived constructors may only return object or undefined\");\n }\n\n return _assertThisInitialized(self);\n }\n\n function _createSuper(Derived) {\n var hasNativeReflectConstruct = _isNativeReflectConstruct();\n\n return function _createSuperInternal() {\n var Super = _getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = _getPrototypeOf(this).constructor;\n\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return _possibleConstructorReturn(this, result);\n };\n }\n\n function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = _getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n }\n\n function _get() {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = _superPropBase(target, property);\n\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(arguments.length < 3 ? target : receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get.apply(this, arguments);\n }\n\n function _slicedToArray(arr, i) {\n return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();\n }\n\n function _toConsumableArray$1(arr) {\n return _arrayWithoutHoles$1(arr) || _iterableToArray$1(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread$1();\n }\n\n function _arrayWithoutHoles$1(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n }\n\n function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n }\n\n function _iterableToArray$1(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n }\n\n function _iterableToArrayLimit(arr, i) {\n var _i = arr == null ? null : typeof Symbol !== \"undefined\" && arr[Symbol.iterator] || arr[\"@@iterator\"];\n\n if (_i == null) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n\n var _s, _e;\n\n try {\n for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n }\n\n function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n }\n\n function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n\n return arr2;\n }\n\n function _nonIterableSpread$1() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var e=function(){return (e=Object.assign||function(e){for(var t,r=1,s=arguments.length;r 0;\n /msie|trident/.test(USER_AGENT); // Determine if the browser supports the option passive for events\n\n var HAS_PASSIVE_EVENT_SUPPORT = function () {\n var passiveEventSupported = false;\n\n if (IS_BROWSER) {\n try {\n var options = {\n // This function will be called when the browser\n // attempts to access the passive property\n get passive() {\n /* istanbul ignore next: will never be called in JSDOM */\n passiveEventSupported = true;\n }\n\n };\n WINDOW.addEventListener('test', options, options);\n WINDOW.removeEventListener('test', options, options);\n } catch (_unused) {\n /* istanbul ignore next: will never be called in JSDOM */\n passiveEventSupported = false;\n }\n }\n\n return passiveEventSupported;\n }();\n var HAS_TOUCH_SUPPORT = IS_BROWSER && ('ontouchstart' in DOCUMENT.documentElement || NAVIGATOR.maxTouchPoints > 0);\n var HAS_POINTER_EVENT_SUPPORT = IS_BROWSER && Boolean(WINDOW.PointerEvent || WINDOW.MSPointerEvent);\n /* istanbul ignore next: JSDOM only checks for 'IntersectionObserver' */\n\n var HAS_INTERACTION_OBSERVER_SUPPORT = IS_BROWSER && 'IntersectionObserver' in WINDOW && 'IntersectionObserverEntry' in WINDOW && // Edge 15 and UC Browser lack support for `isIntersecting`\n // but we an use `intersectionRatio > 0` instead\n // 'isIntersecting' in window.IntersectionObserverEntry.prototype &&\n 'intersectionRatio' in WINDOW.IntersectionObserverEntry.prototype;\n\n var NAME$2 = 'BvConfig';\n var PROP_NAME$2 = '$bvConfig';\n var DEFAULT_BREAKPOINT = ['xs', 'sm', 'md', 'lg', 'xl'];\n\n // --- General ---\n var RX_ARRAY_NOTATION = /\\[(\\d+)]/g;\n var RX_BV_PREFIX = /^(BV?)/;\n var RX_DIGITS = /^\\d+$/;\n var RX_EXTENSION = /^\\..+/;\n var RX_HASH = /^#/;\n var RX_HASH_ID = /^#[A-Za-z]+[\\w\\-:.]*$/;\n var RX_HTML_TAGS = /(<([^>]+)>)/gi;\n var RX_HYPHENATE = /\\B([A-Z])/g;\n var RX_LOWER_UPPER = /([a-z])([A-Z])/g;\n var RX_NUMBER = /^[0-9]*\\.?[0-9]+$/;\n var RX_PLUS = /\\+/g;\n var RX_REGEXP_REPLACE = /[-/\\\\^$*+?.()|[\\]{}]/g;\n var RX_SPACES = /[\\s\\uFEFF\\xA0]+/g;\n var RX_SPACE_SPLIT = /\\s+/;\n var RX_STAR = /\\/\\*$/;\n var RX_START_SPACE_WORD = /(\\s|^)(\\w)/g;\n var RX_TRIM_LEFT = /^\\s+/;\n var RX_UNDERSCORE = /_/g;\n var RX_UN_KEBAB = /-(\\w)/g; // --- Date ---\n // Loose YYYY-MM-DD matching, ignores any appended time inforation\n // Matches '1999-12-20', '1999-1-1', '1999-01-20T22:51:49.118Z', '1999-01-02 13:00:00'\n\n var RX_DATE = /^\\d+-\\d\\d?-\\d\\d?(?:\\s|T|$)/; // Used to split off the date parts of the YYYY-MM-DD string\n\n var RX_DATE_SPLIT = /-|\\s|T/; // Time string RegEx (optional seconds)\n\n var RX_TIME = /^([0-1]?[0-9]|2[0-3]):[0-5]?[0-9](:[0-5]?[0-9])?$/; // --- URL ---\n // HREFs must end with a hash followed by at least one non-hash character\n\n var RX_HREF = /^.*(#[^#]+)$/;\n var RX_ENCODED_COMMA = /%2C/g;\n var RX_ENCODE_REVERSE = /[!'()*]/g;\n var RX_QUERY_START = /^(\\?|#|&)/; // --- Aspect ---\n\n var RX_ASPECT = /^\\d+(\\.\\d*)?[/:]\\d+(\\.\\d*)?$/;\n var RX_ASPECT_SEPARATOR = /[/:]/; // --- Grid ---\n\n var RX_COL_CLASS = /^col-/; // --- Icon ---\n\n var RX_ICON_PREFIX = /^BIcon/; // --- Locale ---\n\n var RX_STRIP_LOCALE_MODS = /-u-.+/;\n\n /* istanbul ignore next */\n\n var Element = HAS_WINDOW_SUPPORT ? WINDOW.Element : /*#__PURE__*/function (_Object) {\n _inherits(Element, _Object);\n\n var _super = _createSuper(Element);\n\n function Element() {\n _classCallCheck(this, Element);\n\n return _super.apply(this, arguments);\n }\n\n return Element;\n }( /*#__PURE__*/_wrapNativeSuper(Object));\n /* istanbul ignore next */\n\n var HTMLElement = HAS_WINDOW_SUPPORT ? WINDOW.HTMLElement : /*#__PURE__*/function (_Element) {\n _inherits(HTMLElement, _Element);\n\n var _super2 = _createSuper(HTMLElement);\n\n function HTMLElement() {\n _classCallCheck(this, HTMLElement);\n\n return _super2.apply(this, arguments);\n }\n\n return HTMLElement;\n }(Element);\n /* istanbul ignore next */\n\n var SVGElement = HAS_WINDOW_SUPPORT ? WINDOW.SVGElement : /*#__PURE__*/function (_Element2) {\n _inherits(SVGElement, _Element2);\n\n var _super3 = _createSuper(SVGElement);\n\n function SVGElement() {\n _classCallCheck(this, SVGElement);\n\n return _super3.apply(this, arguments);\n }\n\n return SVGElement;\n }(Element);\n /* istanbul ignore next */\n\n var File = HAS_WINDOW_SUPPORT ? WINDOW.File : /*#__PURE__*/function (_Object2) {\n _inherits(File, _Object2);\n\n var _super4 = _createSuper(File);\n\n function File() {\n _classCallCheck(this, File);\n\n return _super4.apply(this, arguments);\n }\n\n return File;\n }( /*#__PURE__*/_wrapNativeSuper(Object));\n\n var toType$1 = function toType(value) {\n return _typeof$1(value);\n };\n var toRawType = function toRawType(value) {\n return Object.prototype.toString.call(value).slice(8, -1);\n };\n var isUndefined = function isUndefined(value) {\n return value === undefined;\n };\n var isNull = function isNull(value) {\n return value === null;\n };\n var isUndefinedOrNull = function isUndefinedOrNull(value) {\n return isUndefined(value) || isNull(value);\n };\n var isFunction$1 = function isFunction(value) {\n return toType$1(value) === 'function';\n };\n var isBoolean = function isBoolean(value) {\n return toType$1(value) === 'boolean';\n };\n var isString = function isString(value) {\n return toType$1(value) === 'string';\n };\n var isNumber = function isNumber(value) {\n return toType$1(value) === 'number';\n };\n var isNumeric$1 = function isNumeric(value) {\n return RX_NUMBER.test(String(value));\n };\n var isArray = function isArray(value) {\n return Array.isArray(value);\n }; // Quick object check\n // This is primarily used to tell Objects from primitive values\n // when we know the value is a JSON-compliant type\n // Note object could be a complex type like array, Date, etc.\n\n var isObject = function isObject(obj) {\n return obj !== null && _typeof$1(obj) === 'object';\n }; // Strict object type check\n // Only returns true for plain JavaScript objects\n\n var isPlainObject = function isPlainObject(obj) {\n return Object.prototype.toString.call(obj) === '[object Object]';\n };\n var isDate = function isDate(value) {\n return value instanceof Date;\n };\n var isEvent = function isEvent(value) {\n return value instanceof Event;\n };\n var isFile = function isFile(value) {\n return value instanceof File;\n };\n var isRegExp = function isRegExp(value) {\n return toRawType(value) === 'RegExp';\n };\n var isPromise = function isPromise(value) {\n return !isUndefinedOrNull(value) && isFunction$1(value.then) && isFunction$1(value.catch);\n };\n\n var assign = function assign() {\n return Object.assign.apply(Object, arguments);\n };\n var create = function create(proto, optionalProps) {\n return Object.create(proto, optionalProps);\n };\n var defineProperties = function defineProperties(obj, props) {\n return Object.defineProperties(obj, props);\n };\n var defineProperty$1 = function defineProperty(obj, prop, descriptor) {\n return Object.defineProperty(obj, prop, descriptor);\n };\n var getOwnPropertyNames = function getOwnPropertyNames(obj) {\n return Object.getOwnPropertyNames(obj);\n };\n var keys = function keys(obj) {\n return Object.keys(obj);\n }; // --- \"Instance\" ---\n\n var hasOwnProperty = function hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n };\n var toString$1 = function toString(obj) {\n return Object.prototype.toString.call(obj);\n }; // --- Utilities ---\n // Shallow copy an object\n\n var clone = function clone(obj) {\n return _objectSpread2$3({}, obj);\n }; // Return a shallow copy of object with the specified properties only\n // See: https://gist.github.com/bisubus/2da8af7e801ffd813fab7ac221aa7afc\n\n var pick$1 = function pick(obj, props) {\n return keys(obj).filter(function (key) {\n return props.indexOf(key) !== -1;\n }).reduce(function (result, key) {\n return _objectSpread2$3(_objectSpread2$3({}, result), {}, _defineProperty({}, key, obj[key]));\n }, {});\n }; // Return a shallow copy of object with the specified properties omitted\n // See: https://gist.github.com/bisubus/2da8af7e801ffd813fab7ac221aa7afc\n\n var omit = function omit(obj, props) {\n return keys(obj).filter(function (key) {\n return props.indexOf(key) === -1;\n }).reduce(function (result, key) {\n return _objectSpread2$3(_objectSpread2$3({}, result), {}, _defineProperty({}, key, obj[key]));\n }, {});\n }; // Merges two object deeply together\n // See: https://gist.github.com/Salakar/1d7137de9cb8b704e48a\n\n var mergeDeep = function mergeDeep(target, source) {\n if (isObject(target) && isObject(source)) {\n keys(source).forEach(function (key) {\n if (isObject(source[key])) {\n if (!target[key] || !isObject(target[key])) {\n target[key] = source[key];\n }\n\n mergeDeep(target[key], source[key]);\n } else {\n assign(target, _defineProperty({}, key, source[key]));\n }\n });\n }\n\n return target;\n }; // Returns a shallow copy of the object with keys in sorted order\n\n var sortKeys = function sortKeys(obj) {\n return keys(obj).sort().reduce(function (result, key) {\n return _objectSpread2$3(_objectSpread2$3({}, result), {}, _defineProperty({}, key, obj[key]));\n }, {});\n }; // Convenience method to create a read-only descriptor\n\n var readonlyDescriptor = function readonlyDescriptor() {\n return {\n enumerable: true,\n configurable: false,\n writable: false\n };\n };\n\n var cloneDeep = function cloneDeep(obj) {\n var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : obj;\n\n if (isArray(obj)) {\n return obj.reduce(function (result, val) {\n return [].concat(_toConsumableArray$1(result), [cloneDeep(val, val)]);\n }, []);\n }\n\n if (isPlainObject(obj)) {\n return keys(obj).reduce(function (result, key) {\n return _objectSpread2$3(_objectSpread2$3({}, result), {}, _defineProperty({}, key, cloneDeep(obj[key], obj[key])));\n }, {});\n }\n\n return defaultValue;\n };\n\n var identity = function identity(x) {\n return x;\n };\n\n /**\n * Get property defined by dot/array notation in string, returns undefined if not found\n *\n * @link https://gist.github.com/jeneg/9767afdcca45601ea44930ea03e0febf#gistcomment-1935901\n *\n * @param {Object} obj\n * @param {string|Array} path\n * @return {*}\n */\n\n var getRaw = function getRaw(obj, path) {\n var defaultValue = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;\n // Handle array of path values\n path = isArray(path) ? path.join('.') : path; // If no path or no object passed\n\n if (!path || !isObject(obj)) {\n return defaultValue;\n } // Handle edge case where user has dot(s) in top-level item field key\n // See https://github.com/bootstrap-vue/bootstrap-vue/issues/2762\n // Switched to `in` operator vs `hasOwnProperty` to handle obj.prototype getters\n // https://github.com/bootstrap-vue/bootstrap-vue/issues/3463\n\n\n if (path in obj) {\n return obj[path];\n } // Handle string array notation (numeric indices only)\n\n\n path = String(path).replace(RX_ARRAY_NOTATION, '.$1');\n var steps = path.split('.').filter(identity); // Handle case where someone passes a string of only dots\n\n if (steps.length === 0) {\n return defaultValue;\n } // Traverse path in object to find result\n // Switched to `in` operator vs `hasOwnProperty` to handle obj.prototype getters\n // https://github.com/bootstrap-vue/bootstrap-vue/issues/3463\n\n\n return steps.every(function (step) {\n return isObject(obj) && step in obj && !isUndefinedOrNull(obj = obj[step]);\n }) ? obj : isNull(obj) ? null : defaultValue;\n };\n /**\n * Get property defined by dot/array notation in string.\n *\n * @link https://gist.github.com/jeneg/9767afdcca45601ea44930ea03e0febf#gistcomment-1935901\n *\n * @param {Object} obj\n * @param {string|Array} path\n * @param {*} defaultValue (optional)\n * @return {*}\n */\n\n var get = function get(obj, path) {\n var defaultValue = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n var value = getRaw(obj, path);\n return isUndefinedOrNull(value) ? defaultValue : value;\n };\n\n /**\n * Utilities to get information about the current environment\n */\n var getEnv = function getEnv(key) {\n var fallback = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n var env = typeof process !== 'undefined' && process ? process.env || {} : {};\n\n if (!key) {\n /* istanbul ignore next */\n return env;\n }\n\n return env[key] || fallback;\n };\n var getNoWarn = function getNoWarn() {\n return getEnv('BOOTSTRAP_VUE_NO_WARN') || getEnv('NODE_ENV') === 'production';\n };\n\n /**\n * Log a warning message to the console with BootstrapVue formatting\n * @param {string} message\n */\n\n var warn = function warn(message)\n /* istanbul ignore next */\n {\n var source = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n\n if (!getNoWarn()) {\n console.warn(\"[BootstrapVue warn]: \".concat(source ? \"\".concat(source, \" - \") : '').concat(message));\n }\n };\n /**\n * Warn when no Promise support is given\n * @param {string} source\n * @returns {boolean} warned\n */\n\n var warnNotClient = function warnNotClient(source) {\n /* istanbul ignore else */\n if (IS_BROWSER) {\n return false;\n } else {\n warn(\"\".concat(source, \": Can not be called during SSR.\"));\n return true;\n }\n };\n /**\n * Warn when no Promise support is given\n * @param {string} source\n * @returns {boolean} warned\n */\n\n var warnNoPromiseSupport = function warnNoPromiseSupport(source) {\n /* istanbul ignore else */\n if (HAS_PROMISE_SUPPORT) {\n return false;\n } else {\n warn(\"\".concat(source, \": Requires Promise support.\"));\n return true;\n }\n };\n /**\n * Warn when no MutationObserver support is given\n * @param {string} source\n * @returns {boolean} warned\n */\n\n var warnNoMutationObserverSupport = function warnNoMutationObserverSupport(source) {\n /* istanbul ignore else */\n if (HAS_MUTATION_OBSERVER_SUPPORT) {\n return false;\n } else {\n warn(\"\".concat(source, \": Requires MutationObserver support.\"));\n return true;\n }\n };\n\n var BvConfig = /*#__PURE__*/function () {\n function BvConfig() {\n _classCallCheck(this, BvConfig);\n\n this.$_config = {};\n } // Method to merge in user config parameters\n\n\n _createClass(BvConfig, [{\n key: \"setConfig\",\n value: function setConfig() {\n var _this = this;\n\n var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n /* istanbul ignore next */\n if (!isPlainObject(config)) {\n return;\n }\n\n var configKeys = getOwnPropertyNames(config);\n configKeys.forEach(function (key) {\n /* istanbul ignore next */\n var subConfig = config[key];\n\n if (key === 'breakpoints') {\n /* istanbul ignore if */\n if (!isArray(subConfig) || subConfig.length < 2 || subConfig.some(function (b) {\n return !isString(b) || b.length === 0;\n })) {\n warn('\"breakpoints\" must be an array of at least 2 breakpoint names', NAME$2);\n } else {\n _this.$_config[key] = cloneDeep(subConfig);\n }\n } else if (isPlainObject(subConfig)) {\n // Component prop defaults\n _this.$_config[key] = getOwnPropertyNames(subConfig).reduce(function (config, prop) {\n if (!isUndefined(subConfig[prop])) {\n config[prop] = cloneDeep(subConfig[prop]);\n }\n\n return config;\n }, _this.$_config[key] || {});\n }\n });\n } // Clear the config\n\n }, {\n key: \"resetConfig\",\n value: function resetConfig() {\n this.$_config = {};\n } // Returns a deep copy of the user config\n\n }, {\n key: \"getConfig\",\n value: function getConfig() {\n return cloneDeep(this.$_config);\n } // Returns a deep copy of the config value\n\n }, {\n key: \"getConfigValue\",\n value: function getConfigValue(key) {\n var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n return cloneDeep(getRaw(this.$_config, key, defaultValue));\n }\n }]);\n\n return BvConfig;\n }(); // Method for applying a global config\n\n\n var setConfig = function setConfig() {\n var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n var Vue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Vue__default['default'];\n // Ensure we have a `$bvConfig` Object on the Vue prototype\n // We set on Vue and OurVue just in case consumer has not set an alias of `vue`\n Vue.prototype[PROP_NAME$2] = Vue__default['default'].prototype[PROP_NAME$2] = Vue.prototype[PROP_NAME$2] || Vue__default['default'].prototype[PROP_NAME$2] || new BvConfig(); // Apply the config values\n\n Vue.prototype[PROP_NAME$2].setConfig(config);\n }; // Method for resetting the user config\n\n /**\n * Checks if there are multiple instances of Vue, and warns (once) about possible issues.\n * @param {object} Vue\n */\n\n var checkMultipleVue = function () {\n var checkMultipleVueWarned = false;\n var MULTIPLE_VUE_WARNING = ['Multiple instances of Vue detected!', 'You may need to set up an alias for Vue in your bundler config.', 'See: https://bootstrap-vue.org/docs#using-module-bundlers'].join('\\n');\n return function (Vue) {\n /* istanbul ignore next */\n if (!checkMultipleVueWarned && Vue__default['default'] !== Vue && !IS_JSDOM) {\n warn(MULTIPLE_VUE_WARNING);\n }\n\n checkMultipleVueWarned = true;\n };\n }();\n /**\n * Plugin install factory function.\n * @param {object} { components, directives }\n * @returns {function} plugin install function\n */\n\n var installFactory = function installFactory() {\n var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n components = _ref.components,\n directives = _ref.directives,\n plugins = _ref.plugins;\n\n var install = function install(Vue) {\n var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n if (install.installed) {\n /* istanbul ignore next */\n return;\n }\n\n install.installed = true;\n checkMultipleVue(Vue);\n setConfig(config, Vue);\n registerComponents(Vue, components);\n registerDirectives(Vue, directives);\n registerPlugins(Vue, plugins);\n };\n\n install.installed = false;\n return install;\n };\n /**\n * Plugin object factory function.\n * @param {object} { components, directives, plugins }\n * @returns {object} plugin install object\n */\n\n var pluginFactory = function pluginFactory() {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n var extend = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n return _objectSpread2$3(_objectSpread2$3({}, extend), {}, {\n install: installFactory(options)\n });\n };\n /**\n * Load a group of plugins.\n * @param {object} Vue\n * @param {object} Plugin definitions\n */\n\n var registerPlugins = function registerPlugins(Vue) {\n var plugins = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n for (var plugin in plugins) {\n if (plugin && plugins[plugin]) {\n Vue.use(plugins[plugin]);\n }\n }\n };\n /**\n * Load a component.\n * @param {object} Vue\n * @param {string} Component name\n * @param {object} Component definition\n */\n\n var registerComponent = function registerComponent(Vue, name, def) {\n if (Vue && name && def) {\n Vue.component(name, def);\n }\n };\n /**\n * Load a group of components.\n * @param {object} Vue\n * @param {object} Object of component definitions\n */\n\n var registerComponents = function registerComponents(Vue) {\n var components = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n for (var component in components) {\n registerComponent(Vue, component, components[component]);\n }\n };\n /**\n * Load a directive.\n * @param {object} Vue\n * @param {string} Directive name\n * @param {object} Directive definition\n */\n\n var registerDirective = function registerDirective(Vue, name, def) {\n if (Vue && name && def) {\n // Ensure that any leading V is removed from the\n // name, as Vue adds it automatically\n Vue.directive(name.replace(/^VB/, 'B'), def);\n }\n };\n /**\n * Load a group of directives.\n * @param {object} Vue\n * @param {object} Object of directive definitions\n */\n\n var registerDirectives = function registerDirectives(Vue) {\n var directives = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n for (var directive in directives) {\n registerDirective(Vue, directive, directives[directive]);\n }\n };\n /**\n * Install plugin if window.Vue available\n * @param {object} Plugin definition\n */\n\n var vueUse = function vueUse(VuePlugin) {\n /* istanbul ignore next */\n if (HAS_WINDOW_SUPPORT && window.Vue) {\n window.Vue.use(VuePlugin);\n }\n /* istanbul ignore next */\n\n\n if (HAS_WINDOW_SUPPORT && VuePlugin.NAME) {\n window[VuePlugin.NAME] = VuePlugin;\n }\n };\n\n // Component names\n var NAME_ALERT = 'BAlert';\n var NAME_ASPECT = 'BAspect';\n var NAME_AVATAR = 'BAvatar';\n var NAME_AVATAR_GROUP = 'BAvatarGroup';\n var NAME_BADGE = 'BBadge';\n var NAME_BREADCRUMB = 'BBreadcrumb';\n var NAME_BREADCRUMB_ITEM = 'BBreadcrumbItem';\n var NAME_BREADCRUMB_LINK = 'BBreadcrumbLink';\n var NAME_BUTTON = 'BButton';\n var NAME_BUTTON_CLOSE = 'BButtonClose';\n var NAME_BUTTON_GROUP = 'BButtonGroup';\n var NAME_BUTTON_TOOLBAR = 'BButtonToolbar';\n var NAME_CALENDAR = 'BCalendar';\n var NAME_CARD = 'BCard';\n var NAME_CARD_BODY = 'BCardBody';\n var NAME_CARD_FOOTER = 'BCardFooter';\n var NAME_CARD_GROUP = 'BCardGroup';\n var NAME_CARD_HEADER = 'BCardHeader';\n var NAME_CARD_IMG = 'BCardImg';\n var NAME_CARD_IMG_LAZY = 'BCardImgLazy';\n var NAME_CARD_SUB_TITLE = 'BCardSubTitle';\n var NAME_CARD_TEXT = 'BCardText';\n var NAME_CARD_TITLE = 'BCardTitle';\n var NAME_CAROUSEL = 'BCarousel';\n var NAME_CAROUSEL_SLIDE = 'BCarouselSlide';\n var NAME_COL = 'BCol';\n var NAME_COLLAPSE = 'BCollapse';\n var NAME_CONTAINER = 'BContainer';\n var NAME_DROPDOWN = 'BDropdown';\n var NAME_DROPDOWN_DIVIDER = 'BDropdownDivider';\n var NAME_DROPDOWN_FORM = 'BDropdownForm';\n var NAME_DROPDOWN_GROUP = 'BDropdownGroup';\n var NAME_DROPDOWN_HEADER = 'BDropdownHeader';\n var NAME_DROPDOWN_ITEM = 'BDropdownItem';\n var NAME_DROPDOWN_ITEM_BUTTON = 'BDropdownItemButton';\n var NAME_DROPDOWN_TEXT = 'BDropdownText';\n var NAME_EMBED = 'BEmbed';\n var NAME_FORM = 'BForm';\n var NAME_FORM_CHECKBOX = 'BFormCheckbox';\n var NAME_FORM_CHECKBOX_GROUP = 'BFormCheckboxGroup';\n var NAME_FORM_DATALIST = 'BFormDatalist';\n var NAME_FORM_DATEPICKER = 'BFormDatepicker';\n var NAME_FORM_FILE = 'BFormFile';\n var NAME_FORM_GROUP = 'BFormGroup';\n var NAME_FORM_INPUT = 'BFormInput';\n var NAME_FORM_INVALID_FEEDBACK = 'BFormInvalidFeedback';\n var NAME_FORM_RADIO = 'BFormRadio';\n var NAME_FORM_RADIO_GROUP = 'BFormRadioGroup';\n var NAME_FORM_RATING = 'BFormRating';\n var NAME_FORM_ROW = 'BFormRow';\n var NAME_FORM_SELECT = 'BFormSelect';\n var NAME_FORM_SELECT_OPTION = 'BFormSelectOption';\n var NAME_FORM_SELECT_OPTION_GROUP = 'BFormSelectOptionGroup';\n var NAME_FORM_SPINBUTTON = 'BFormSpinbutton';\n var NAME_FORM_TAG = 'BFormTag';\n var NAME_FORM_TAGS = 'BFormTags';\n var NAME_FORM_TEXT = 'BFormText';\n var NAME_FORM_TEXTAREA = 'BFormTextarea';\n var NAME_FORM_TIMEPICKER = 'BFormTimepicker';\n var NAME_FORM_VALID_FEEDBACK = 'BFormValidFeedback';\n var NAME_ICON = 'BIcon';\n var NAME_ICONSTACK = 'BIconstack';\n var NAME_ICON_BASE = 'BIconBase';\n var NAME_IMG = 'BImg';\n var NAME_IMG_LAZY = 'BImgLazy';\n var NAME_INPUT_GROUP = 'BInputGroup';\n var NAME_INPUT_GROUP_ADDON = 'BInputGroupAddon';\n var NAME_INPUT_GROUP_APPEND = 'BInputGroupAppend';\n var NAME_INPUT_GROUP_PREPEND = 'BInputGroupPrepend';\n var NAME_INPUT_GROUP_TEXT = 'BInputGroupText';\n var NAME_JUMBOTRON = 'BJumbotron';\n var NAME_LINK = 'BLink';\n var NAME_LIST_GROUP = 'BListGroup';\n var NAME_LIST_GROUP_ITEM = 'BListGroupItem';\n var NAME_MEDIA = 'BMedia';\n var NAME_MEDIA_ASIDE = 'BMediaAside';\n var NAME_MEDIA_BODY = 'BMediaBody';\n var NAME_MODAL = 'BModal';\n var NAME_MSG_BOX = 'BMsgBox';\n var NAME_NAV = 'BNav';\n var NAME_NAVBAR = 'BNavbar';\n var NAME_NAVBAR_BRAND = 'BNavbarBrand';\n var NAME_NAVBAR_NAV = 'BNavbarNav';\n var NAME_NAVBAR_TOGGLE = 'BNavbarToggle';\n var NAME_NAV_FORM = 'BNavForm';\n var NAME_NAV_ITEM = 'BNavItem';\n var NAME_NAV_ITEM_DROPDOWN = 'BNavItemDropdown';\n var NAME_NAV_TEXT = 'BNavText';\n var NAME_OVERLAY = 'BOverlay';\n var NAME_PAGINATION = 'BPagination';\n var NAME_PAGINATION_NAV = 'BPaginationNav';\n var NAME_POPOVER = 'BPopover';\n var NAME_PROGRESS = 'BProgress';\n var NAME_PROGRESS_BAR = 'BProgressBar';\n var NAME_ROW = 'BRow';\n var NAME_SIDEBAR = 'BSidebar';\n var NAME_SKELETON = 'BSkeleton';\n var NAME_SKELETON_ICON = 'BSkeletonIcon';\n var NAME_SKELETON_IMG = 'BSkeletonImg';\n var NAME_SKELETON_TABLE = 'BSkeletonTable';\n var NAME_SKELETON_WRAPPER = 'BSkeletonWrapper';\n var NAME_SPINNER = 'BSpinner';\n var NAME_TAB = 'BTab';\n var NAME_TABLE = 'BTable';\n var NAME_TABLE_CELL = 'BTableCell';\n var NAME_TABLE_LITE = 'BTableLite';\n var NAME_TABLE_SIMPLE = 'BTableSimple';\n var NAME_TABS = 'BTabs';\n var NAME_TBODY = 'BTbody';\n var NAME_TFOOT = 'BTfoot';\n var NAME_TH = 'BTh';\n var NAME_THEAD = 'BThead';\n var NAME_TIME = 'BTime';\n var NAME_TOAST = 'BToast';\n var NAME_TOASTER = 'BToaster';\n var NAME_TOOLTIP = 'BTooltip';\n var NAME_TR = 'BTr'; // Helper component names\n\n var NAME_COLLAPSE_HELPER = 'BVCollapse';\n var NAME_FORM_BUTTON_LABEL_CONTROL = 'BVFormBtnLabelControl';\n var NAME_FORM_RATING_STAR = 'BVFormRatingStar';\n var NAME_POPOVER_HELPER = 'BVPopover';\n var NAME_POPOVER_TEMPLATE = 'BVPopoverTemplate';\n var NAME_POPPER = 'BVPopper';\n var NAME_TAB_BUTTON_HELPER = 'BVTabButton';\n var NAME_TOAST_POP = 'BVToastPop';\n var NAME_TOOLTIP_HELPER = 'BVTooltip';\n var NAME_TOOLTIP_TEMPLATE = 'BVTooltipTemplate';\n var NAME_TRANSITION = 'BVTransition';\n var NAME_TRANSPORTER = 'BVTransporter';\n var NAME_TRANSPORTER_TARGET = 'BVTransporterTarget';\n\n var EVENT_NAME_ACTIVATE_TAB = 'activate-tab';\n var EVENT_NAME_BLUR = 'blur';\n var EVENT_NAME_CANCEL = 'cancel';\n var EVENT_NAME_CHANGE = 'change';\n var EVENT_NAME_CHANGED = 'changed';\n var EVENT_NAME_CLICK = 'click';\n var EVENT_NAME_CLOSE = 'close';\n var EVENT_NAME_CONTEXT = 'context';\n var EVENT_NAME_CONTEXT_CHANGED = 'context-changed';\n var EVENT_NAME_DESTROYED = 'destroyed';\n var EVENT_NAME_DISABLE = 'disable';\n var EVENT_NAME_DISABLED = 'disabled';\n var EVENT_NAME_DISMISSED = 'dismissed';\n var EVENT_NAME_DISMISS_COUNT_DOWN = 'dismiss-count-down';\n var EVENT_NAME_ENABLE = 'enable';\n var EVENT_NAME_ENABLED = 'enabled';\n var EVENT_NAME_FILTERED = 'filtered';\n var EVENT_NAME_FIRST = 'first';\n var EVENT_NAME_FOCUS = 'focus';\n var EVENT_NAME_FOCUSIN = 'focusin';\n var EVENT_NAME_FOCUSOUT = 'focusout';\n var EVENT_NAME_HEAD_CLICKED = 'head-clicked';\n var EVENT_NAME_HIDDEN = 'hidden';\n var EVENT_NAME_HIDE = 'hide';\n var EVENT_NAME_IMG_ERROR = 'img-error';\n var EVENT_NAME_INPUT = 'input';\n var EVENT_NAME_LAST = 'last';\n var EVENT_NAME_MOUSEENTER = 'mouseenter';\n var EVENT_NAME_MOUSELEAVE = 'mouseleave';\n var EVENT_NAME_NEXT = 'next';\n var EVENT_NAME_OK = 'ok';\n var EVENT_NAME_OPEN = 'open';\n var EVENT_NAME_PAGE_CLICK = 'page-click';\n var EVENT_NAME_PAUSED = 'paused';\n var EVENT_NAME_PREV = 'prev';\n var EVENT_NAME_REFRESH = 'refresh';\n var EVENT_NAME_REFRESHED = 'refreshed';\n var EVENT_NAME_REMOVE = 'remove';\n var EVENT_NAME_ROW_CLICKED = 'row-clicked';\n var EVENT_NAME_ROW_CONTEXTMENU = 'row-contextmenu';\n var EVENT_NAME_ROW_DBLCLICKED = 'row-dblclicked';\n var EVENT_NAME_ROW_HOVERED = 'row-hovered';\n var EVENT_NAME_ROW_MIDDLE_CLICKED = 'row-middle-clicked';\n var EVENT_NAME_ROW_SELECTED = 'row-selected';\n var EVENT_NAME_ROW_UNHOVERED = 'row-unhovered';\n var EVENT_NAME_SELECTED = 'selected';\n var EVENT_NAME_SHOW = 'show';\n var EVENT_NAME_SHOWN = 'shown';\n var EVENT_NAME_SLIDING_END = 'sliding-end';\n var EVENT_NAME_SLIDING_START = 'sliding-start';\n var EVENT_NAME_SORT_CHANGED = 'sort-changed';\n var EVENT_NAME_TAG_STATE = 'tag-state';\n var EVENT_NAME_TOGGLE = 'toggle';\n var EVENT_NAME_UNPAUSED = 'unpaused';\n var EVENT_NAME_UPDATE = 'update';\n var HOOK_EVENT_NAME_BEFORE_DESTROY = isVue3 ? 'vnodeBeforeUnmount' : 'hook:beforeDestroy';\n var HOOK_EVENT_NAME_DESTROYED = isVue3 ? 'vNodeUnmounted' : 'hook:destroyed';\n var MODEL_EVENT_NAME_PREFIX = 'update:';\n var ROOT_EVENT_NAME_PREFIX = 'bv';\n var ROOT_EVENT_NAME_SEPARATOR = '::';\n var EVENT_OPTIONS_PASSIVE = {\n passive: true\n };\n var EVENT_OPTIONS_NO_CAPTURE = {\n passive: true,\n capture: false\n };\n\n // General types\n var PROP_TYPE_ANY = undefined;\n var PROP_TYPE_ARRAY = Array;\n var PROP_TYPE_BOOLEAN = Boolean;\n var PROP_TYPE_DATE = Date;\n var PROP_TYPE_FUNCTION = Function;\n var PROP_TYPE_NUMBER = Number;\n var PROP_TYPE_OBJECT = Object;\n var PROP_TYPE_REG_EXP = RegExp;\n var PROP_TYPE_STRING = String; // Multiple types\n\n var PROP_TYPE_ARRAY_FUNCTION = [PROP_TYPE_ARRAY, PROP_TYPE_FUNCTION];\n var PROP_TYPE_ARRAY_OBJECT = [PROP_TYPE_ARRAY, PROP_TYPE_OBJECT];\n var PROP_TYPE_ARRAY_OBJECT_STRING = [PROP_TYPE_ARRAY, PROP_TYPE_OBJECT, PROP_TYPE_STRING];\n var PROP_TYPE_ARRAY_STRING = [PROP_TYPE_ARRAY, PROP_TYPE_STRING];\n var PROP_TYPE_BOOLEAN_NUMBER = [PROP_TYPE_BOOLEAN, PROP_TYPE_NUMBER];\n var PROP_TYPE_BOOLEAN_NUMBER_STRING = [PROP_TYPE_BOOLEAN, PROP_TYPE_NUMBER, PROP_TYPE_STRING];\n var PROP_TYPE_BOOLEAN_STRING = [PROP_TYPE_BOOLEAN, PROP_TYPE_STRING];\n var PROP_TYPE_DATE_STRING = [PROP_TYPE_DATE, PROP_TYPE_STRING];\n var PROP_TYPE_FUNCTION_STRING = [PROP_TYPE_FUNCTION, PROP_TYPE_STRING];\n var PROP_TYPE_NUMBER_STRING = [PROP_TYPE_NUMBER, PROP_TYPE_STRING];\n var PROP_TYPE_NUMBER_OBJECT_STRING = [PROP_TYPE_NUMBER, PROP_TYPE_OBJECT, PROP_TYPE_STRING];\n var PROP_TYPE_OBJECT_FUNCTION = [PROP_TYPE_OBJECT, PROP_TYPE_FUNCTION];\n var PROP_TYPE_OBJECT_STRING = [PROP_TYPE_OBJECT, PROP_TYPE_STRING];\n\n var SLOT_NAME_ADD_BUTTON_TEXT = 'add-button-text';\n var SLOT_NAME_APPEND = 'append';\n var SLOT_NAME_ASIDE = 'aside';\n var SLOT_NAME_BADGE = 'badge';\n var SLOT_NAME_BOTTOM_ROW = 'bottom-row';\n var SLOT_NAME_BUTTON_CONTENT = 'button-content';\n var SLOT_NAME_CUSTOM_FOOT = 'custom-foot';\n var SLOT_NAME_DECREMENT = 'decrement';\n var SLOT_NAME_DEFAULT = 'default';\n var SLOT_NAME_DESCRIPTION = 'description';\n var SLOT_NAME_DISMISS = 'dismiss';\n var SLOT_NAME_DROP_PLACEHOLDER = 'drop-placeholder';\n var SLOT_NAME_ELLIPSIS_TEXT = 'ellipsis-text';\n var SLOT_NAME_EMPTY = 'empty';\n var SLOT_NAME_EMPTYFILTERED = 'emptyfiltered';\n var SLOT_NAME_FILE_NAME = 'file-name';\n var SLOT_NAME_FIRST = 'first';\n var SLOT_NAME_FIRST_TEXT = 'first-text';\n var SLOT_NAME_FOOTER = 'footer';\n var SLOT_NAME_HEADER = 'header';\n var SLOT_NAME_HEADER_CLOSE = 'header-close';\n var SLOT_NAME_ICON_CLEAR = 'icon-clear';\n var SLOT_NAME_ICON_EMPTY = 'icon-empty';\n var SLOT_NAME_ICON_FULL = 'icon-full';\n var SLOT_NAME_ICON_HALF = 'icon-half';\n var SLOT_NAME_IMG = 'img';\n var SLOT_NAME_INCREMENT = 'increment';\n var SLOT_NAME_INVALID_FEEDBACK = 'invalid-feedback';\n var SLOT_NAME_LABEL = 'label';\n var SLOT_NAME_LAST_TEXT = 'last-text';\n var SLOT_NAME_LEAD = 'lead';\n var SLOT_NAME_LOADING = 'loading';\n var SLOT_NAME_MODAL_BACKDROP = 'modal-backdrop';\n var SLOT_NAME_MODAL_CANCEL = 'modal-cancel';\n var SLOT_NAME_MODAL_FOOTER = 'modal-footer';\n var SLOT_NAME_MODAL_HEADER = 'modal-header';\n var SLOT_NAME_MODAL_HEADER_CLOSE = 'modal-header-close';\n var SLOT_NAME_MODAL_OK = 'modal-ok';\n var SLOT_NAME_MODAL_TITLE = 'modal-title';\n var SLOT_NAME_NAV_NEXT_DECADE = 'nav-next-decade';\n var SLOT_NAME_NAV_NEXT_MONTH = 'nav-next-month';\n var SLOT_NAME_NAV_NEXT_YEAR = 'nav-next-year';\n var SLOT_NAME_NAV_PEV_DECADE = 'nav-prev-decade';\n var SLOT_NAME_NAV_PEV_MONTH = 'nav-prev-month';\n var SLOT_NAME_NAV_PEV_YEAR = 'nav-prev-year';\n var SLOT_NAME_NAV_THIS_MONTH = 'nav-this-month';\n var SLOT_NAME_NEXT_TEXT = 'next-text';\n var SLOT_NAME_OVERLAY = 'overlay';\n var SLOT_NAME_PAGE = 'page';\n var SLOT_NAME_PLACEHOLDER = 'placeholder';\n var SLOT_NAME_PREPEND = 'prepend';\n var SLOT_NAME_PREV_TEXT = 'prev-text';\n var SLOT_NAME_ROW_DETAILS = 'row-details';\n var SLOT_NAME_TABLE_BUSY = 'table-busy';\n var SLOT_NAME_TABLE_CAPTION = 'table-caption';\n var SLOT_NAME_TABLE_COLGROUP = 'table-colgroup';\n var SLOT_NAME_TABS_END = 'tabs-end';\n var SLOT_NAME_TABS_START = 'tabs-start';\n var SLOT_NAME_TEXT = 'text';\n var SLOT_NAME_THEAD_TOP = 'thead-top';\n var SLOT_NAME_TITLE = 'title';\n var SLOT_NAME_TOAST_TITLE = 'toast-title';\n var SLOT_NAME_TOP_ROW = 'top-row';\n var SLOT_NAME_VALID_FEEDBACK = 'valid-feedback';\n\n var from = function from() {\n return Array.from.apply(Array, arguments);\n }; // --- Instance ---\n\n var arrayIncludes = function arrayIncludes(array, value) {\n return array.indexOf(value) !== -1;\n };\n var concat = function concat() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return Array.prototype.concat.apply([], args);\n }; // --- Utilities ---\n\n var createArray = function createArray(length, fillFn) {\n var mapFn = isFunction$1(fillFn) ? fillFn : function () {\n return fillFn;\n };\n return Array.apply(null, {\n length: length\n }).map(mapFn);\n };\n var flatten = function flatten(array) {\n return array.reduce(function (result, item) {\n return concat(result, item);\n }, []);\n };\n var flattenDeep = function flattenDeep(array) {\n return array.reduce(function (result, item) {\n return concat(result, Array.isArray(item) ? flattenDeep(item) : item);\n }, []);\n };\n\n // In functional components, `slots` is a function so it must be called\n // first before passing to the below methods. `scopedSlots` is always an\n // object and may be undefined (for Vue < 2.6.x)\n\n /**\n * Returns true if either scoped or unscoped named slot exists\n *\n * @param {String, Array} name or name[]\n * @param {Object} scopedSlots\n * @param {Object} slots\n * @returns {Array|undefined} VNodes\n */\n\n var hasNormalizedSlot = function hasNormalizedSlot(names) {\n var $scopedSlots = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var $slots = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n // Ensure names is an array\n names = concat(names).filter(identity); // Returns true if the either a $scopedSlot or $slot exists with the specified name\n\n return names.some(function (name) {\n return $scopedSlots[name] || $slots[name];\n });\n };\n /**\n * Returns VNodes for named slot either scoped or unscoped\n *\n * @param {String, Array} name or name[]\n * @param {String} scope\n * @param {Object} scopedSlots\n * @param {Object} slots\n * @returns {Array|undefined} VNodes\n */\n\n var normalizeSlot = function normalizeSlot(names) {\n var scope = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var $scopedSlots = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n var $slots = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n // Ensure names is an array\n names = concat(names).filter(identity);\n var slot;\n\n for (var i = 0; i < names.length && !slot; i++) {\n var name = names[i];\n slot = $scopedSlots[name] || $slots[name];\n } // Note: in Vue 2.6.x, all named slots are also scoped slots\n\n\n return isFunction$1(slot) ? slot(scope) : slot;\n };\n\n var normalizeSlotMixin = extend({\n methods: {\n // Returns `true` if the either a `$scopedSlot` or `$slot` exists with the specified name\n // `name` can be a string name or an array of names\n hasNormalizedSlot: function hasNormalizedSlot$1() {\n var name = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : SLOT_NAME_DEFAULT;\n var scopedSlots = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : this.$scopedSlots;\n var slots = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : this.$slots;\n return hasNormalizedSlot(name, scopedSlots, slots);\n },\n // Returns an array of rendered VNodes if slot found, otherwise `undefined`\n // `name` can be a string name or an array of names\n normalizeSlot: function normalizeSlot$1() {\n var name = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : SLOT_NAME_DEFAULT;\n var scope = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var scopedSlots = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : this.$scopedSlots;\n var slots = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : this.$slots;\n\n var vNodes = normalizeSlot(name, scope, scopedSlots, slots);\n\n return vNodes ? concat(vNodes) : vNodes;\n }\n }\n });\n\n // Number utilities\n // Converts a value (string, number, etc.) to an integer number\n // Assumes radix base 10\n var toInteger = function toInteger(value) {\n var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : NaN;\n var integer = parseInt(value, 10);\n return isNaN(integer) ? defaultValue : integer;\n }; // Converts a value (string, number, etc.) to a number\n\n var toFloat = function toFloat(value) {\n var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : NaN;\n var float = parseFloat(value);\n return isNaN(float) ? defaultValue : float;\n }; // Converts a value (string, number, etc.) to a string\n // representation with `precision` digits after the decimal\n // Returns the string 'NaN' if the value cannot be converted\n\n var toFixed = function toFixed(val, precision) {\n return toFloat(val).toFixed(toInteger(precision, 0));\n };\n\n // String utilities\n // Converts PascalCase or camelCase to kebab-case\n\n var kebabCase = function kebabCase(str) {\n return str.replace(RX_HYPHENATE, '-$1').toLowerCase();\n }; // Converts a kebab-case or camelCase string to PascalCase\n\n var pascalCase = function pascalCase(str) {\n str = kebabCase(str).replace(RX_UN_KEBAB, function (_, c) {\n return c ? c.toUpperCase() : '';\n });\n return str.charAt(0).toUpperCase() + str.slice(1);\n }; // Converts a string, including strings in camelCase or snake_case, into Start Case\n // It keeps original single quote and hyphen in the word\n // https://github.com/UrbanCompass/to-start-case\n\n var startCase = function startCase(str) {\n return str.replace(RX_UNDERSCORE, ' ').replace(RX_LOWER_UPPER, function (str, $1, $2) {\n return $1 + ' ' + $2;\n }).replace(RX_START_SPACE_WORD, function (str, $1, $2) {\n return $1 + $2.toUpperCase();\n });\n }; // Lowercases the first letter of a string and returns a new string\n\n var lowerFirst = function lowerFirst(str) {\n str = isString(str) ? str.trim() : String(str);\n return str.charAt(0).toLowerCase() + str.slice(1);\n }; // Uppercases the first letter of a string and returns a new string\n\n var upperFirst = function upperFirst(str) {\n str = isString(str) ? str.trim() : String(str);\n return str.charAt(0).toUpperCase() + str.slice(1);\n }; // Escape characters to be used in building a regular expression\n\n var escapeRegExp = function escapeRegExp(str) {\n return str.replace(RX_REGEXP_REPLACE, '\\\\$&');\n }; // Convert a value to a string that can be rendered\n // `undefined`/`null` will be converted to `''`\n // Plain objects and arrays will be JSON stringified\n\n var toString = function toString(val) {\n var spaces = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2;\n return isUndefinedOrNull(val) ? '' : isArray(val) || isPlainObject(val) && val.toString === Object.prototype.toString ? JSON.stringify(val, null, spaces) : String(val);\n }; // Remove leading white space from a string\n\n var trimLeft = function trimLeft(str) {\n return toString(str).replace(RX_TRIM_LEFT, '');\n }; // Remove Trailing white space from a string\n\n var trim = function trim(str) {\n return toString(str).trim();\n }; // Lower case a string\n\n var lowerCase = function lowerCase(str) {\n return toString(str).toLowerCase();\n }; // Upper case a string\n\n var ELEMENT_PROTO = Element.prototype;\n var TABABLE_SELECTOR = ['button', '[href]:not(.disabled)', 'input', 'select', 'textarea', '[tabindex]', '[contenteditable]'].map(function (s) {\n return \"\".concat(s, \":not(:disabled):not([disabled])\");\n }).join(', '); // --- Normalization utils ---\n // See: https://developer.mozilla.org/en-US/docs/Web/API/Element/matches#Polyfill\n\n /* istanbul ignore next */\n\n var matchesEl = ELEMENT_PROTO.matches || ELEMENT_PROTO.msMatchesSelector || ELEMENT_PROTO.webkitMatchesSelector; // See: https://developer.mozilla.org/en-US/docs/Web/API/Element/closest\n\n /* istanbul ignore next */\n\n var closestEl = ELEMENT_PROTO.closest || function (sel) {\n var el = this;\n\n do {\n // Use our \"patched\" matches function\n if (matches(el, sel)) {\n return el;\n }\n\n el = el.parentElement || el.parentNode;\n } while (!isNull(el) && el.nodeType === Node.ELEMENT_NODE);\n\n return null;\n }; // `requestAnimationFrame()` convenience method\n\n /* istanbul ignore next: JSDOM always returns the first option */\n\n var requestAF = (WINDOW.requestAnimationFrame || WINDOW.webkitRequestAnimationFrame || WINDOW.mozRequestAnimationFrame || WINDOW.msRequestAnimationFrame || WINDOW.oRequestAnimationFrame || // Fallback, but not a true polyfill\n // Only needed for Opera Mini\n\n /* istanbul ignore next */\n function (cb) {\n return setTimeout(cb, 16);\n }).bind(WINDOW);\n var MutationObs = WINDOW.MutationObserver || WINDOW.WebKitMutationObserver || WINDOW.MozMutationObserver || null; // --- Utils ---\n // Remove a node from DOM\n\n var removeNode = function removeNode(el) {\n return el && el.parentNode && el.parentNode.removeChild(el);\n }; // Determine if an element is an HTML element\n\n var isElement = function isElement(el) {\n return !!(el && el.nodeType === Node.ELEMENT_NODE);\n }; // Get the currently active HTML element\n\n var getActiveElement = function getActiveElement() {\n var excludes = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var activeElement = DOCUMENT.activeElement;\n return activeElement && !excludes.some(function (el) {\n return el === activeElement;\n }) ? activeElement : null;\n }; // Returns `true` if a tag's name equals `name`\n\n var isTag = function isTag(tag, name) {\n return toString(tag).toLowerCase() === toString(name).toLowerCase();\n }; // Determine if an HTML element is the currently active element\n\n var isActiveElement = function isActiveElement(el) {\n return isElement(el) && el === getActiveElement();\n }; // Determine if an HTML element is visible - Faster than CSS check\n\n var isVisible = function isVisible(el) {\n if (!isElement(el) || !el.parentNode || !contains(DOCUMENT.body, el)) {\n // Note this can fail for shadow dom elements since they\n // are not a direct descendant of document.body\n return false;\n }\n\n if (getStyle(el, 'display') === 'none') {\n // We do this check to help with vue-test-utils when using v-show\n\n /* istanbul ignore next */\n return false;\n } // All browsers support getBoundingClientRect(), except JSDOM as it returns all 0's for values :(\n // So any tests that need isVisible will fail in JSDOM\n // Except when we override the getBCR prototype in some tests\n\n\n var bcr = getBCR(el);\n return !!(bcr && bcr.height > 0 && bcr.width > 0);\n }; // Determine if an element is disabled\n\n var isDisabled = function isDisabled(el) {\n return !isElement(el) || el.disabled || hasAttr(el, 'disabled') || hasClass(el, 'disabled');\n }; // Cause/wait-for an element to reflow its content (adjusting its height/width)\n\n var reflow = function reflow(el) {\n // Requesting an elements offsetHight will trigger a reflow of the element content\n\n /* istanbul ignore next: reflow doesn't happen in JSDOM */\n return isElement(el) && el.offsetHeight;\n }; // Select all elements matching selector. Returns `[]` if none found\n\n var selectAll = function selectAll(selector, root) {\n return from((isElement(root) ? root : DOCUMENT).querySelectorAll(selector));\n }; // Select a single element, returns `null` if not found\n\n var select = function select(selector, root) {\n return (isElement(root) ? root : DOCUMENT).querySelector(selector) || null;\n }; // Determine if an element matches a selector\n\n var matches = function matches(el, selector) {\n return isElement(el) ? matchesEl.call(el, selector) : false;\n }; // Finds closest element matching selector. Returns `null` if not found\n\n var closest = function closest(selector, root) {\n var includeRoot = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n if (!isElement(root)) {\n return null;\n }\n\n var el = closestEl.call(root, selector); // Native closest behaviour when `includeRoot` is truthy,\n // else emulate jQuery closest and return `null` if match is\n // the passed in root element when `includeRoot` is falsey\n\n return includeRoot ? el : el === root ? null : el;\n }; // Returns true if the parent element contains the child element\n\n var contains = function contains(parent, child) {\n return parent && isFunction$1(parent.contains) ? parent.contains(child) : false;\n }; // Get an element given an ID\n\n var getById = function getById(id) {\n return DOCUMENT.getElementById(/^#/.test(id) ? id.slice(1) : id) || null;\n }; // Add a class to an element\n\n var addClass = function addClass(el, className) {\n // We are checking for `el.classList` existence here since IE 11\n // returns `undefined` for some elements (e.g. SVG elements)\n // See https://github.com/bootstrap-vue/bootstrap-vue/issues/2713\n if (className && isElement(el) && el.classList) {\n el.classList.add(className);\n }\n }; // Remove a class from an element\n\n var removeClass = function removeClass(el, className) {\n // We are checking for `el.classList` existence here since IE 11\n // returns `undefined` for some elements (e.g. SVG elements)\n // See https://github.com/bootstrap-vue/bootstrap-vue/issues/2713\n if (className && isElement(el) && el.classList) {\n el.classList.remove(className);\n }\n }; // Test if an element has a class\n\n var hasClass = function hasClass(el, className) {\n // We are checking for `el.classList` existence here since IE 11\n // returns `undefined` for some elements (e.g. SVG elements)\n // See https://github.com/bootstrap-vue/bootstrap-vue/issues/2713\n if (className && isElement(el) && el.classList) {\n return el.classList.contains(className);\n }\n\n return false;\n }; // Set an attribute on an element\n\n var setAttr = function setAttr(el, attr, value) {\n if (attr && isElement(el)) {\n el.setAttribute(attr, value);\n }\n }; // Remove an attribute from an element\n\n var removeAttr = function removeAttr(el, attr) {\n if (attr && isElement(el)) {\n el.removeAttribute(attr);\n }\n }; // Get an attribute value from an element\n // Returns `null` if not found\n\n var getAttr = function getAttr(el, attr) {\n return attr && isElement(el) ? el.getAttribute(attr) : null;\n }; // Determine if an attribute exists on an element\n // Returns `true` or `false`, or `null` if element not found\n\n var hasAttr = function hasAttr(el, attr) {\n return attr && isElement(el) ? el.hasAttribute(attr) : null;\n }; // Set an style property on an element\n\n var setStyle = function setStyle(el, prop, value) {\n if (prop && isElement(el)) {\n el.style[prop] = value;\n }\n }; // Remove an style property from an element\n\n var removeStyle = function removeStyle(el, prop) {\n if (prop && isElement(el)) {\n el.style[prop] = '';\n }\n }; // Get an style property value from an element\n // Returns `null` if not found\n\n var getStyle = function getStyle(el, prop) {\n return prop && isElement(el) ? el.style[prop] || null : null;\n }; // Return the Bounding Client Rect of an element\n // Returns `null` if not an element\n\n /* istanbul ignore next: getBoundingClientRect() doesn't work in JSDOM */\n\n var getBCR = function getBCR(el) {\n return isElement(el) ? el.getBoundingClientRect() : null;\n }; // Get computed style object for an element\n\n /* istanbul ignore next: getComputedStyle() doesn't work in JSDOM */\n\n var getCS = function getCS(el) {\n var getComputedStyle = WINDOW.getComputedStyle;\n return getComputedStyle && isElement(el) ? getComputedStyle(el) : {};\n }; // Returns a `Selection` object representing the range of text selected\n // Returns `null` if no window support is given\n\n /* istanbul ignore next: getSelection() doesn't work in JSDOM */\n\n var getSel = function getSel() {\n var getSelection = WINDOW.getSelection;\n return getSelection ? WINDOW.getSelection() : null;\n }; // Return an element's offset with respect to document element\n // https://j11y.io/jquery/#v=git&fn=jQuery.fn.offset\n\n var offset$1 = function offset(el)\n /* istanbul ignore next: getBoundingClientRect(), getClientRects() doesn't work in JSDOM */\n {\n var _offset = {\n top: 0,\n left: 0\n };\n\n if (!isElement(el) || el.getClientRects().length === 0) {\n return _offset;\n }\n\n var bcr = getBCR(el);\n\n if (bcr) {\n var win = el.ownerDocument.defaultView;\n _offset.top = bcr.top + win.pageYOffset;\n _offset.left = bcr.left + win.pageXOffset;\n }\n\n return _offset;\n }; // Return an element's offset with respect to to its offsetParent\n // https://j11y.io/jquery/#v=git&fn=jQuery.fn.position\n\n var position = function position(el)\n /* istanbul ignore next: getBoundingClientRect() doesn't work in JSDOM */\n {\n var _offset = {\n top: 0,\n left: 0\n };\n\n if (!isElement(el)) {\n return _offset;\n }\n\n var parentOffset = {\n top: 0,\n left: 0\n };\n var elStyles = getCS(el);\n\n if (elStyles.position === 'fixed') {\n _offset = getBCR(el) || _offset;\n } else {\n _offset = offset$1(el);\n var doc = el.ownerDocument;\n var offsetParent = el.offsetParent || doc.documentElement;\n\n while (offsetParent && (offsetParent === doc.body || offsetParent === doc.documentElement) && getCS(offsetParent).position === 'static') {\n offsetParent = offsetParent.parentNode;\n }\n\n if (offsetParent && offsetParent !== el && offsetParent.nodeType === Node.ELEMENT_NODE) {\n parentOffset = offset$1(offsetParent);\n var offsetParentStyles = getCS(offsetParent);\n parentOffset.top += toFloat(offsetParentStyles.borderTopWidth, 0);\n parentOffset.left += toFloat(offsetParentStyles.borderLeftWidth, 0);\n }\n }\n\n return {\n top: _offset.top - parentOffset.top - toFloat(elStyles.marginTop, 0),\n left: _offset.left - parentOffset.left - toFloat(elStyles.marginLeft, 0)\n };\n }; // Find all tabable elements in the given element\n // Assumes users have not used `tabindex` > `0` on elements\n\n var getTabables = function getTabables() {\n var rootEl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : document;\n return selectAll(TABABLE_SELECTOR, rootEl).filter(isVisible).filter(function (el) {\n return el.tabIndex > -1 && !el.disabled;\n });\n }; // Attempt to focus an element, and return `true` if successful\n\n var attemptFocus = function attemptFocus(el) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n try {\n el.focus(options);\n } catch (_unused) {}\n\n return isActiveElement(el);\n }; // Attempt to blur an element, and return `true` if successful\n\n var attemptBlur = function attemptBlur(el) {\n try {\n el.blur();\n } catch (_unused2) {}\n\n return !isActiveElement(el);\n };\n\n var memoize = function memoize(fn) {\n var cache = create(null);\n return function () {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var argsKey = JSON.stringify(args);\n return cache[argsKey] = cache[argsKey] || fn.apply(null, args);\n };\n };\n\n var VueProto = Vue__default['default'].prototype; // --- Getter methods ---\n\n var getConfigValue = function getConfigValue(key) {\n var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n var bvConfig = VueProto[PROP_NAME$2];\n return bvConfig ? bvConfig.getConfigValue(key, defaultValue) : cloneDeep(defaultValue);\n }; // Method to grab a config value for a particular component\n\n var getComponentConfig = function getComponentConfig(key) {\n var propKey = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n var defaultValue = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;\n // Return the particular config value for key if specified,\n // otherwise we return the full config (or an empty object if not found)\n return propKey ? getConfigValue(\"\".concat(key, \".\").concat(propKey), defaultValue) : getConfigValue(key, {});\n }; // Get all breakpoint names\n\n var getBreakpoints = function getBreakpoints() {\n return getConfigValue('breakpoints', DEFAULT_BREAKPOINT);\n }; // Private method for caching breakpoint names\n\n var _getBreakpointsCached = memoize(function () {\n return getBreakpoints();\n }); // Get all breakpoint names (cached)\n\n\n var getBreakpointsCached = function getBreakpointsCached() {\n return cloneDeep(_getBreakpointsCached());\n }; // Get breakpoints with the smallest breakpoint set as ''\n // Useful for components that create breakpoint specific props\n\n var getBreakpointsUpCached = memoize(function () {\n var breakpoints = getBreakpointsCached();\n breakpoints[0] = '';\n return breakpoints;\n }); // Get breakpoints with the largest breakpoint set as ''\n\n var prefixPropName = function prefixPropName(prefix, value) {\n return prefix + upperFirst(value);\n }; // Remove a prefix from a property\n\n var unprefixPropName = function unprefixPropName(prefix, value) {\n return lowerFirst(value.replace(prefix, ''));\n }; // Suffix can be a falsey value so nothing is appended to string\n // (helps when looping over props & some shouldn't change)\n // Use data last parameters to allow for currying\n\n var suffixPropName = function suffixPropName(suffix, value) {\n return value + (suffix ? upperFirst(suffix) : '');\n }; // Generates a prop object\n\n var makeProp = function makeProp() {\n var type = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : PROP_TYPE_ANY;\n var value = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n var requiredOrValidator = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;\n var validator = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : undefined;\n var required = requiredOrValidator === true;\n validator = required ? validator : requiredOrValidator;\n return _objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, type ? {\n type: type\n } : {}), required ? {\n required: required\n } : isUndefined(value) ? {} : {\n default: isObject(value) ? function () {\n return value;\n } : value\n }), isUndefined(validator) ? {} : {\n validator: validator\n });\n }; // Copies props from one array/object to a new array/object\n // Prop values are also cloned as new references to prevent possible\n // mutation of original prop object values\n // Optionally accepts a function to transform the prop name\n\n var copyProps = function copyProps(props) {\n var transformFn = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : identity;\n\n if (isArray(props)) {\n return props.map(transformFn);\n }\n\n var copied = {};\n\n for (var prop in props) {\n /* istanbul ignore else */\n if (hasOwnProperty(props, prop)) {\n // If the prop value is an object, do a shallow clone\n // to prevent potential mutations to the original object\n copied[transformFn(prop)] = isObject(props[prop]) ? clone(props[prop]) : props[prop];\n }\n }\n\n return copied;\n }; // Given an array of properties or an object of property keys,\n // plucks all the values off the target object, returning a new object\n // that has props that reference the original prop values\n\n var pluckProps = function pluckProps(keysToPluck, objToPluck) {\n var transformFn = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : identity;\n return (isArray(keysToPluck) ? keysToPluck.slice() : keys(keysToPluck)).reduce(function (memo, prop) {\n memo[transformFn(prop)] = objToPluck[prop];\n return memo;\n }, {});\n }; // Make a prop object configurable by global configuration\n // Replaces the current `default` key of each prop with a `getComponentConfig()`\n // call that falls back to the current default value of the prop\n\n var makePropConfigurable = function makePropConfigurable(prop, key, componentKey) {\n return _objectSpread2$3(_objectSpread2$3({}, cloneDeep(prop)), {}, {\n default: function bvConfigurablePropDefault() {\n var value = getComponentConfig(componentKey, key, prop.default);\n return isFunction$1(value) ? value() : value;\n }\n });\n }; // Make a props object configurable by global configuration\n // Replaces the current `default` key of each prop with a `getComponentConfig()`\n // call that falls back to the current default value of the prop\n\n var makePropsConfigurable = function makePropsConfigurable(props, componentKey) {\n return keys(props).reduce(function (result, key) {\n return _objectSpread2$3(_objectSpread2$3({}, result), {}, _defineProperty({}, key, makePropConfigurable(props[key], key, componentKey)));\n }, {});\n }; // Get function name we use in `makePropConfigurable()`\n // for the prop default value override to compare\n // against in `hasPropFunction()`\n\n var configurablePropDefaultFnName = makePropConfigurable({}, '', '').default.name; // Detect wether the given value is currently a function\n // and isn't the props default function\n\n var hasPropFunction = function hasPropFunction(fn) {\n return isFunction$1(fn) && fn.name && fn.name !== configurablePropDefaultFnName;\n };\n\n var makeModelMixin = function makeModelMixin(prop) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n _ref$type = _ref.type,\n type = _ref$type === void 0 ? PROP_TYPE_ANY : _ref$type,\n _ref$defaultValue = _ref.defaultValue,\n defaultValue = _ref$defaultValue === void 0 ? undefined : _ref$defaultValue,\n _ref$validator = _ref.validator,\n validator = _ref$validator === void 0 ? undefined : _ref$validator,\n _ref$event = _ref.event,\n event = _ref$event === void 0 ? EVENT_NAME_INPUT : _ref$event;\n\n var props = _defineProperty({}, prop, makeProp(type, defaultValue, validator)); // @vue/component\n\n\n var mixin = extend({\n model: {\n prop: prop,\n event: event\n },\n props: props\n });\n return {\n mixin: mixin,\n props: props,\n prop: prop,\n event: event\n };\n };\n\n // Normalize event options based on support of passive option\n // Exported only for testing purposes\n\n var parseEventOptions = function parseEventOptions(options) {\n /* istanbul ignore else: can't test in JSDOM, as it supports passive */\n if (HAS_PASSIVE_EVENT_SUPPORT) {\n return isObject(options) ? options : {\n capture: !!options || false\n };\n } else {\n // Need to translate to actual Boolean value\n return !!(isObject(options) ? options.capture : options);\n }\n }; // Attach an event listener to an element\n\n var eventOn = function eventOn(el, eventName, handler, options) {\n if (el && el.addEventListener) {\n el.addEventListener(eventName, handler, parseEventOptions(options));\n }\n }; // Remove an event listener from an element\n\n var eventOff = function eventOff(el, eventName, handler, options) {\n if (el && el.removeEventListener) {\n el.removeEventListener(eventName, handler, parseEventOptions(options));\n }\n }; // Utility method to add/remove a event listener based on first argument (boolean)\n // It passes all other arguments to the `eventOn()` or `eventOff` method\n\n var eventOnOff = function eventOnOff(on) {\n var method = on ? eventOn : eventOff;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n method.apply(void 0, args);\n }; // Utility method to prevent the default event handling and propagation\n\n var stopEvent = function stopEvent(event) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n _ref$preventDefault = _ref.preventDefault,\n preventDefault = _ref$preventDefault === void 0 ? true : _ref$preventDefault,\n _ref$propagation = _ref.propagation,\n propagation = _ref$propagation === void 0 ? true : _ref$propagation,\n _ref$immediatePropaga = _ref.immediatePropagation,\n immediatePropagation = _ref$immediatePropaga === void 0 ? false : _ref$immediatePropaga;\n\n if (preventDefault) {\n event.preventDefault();\n }\n\n if (propagation) {\n event.stopPropagation();\n }\n\n if (immediatePropagation) {\n event.stopImmediatePropagation();\n }\n }; // Helper method to convert a component/directive name to a base event name\n // `getBaseEventName('BNavigationItem')` => 'navigation-item'\n // `getBaseEventName('BVToggle')` => 'toggle'\n\n var getBaseEventName = function getBaseEventName(value) {\n return kebabCase(value.replace(RX_BV_PREFIX, ''));\n }; // Get a root event name by component/directive and event name\n // `getBaseEventName('BModal', 'show')` => 'bv::modal::show'\n\n\n var getRootEventName = function getRootEventName(name, eventName) {\n return [ROOT_EVENT_NAME_PREFIX, getBaseEventName(name), eventName].join(ROOT_EVENT_NAME_SEPARATOR);\n }; // Get a root action event name by component/directive and action name\n // `getRootActionEventName('BModal', 'show')` => 'bv::show::modal'\n\n var getRootActionEventName = function getRootActionEventName(name, actionName) {\n return [ROOT_EVENT_NAME_PREFIX, actionName, getBaseEventName(name)].join(ROOT_EVENT_NAME_SEPARATOR);\n };\n\n var props$2l = makePropsConfigurable({\n ariaLabel: makeProp(PROP_TYPE_STRING, 'Close'),\n content: makeProp(PROP_TYPE_STRING, '×'),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n textVariant: makeProp(PROP_TYPE_STRING)\n }, NAME_BUTTON_CLOSE); // --- Main component ---\n // @vue/component\n\n var BButtonClose = /*#__PURE__*/extend({\n name: NAME_BUTTON_CLOSE,\n functional: true,\n props: props$2l,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n slots = _ref.slots,\n scopedSlots = _ref.scopedSlots;\n var $slots = slots();\n var $scopedSlots = scopedSlots || {};\n var componentData = {\n staticClass: 'close',\n class: _defineProperty({}, \"text-\".concat(props.textVariant), props.textVariant),\n attrs: {\n type: 'button',\n disabled: props.disabled,\n 'aria-label': props.ariaLabel ? String(props.ariaLabel) : null\n },\n on: {\n click: function click(event) {\n // Ensure click on button HTML content is also disabled\n\n /* istanbul ignore if: bug in JSDOM still emits click on inner element */\n if (props.disabled && isEvent(event)) {\n stopEvent(event);\n }\n }\n }\n }; // Careful not to override the default slot with innerHTML\n\n if (!hasNormalizedSlot(SLOT_NAME_DEFAULT, $scopedSlots, $slots)) {\n componentData.domProps = {\n innerHTML: props.content\n };\n }\n\n return h('button', a(data, componentData), normalizeSlot(SLOT_NAME_DEFAULT, {}, $scopedSlots, $slots));\n }\n });\n\n var NO_FADE_PROPS = {\n name: '',\n enterClass: '',\n enterActiveClass: '',\n enterToClass: 'show',\n leaveClass: 'show',\n leaveActiveClass: '',\n leaveToClass: ''\n };\n\n var FADE_PROPS = _objectSpread2$3(_objectSpread2$3({}, NO_FADE_PROPS), {}, {\n enterActiveClass: 'fade',\n leaveActiveClass: 'fade'\n }); // --- Props ---\n\n\n var props$2k = {\n // Has no effect if `trans-props` provided\n appear: makeProp(PROP_TYPE_BOOLEAN, false),\n // Can be overridden by user supplied `trans-props`\n mode: makeProp(PROP_TYPE_STRING),\n // Only applicable to the built in transition\n // Has no effect if `trans-props` provided\n noFade: makeProp(PROP_TYPE_BOOLEAN, false),\n // For user supplied transitions (if needed)\n transProps: makeProp(PROP_TYPE_OBJECT)\n }; // --- Main component ---\n // @vue/component\n\n var BVTransition = /*#__PURE__*/extend({\n name: NAME_TRANSITION,\n functional: true,\n props: props$2k,\n render: function render(h, _ref) {\n var children = _ref.children,\n data = _ref.data,\n props = _ref.props;\n var transProps = props.transProps;\n\n if (!isPlainObject(transProps)) {\n transProps = props.noFade ? NO_FADE_PROPS : FADE_PROPS;\n\n if (props.appear) {\n // Default the appear classes to equal the enter classes\n transProps = _objectSpread2$3(_objectSpread2$3({}, transProps), {}, {\n appear: true,\n appearClass: transProps.enterClass,\n appearActiveClass: transProps.enterActiveClass,\n appearToClass: transProps.enterToClass\n });\n }\n }\n\n transProps = _objectSpread2$3(_objectSpread2$3({\n mode: props.mode\n }, transProps), {}, {\n // We always need `css` true\n css: true\n });\n\n var dataCopy = _objectSpread2$3({}, data);\n\n delete dataCopy.props;\n return h('transition', // Any transition event listeners will get merged here\n a(dataCopy, {\n props: transProps\n }), children);\n }\n });\n\n var _watch$k;\n\n var _makeModelMixin$k = makeModelMixin('show', {\n type: PROP_TYPE_BOOLEAN_NUMBER_STRING,\n defaultValue: false\n }),\n modelMixin$j = _makeModelMixin$k.mixin,\n modelProps$j = _makeModelMixin$k.props,\n MODEL_PROP_NAME$j = _makeModelMixin$k.prop,\n MODEL_EVENT_NAME$j = _makeModelMixin$k.event; // --- Helper methods ---\n // Convert `show` value to a number\n\n\n var parseCountDown = function parseCountDown(show) {\n if (show === '' || isBoolean(show)) {\n return 0;\n }\n\n show = toInteger(show, 0);\n return show > 0 ? show : 0;\n }; // Convert `show` value to a boolean\n\n\n var parseShow = function parseShow(show) {\n if (show === '' || show === true) {\n return true;\n }\n\n if (toInteger(show, 0) < 1) {\n // Boolean will always return false for the above comparison\n return false;\n }\n\n return !!show;\n }; // --- Props ---\n\n\n var props$2j = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, modelProps$j), {}, {\n dismissLabel: makeProp(PROP_TYPE_STRING, 'Close'),\n dismissible: makeProp(PROP_TYPE_BOOLEAN, false),\n fade: makeProp(PROP_TYPE_BOOLEAN, false),\n variant: makeProp(PROP_TYPE_STRING, 'info')\n })), NAME_ALERT); // --- Main component ---\n // @vue/component\n\n var BAlert = /*#__PURE__*/extend({\n name: NAME_ALERT,\n mixins: [modelMixin$j, normalizeSlotMixin],\n props: props$2j,\n data: function data() {\n return {\n countDown: 0,\n // If initially shown, we need to set these for SSR\n localShow: parseShow(this[MODEL_PROP_NAME$j])\n };\n },\n watch: (_watch$k = {}, _defineProperty(_watch$k, MODEL_PROP_NAME$j, function (newValue) {\n this.countDown = parseCountDown(newValue);\n this.localShow = parseShow(newValue);\n }), _defineProperty(_watch$k, \"countDown\", function countDown(newValue) {\n var _this = this;\n\n this.clearCountDownInterval();\n var show = this[MODEL_PROP_NAME$j]; // Ignore if `show` transitions to a boolean value\n\n if (isNumeric$1(show)) {\n this.$emit(EVENT_NAME_DISMISS_COUNT_DOWN, newValue); // Update the v-model if needed\n\n if (show !== newValue) {\n this.$emit(MODEL_EVENT_NAME$j, newValue);\n }\n\n if (newValue > 0) {\n this.localShow = true;\n this.$_countDownTimeout = setTimeout(function () {\n _this.countDown--;\n }, 1000);\n } else {\n // Slightly delay the hide to allow any UI updates\n this.$nextTick(function () {\n requestAF(function () {\n _this.localShow = false;\n });\n });\n }\n }\n }), _defineProperty(_watch$k, \"localShow\", function localShow(newValue) {\n var show = this[MODEL_PROP_NAME$j]; // Only emit dismissed events for dismissible or auto-dismissing alerts\n\n if (!newValue && (this.dismissible || isNumeric$1(show))) {\n this.$emit(EVENT_NAME_DISMISSED);\n } // Only emit booleans if we weren't passed a number via v-model\n\n\n if (!isNumeric$1(show) && show !== newValue) {\n this.$emit(MODEL_EVENT_NAME$j, newValue);\n }\n }), _watch$k),\n created: function created() {\n // Create private non-reactive props\n this.$_filterTimer = null;\n var show = this[MODEL_PROP_NAME$j];\n this.countDown = parseCountDown(show);\n this.localShow = parseShow(show);\n },\n beforeDestroy: function beforeDestroy() {\n this.clearCountDownInterval();\n },\n methods: {\n dismiss: function dismiss() {\n this.clearCountDownInterval();\n this.countDown = 0;\n this.localShow = false;\n },\n clearCountDownInterval: function clearCountDownInterval() {\n clearTimeout(this.$_countDownTimeout);\n this.$_countDownTimeout = null;\n }\n },\n render: function render(h) {\n var $alert = h();\n\n if (this.localShow) {\n var dismissible = this.dismissible,\n variant = this.variant;\n var $dismissButton = h();\n\n if (dismissible) {\n // Add dismiss button\n $dismissButton = h(BButtonClose, {\n attrs: {\n 'aria-label': this.dismissLabel\n },\n on: {\n click: this.dismiss\n }\n }, [this.normalizeSlot(SLOT_NAME_DISMISS)]);\n }\n\n $alert = h('div', {\n staticClass: 'alert',\n class: _defineProperty({\n 'alert-dismissible': dismissible\n }, \"alert-\".concat(variant), variant),\n attrs: {\n role: 'alert',\n 'aria-live': 'polite',\n 'aria-atomic': true\n },\n key: this[COMPONENT_UID_KEY]\n }, [$dismissButton, this.normalizeSlot()]);\n }\n\n return h(BVTransition, {\n props: {\n noFade: !this.fade\n }\n }, [$alert]);\n }\n });\n\n var AlertPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BAlert: BAlert\n }\n });\n\n // Math utilty functions\n var mathMin = Math.min;\n var mathMax = Math.max;\n var mathAbs = Math.abs;\n var mathCeil = Math.ceil;\n var mathFloor = Math.floor;\n var mathPow = Math.pow;\n var mathRound = Math.round;\n\n var CLASS_NAME$3 = 'b-aspect'; // --- Props ---\n\n var props$2i = makePropsConfigurable({\n // Accepts a number (i.e. `16 / 9`, `1`, `4 / 3`)\n // Or a string (i.e. '16/9', '16:9', '4:3' '1:1')\n aspect: makeProp(PROP_TYPE_NUMBER_STRING, '1:1'),\n tag: makeProp(PROP_TYPE_STRING, 'div')\n }, NAME_ASPECT); // --- Main component ---\n // @vue/component\n\n var BAspect = /*#__PURE__*/extend({\n name: NAME_ASPECT,\n mixins: [normalizeSlotMixin],\n props: props$2i,\n computed: {\n padding: function padding() {\n var aspect = this.aspect;\n var ratio = 1;\n\n if (RX_ASPECT.test(aspect)) {\n // Width and/or Height can be a decimal value below `1`, so\n // we only fallback to `1` if the value is `0` or `NaN`\n var _aspect$split$map = aspect.split(RX_ASPECT_SEPARATOR).map(function (v) {\n return toFloat(v) || 1;\n }),\n _aspect$split$map2 = _slicedToArray(_aspect$split$map, 2),\n width = _aspect$split$map2[0],\n height = _aspect$split$map2[1];\n\n ratio = width / height;\n } else {\n ratio = toFloat(aspect) || 1;\n }\n\n return \"\".concat(100 / mathAbs(ratio), \"%\");\n }\n },\n render: function render(h) {\n var $sizer = h('div', {\n staticClass: \"\".concat(CLASS_NAME$3, \"-sizer flex-grow-1\"),\n style: {\n paddingBottom: this.padding,\n height: 0\n }\n });\n var $content = h('div', {\n staticClass: \"\".concat(CLASS_NAME$3, \"-content flex-grow-1 w-100 mw-100\"),\n style: {\n marginLeft: '-100%'\n }\n }, this.normalizeSlot());\n return h(this.tag, {\n staticClass: \"\".concat(CLASS_NAME$3, \" d-flex\")\n }, [$sizer, $content]);\n }\n });\n\n var AspectPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BAspect: BAspect\n }\n });\n\n function safeVueInstance(target) {\n if (!isVue3) {\n return target;\n }\n\n return new Proxy(target, {\n get: function get(target, prop) {\n return prop in target ? target[prop] : undefined;\n }\n });\n }\n\n var ANCHOR_TAG = 'a'; // Method to replace reserved chars\n\n var encodeReserveReplacer = function encodeReserveReplacer(c) {\n return '%' + c.charCodeAt(0).toString(16);\n }; // Fixed encodeURIComponent which is more conformant to RFC3986:\n // - escapes [!'()*]\n // - preserve commas\n\n\n var encode = function encode(str) {\n return encodeURIComponent(toString(str)).replace(RX_ENCODE_REVERSE, encodeReserveReplacer).replace(RX_ENCODED_COMMA, ',');\n };\n\n var decode = decodeURIComponent; // Stringifies an object of query parameters\n // See: https://github.com/vuejs/vue-router/blob/dev/src/util/query.js\n\n var stringifyQueryObj = function stringifyQueryObj(obj) {\n if (!isPlainObject(obj)) {\n return '';\n }\n\n var query = keys(obj).map(function (key) {\n var value = obj[key];\n\n if (isUndefined(value)) {\n return '';\n } else if (isNull(value)) {\n return encode(key);\n } else if (isArray(value)) {\n return value.reduce(function (results, value2) {\n if (isNull(value2)) {\n results.push(encode(key));\n } else if (!isUndefined(value2)) {\n // Faster than string interpolation\n results.push(encode(key) + '=' + encode(value2));\n }\n\n return results;\n }, []).join('&');\n } // Faster than string interpolation\n\n\n return encode(key) + '=' + encode(value);\n })\n /* must check for length, as we only want to filter empty strings, not things that look falsey! */\n .filter(function (x) {\n return x.length > 0;\n }).join('&');\n return query ? \"?\".concat(query) : '';\n };\n var parseQuery = function parseQuery(query) {\n var parsed = {};\n query = toString(query).trim().replace(RX_QUERY_START, '');\n\n if (!query) {\n return parsed;\n }\n\n query.split('&').forEach(function (param) {\n var parts = param.replace(RX_PLUS, ' ').split('=');\n var key = decode(parts.shift());\n var value = parts.length > 0 ? decode(parts.join('=')) : null;\n\n if (isUndefined(parsed[key])) {\n parsed[key] = value;\n } else if (isArray(parsed[key])) {\n parsed[key].push(value);\n } else {\n parsed[key] = [parsed[key], value];\n }\n });\n return parsed;\n };\n var isLink$1 = function isLink(props) {\n return !!(props.href || props.to);\n };\n var isRouterLink = function isRouterLink(tag) {\n return !!(tag && !isTag(tag, 'a'));\n };\n var computeTag = function computeTag(_ref, thisOrParent) {\n var to = _ref.to,\n disabled = _ref.disabled,\n routerComponentName = _ref.routerComponentName;\n var hasRouter = !!safeVueInstance(thisOrParent).$router;\n var hasNuxt = !!safeVueInstance(thisOrParent).$nuxt;\n\n if (!hasRouter || hasRouter && (disabled || !to)) {\n return ANCHOR_TAG;\n } // TODO:\n // Check registered components for existence of user supplied router link component name\n // We would need to check PascalCase, kebab-case, and camelCase versions of name:\n // const name = routerComponentName\n // const names = [name, PascalCase(name), KebabCase(name), CamelCase(name)]\n // exists = names.some(name => !!thisOrParent.$options.components[name])\n // And may want to cache the result for performance or we just let the render fail\n // if the component is not registered\n\n\n return routerComponentName || (hasNuxt ? 'nuxt-link' : 'router-link');\n };\n var computeRel = function computeRel() {\n var _ref2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n target = _ref2.target,\n rel = _ref2.rel;\n\n return target === '_blank' && isNull(rel) ? 'noopener' : rel || null;\n };\n var computeHref = function computeHref() {\n var _ref3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n href = _ref3.href,\n to = _ref3.to;\n\n var tag = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ANCHOR_TAG;\n var fallback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '#';\n var toFallback = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : '/';\n\n // Return `href` when explicitly provided\n if (href) {\n return href;\n } // We've checked for `$router` in `computeTag()`, so `isRouterLink()` indicates a live router\n // When deferring to Vue Router's ``, don't use the `href` attribute at all\n // We return `null`, and then remove `href` from the attributes passed to ``\n\n\n if (isRouterLink(tag)) {\n return null;\n } // Fallback to `to` prop (if `to` is a string)\n\n\n if (isString(to)) {\n return to || toFallback;\n } // Fallback to `to.path' + `to.query` + `to.hash` prop (if `to` is an object)\n\n\n if (isPlainObject(to) && (to.path || to.query || to.hash)) {\n var path = toString(to.path);\n var query = stringifyQueryObj(to.query);\n var hash = toString(to.hash);\n hash = !hash || hash.charAt(0) === '#' ? hash : \"#\".concat(hash);\n return \"\".concat(path).concat(query).concat(hash) || toFallback;\n } // If nothing is provided return the fallback\n\n\n return fallback;\n };\n\n // Base attributes needed on all icons\n\n var BASE_ATTRS = {\n viewBox: '0 0 16 16',\n width: '1em',\n height: '1em',\n focusable: 'false',\n role: 'img',\n 'aria-label': 'icon'\n }; // Attributes that are nulled out when stacked\n\n var STACKED_ATTRS = {\n width: null,\n height: null,\n focusable: null,\n role: null,\n 'aria-label': null\n }; // --- Props ---\n\n var props$2h = {\n animation: makeProp(PROP_TYPE_STRING),\n content: makeProp(PROP_TYPE_STRING),\n flipH: makeProp(PROP_TYPE_BOOLEAN, false),\n flipV: makeProp(PROP_TYPE_BOOLEAN, false),\n fontScale: makeProp(PROP_TYPE_NUMBER_STRING, 1),\n rotate: makeProp(PROP_TYPE_NUMBER_STRING, 0),\n scale: makeProp(PROP_TYPE_NUMBER_STRING, 1),\n shiftH: makeProp(PROP_TYPE_NUMBER_STRING, 0),\n shiftV: makeProp(PROP_TYPE_NUMBER_STRING, 0),\n stacked: makeProp(PROP_TYPE_BOOLEAN, false),\n title: makeProp(PROP_TYPE_STRING),\n variant: makeProp(PROP_TYPE_STRING)\n }; // --- Main component ---\n // Shared private base component to reduce bundle/runtime size\n // @vue/component\n\n var BVIconBase = /*#__PURE__*/extend({\n name: NAME_ICON_BASE,\n functional: true,\n props: props$2h,\n render: function render(h, _ref) {\n var _class;\n\n var data = _ref.data,\n props = _ref.props,\n children = _ref.children;\n var animation = props.animation,\n content = props.content,\n flipH = props.flipH,\n flipV = props.flipV,\n stacked = props.stacked,\n title = props.title,\n variant = props.variant;\n var fontScale = mathMax(toFloat(props.fontScale, 1), 0) || 1;\n var scale = mathMax(toFloat(props.scale, 1), 0) || 1;\n var rotate = toFloat(props.rotate, 0);\n var shiftH = toFloat(props.shiftH, 0);\n var shiftV = toFloat(props.shiftV, 0); // Compute the transforms\n // Note that order is important as SVG transforms are applied in order from\n // left to right and we want flipping/scale to occur before rotation\n // Note shifting is applied separately\n // Assumes that the viewbox is `0 0 16 16` (`8 8` is the center)\n\n var hasScale = flipH || flipV || scale !== 1;\n var hasTransforms = hasScale || rotate;\n var hasShift = shiftH || shiftV;\n var hasContent = !isUndefinedOrNull(content);\n var transforms = [hasTransforms ? 'translate(8 8)' : null, hasScale ? \"scale(\".concat((flipH ? -1 : 1) * scale, \" \").concat((flipV ? -1 : 1) * scale, \")\") : null, rotate ? \"rotate(\".concat(rotate, \")\") : null, hasTransforms ? 'translate(-8 -8)' : null].filter(identity); // We wrap the content in a `` for handling the transforms (except shift)\n\n var $inner = h('g', {\n attrs: {\n transform: transforms.join(' ') || null\n },\n domProps: hasContent ? {\n innerHTML: content || ''\n } : {}\n }, children); // If needed, we wrap in an additional `` in order to handle the shifting\n\n if (hasShift) {\n $inner = h('g', {\n attrs: {\n transform: \"translate(\".concat(16 * shiftH / 16, \" \").concat(-16 * shiftV / 16, \")\")\n }\n }, [$inner]);\n } // Wrap in an additional `` for proper animation handling if stacked\n\n\n if (stacked) {\n $inner = h('g', [$inner]);\n }\n\n var $title = title ? h('title', title) : null;\n var $content = [$title, $inner].filter(identity);\n return h('svg', a({\n staticClass: 'b-icon bi',\n class: (_class = {}, _defineProperty(_class, \"text-\".concat(variant), variant), _defineProperty(_class, \"b-icon-animation-\".concat(animation), animation), _class),\n attrs: BASE_ATTRS,\n style: stacked ? {} : {\n fontSize: fontScale === 1 ? null : \"\".concat(fontScale * 100, \"%\")\n }\n }, // Merge in user supplied data\n data, // If icon is stacked, null-out some attrs\n stacked ? {\n attrs: STACKED_ATTRS\n } : {}, // These cannot be overridden by users\n {\n attrs: {\n xmlns: stacked ? null : 'http://www.w3.org/2000/svg',\n fill: 'currentColor'\n }\n }), $content);\n }\n });\n\n var iconProps$1 = omit(props$2h, ['content']);\n /**\n * Icon component generator function\n *\n * @param {string} icon name (minus the leading `BIcon`)\n * @param {string} raw `innerHTML` for SVG\n * @return {VueComponent}\n */\n\n var makeIcon = function makeIcon(name, content) {\n // For performance reason we pre-compute some values, so that\n // they are not computed on each render of the icon component\n var kebabName = kebabCase(name);\n var iconName = \"BIcon\".concat(pascalCase(name));\n var iconNameClass = \"bi-\".concat(kebabName);\n var iconTitle = kebabName.replace(/-/g, ' ');\n var svgContent = trim(content || '');\n return /*#__PURE__*/extend({\n name: iconName,\n functional: true,\n props: iconProps$1,\n render: function render(h, _ref) {\n var data = _ref.data,\n props = _ref.props;\n return h(BVIconBase, a( // Defaults\n {\n props: {\n title: iconTitle\n },\n attrs: {\n 'aria-label': iconTitle\n }\n }, // User data\n data, // Required data\n {\n staticClass: iconNameClass,\n props: _objectSpread2$3(_objectSpread2$3({}, props), {}, {\n content: svgContent\n })\n }));\n }\n });\n };\n\n // --- BEGIN AUTO-GENERATED FILE ---\n var BIconBlank=/*#__PURE__*/makeIcon('Blank','');// --- Bootstrap Icons ---\n var BIconCalendar=/*#__PURE__*/makeIcon('Calendar','');// eslint-disable-next-line\n var BIconCalendarFill=/*#__PURE__*/makeIcon('CalendarFill','');// eslint-disable-next-line\n var BIconChevronBarLeft=/*#__PURE__*/makeIcon('ChevronBarLeft','');// eslint-disable-next-line\n var BIconChevronDoubleLeft=/*#__PURE__*/makeIcon('ChevronDoubleLeft','');// eslint-disable-next-line\n var BIconChevronDown=/*#__PURE__*/makeIcon('ChevronDown','');// eslint-disable-next-line\n var BIconChevronLeft=/*#__PURE__*/makeIcon('ChevronLeft','');// eslint-disable-next-line\n var BIconChevronUp=/*#__PURE__*/makeIcon('ChevronUp','');// eslint-disable-next-line\n var BIconCircleFill=/*#__PURE__*/makeIcon('CircleFill','');// eslint-disable-next-line\n var BIconClock=/*#__PURE__*/makeIcon('Clock','');// eslint-disable-next-line\n var BIconClockFill=/*#__PURE__*/makeIcon('ClockFill','');// eslint-disable-next-line\n var BIconDash=/*#__PURE__*/makeIcon('Dash','');// eslint-disable-next-line\n var BIconPersonFill=/*#__PURE__*/makeIcon('PersonFill','');// eslint-disable-next-line\n var BIconPlus=/*#__PURE__*/makeIcon('Plus','');// eslint-disable-next-line\n var BIconStar=/*#__PURE__*/makeIcon('Star','');// eslint-disable-next-line\n var BIconStarFill=/*#__PURE__*/makeIcon('StarFill','');// eslint-disable-next-line\n var BIconStarHalf=/*#__PURE__*/makeIcon('StarHalf','');// eslint-disable-next-line\n var BIconX=/*#__PURE__*/makeIcon('X','');// eslint-disable-next-line\n // --- END AUTO-GENERATED FILE ---\n\n var findIconComponent = function findIconComponent(ctx, iconName) {\n if (!ctx) {\n return Vue__default['default'].component(iconName);\n }\n\n var components = (ctx.$options || {}).components;\n var iconComponent = components && components[iconName];\n return iconComponent || findIconComponent(ctx.$parent, iconName);\n }; // --- Props ---\n\n\n var iconProps = omit(props$2h, ['content']);\n var props$2g = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, iconProps), {}, {\n icon: makeProp(PROP_TYPE_STRING)\n })), NAME_ICON); // --- Main component ---\n // Helper BIcon component\n // Requires the requested icon component to be installed\n // @vue/component\n\n var BIcon = /*#__PURE__*/extend({\n name: NAME_ICON,\n functional: true,\n props: props$2g,\n render: function render(h, _ref) {\n var data = _ref.data,\n props = _ref.props,\n parent = _ref.parent;\n var icon = pascalCase(trim(props.icon || '')).replace(RX_ICON_PREFIX, ''); // If parent context exists, we check to see if the icon has been registered\n // either locally in the parent component, or globally at the `$root` level\n // If not registered, we render a blank icon\n\n return h(icon ? findIconComponent(parent, \"BIcon\".concat(icon)) || BIconBlank : BIconBlank, a(data, {\n props: pluckProps(iconProps, props)\n }));\n }\n });\n\n var CODE_BACKSPACE = 8;\n var CODE_DELETE = 46;\n var CODE_DOWN = 40;\n var CODE_END = 35;\n var CODE_ENTER = 13;\n var CODE_ESC = 27;\n var CODE_HOME = 36;\n var CODE_LEFT = 37;\n var CODE_PAGEDOWN = 34;\n var CODE_PAGEUP = 33;\n var CODE_RIGHT = 39;\n var CODE_SPACE = 32;\n var CODE_UP = 38;\n\n // Handles when arrays are \"sparse\" (array.every(...) doesn't handle sparse)\n\n var compareArrays = function compareArrays(a, b) {\n if (a.length !== b.length) {\n return false;\n }\n\n var equal = true;\n\n for (var i = 0; equal && i < a.length; i++) {\n equal = looseEqual(a[i], b[i]);\n }\n\n return equal;\n };\n /**\n * Check if two values are loosely equal - that is,\n * if they are plain objects, do they have the same shape?\n * Returns boolean true or false\n */\n\n\n var looseEqual = function looseEqual(a, b) {\n if (a === b) {\n return true;\n }\n\n var aValidType = isDate(a);\n var bValidType = isDate(b);\n\n if (aValidType || bValidType) {\n return aValidType && bValidType ? a.getTime() === b.getTime() : false;\n }\n\n aValidType = isArray(a);\n bValidType = isArray(b);\n\n if (aValidType || bValidType) {\n return aValidType && bValidType ? compareArrays(a, b) : false;\n }\n\n aValidType = isObject(a);\n bValidType = isObject(b);\n\n if (aValidType || bValidType) {\n /* istanbul ignore if: this if will probably never be called */\n if (!aValidType || !bValidType) {\n return false;\n }\n\n var aKeysCount = keys(a).length;\n var bKeysCount = keys(b).length;\n\n if (aKeysCount !== bKeysCount) {\n return false;\n }\n\n for (var key in a) {\n var aHasKey = hasOwnProperty(a, key);\n var bHasKey = hasOwnProperty(b, key);\n\n if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {\n return false;\n }\n }\n }\n\n return String(a) === String(b);\n };\n\n var isEmpty = function isEmpty(value) {\n return !value || keys(value).length === 0;\n };\n\n var makePropWatcher = function makePropWatcher(propName) {\n return {\n handler: function handler(newValue, oldValue) {\n if (looseEqual(newValue, oldValue)) {\n return;\n }\n\n if (isEmpty(newValue) || isEmpty(oldValue)) {\n this[propName] = cloneDeep(newValue);\n return;\n }\n\n for (var key in oldValue) {\n if (!hasOwnProperty(newValue, key)) {\n this.$delete(this.$data[propName], key);\n }\n }\n\n for (var _key in newValue) {\n this.$set(this.$data[propName], _key, newValue[_key]);\n }\n }\n };\n };\n var makePropCacheMixin = function makePropCacheMixin(propName, proxyPropName) {\n return extend({\n data: function data() {\n return _defineProperty({}, proxyPropName, cloneDeep(this[propName]));\n },\n watch: _defineProperty({}, propName, makePropWatcher(proxyPropName))\n });\n };\n\n var attrsMixinVue2 = makePropCacheMixin('$attrs', 'bvAttrs');\n var attrsMixinVue3 = extend({\n computed: {\n bvAttrs: function bvAttrs() {\n var bvAttrs = _objectSpread2$3({}, this.$attrs);\n\n Object.keys(bvAttrs).forEach(function (key) {\n if (bvAttrs[key] === undefined) {\n delete bvAttrs[key];\n }\n });\n return bvAttrs;\n }\n }\n });\n var attrsMixin = isVue3 ? attrsMixinVue3 : attrsMixinVue2;\n\n var getEventRoot = function getEventRoot(vm) {\n return vm.$root.$options.bvEventRoot || vm.$root;\n };\n\n var PROP$3 = '$_rootListeners'; // --- Mixin ---\n // @vue/component\n\n var listenOnRootMixin = extend({\n computed: {\n bvEventRoot: function bvEventRoot() {\n return getEventRoot(this);\n }\n },\n created: function created() {\n // Define non-reactive property\n // Object of arrays, keyed by event name,\n // where value is an array of callbacks\n this[PROP$3] = {};\n },\n beforeDestroy: function beforeDestroy() {\n var _this = this;\n\n // Unregister all registered listeners\n keys(this[PROP$3] || {}).forEach(function (event) {\n _this[PROP$3][event].forEach(function (callback) {\n _this.listenOffRoot(event, callback);\n });\n });\n this[PROP$3] = null;\n },\n methods: {\n registerRootListener: function registerRootListener(event, callback) {\n if (this[PROP$3]) {\n this[PROP$3][event] = this[PROP$3][event] || [];\n\n if (!arrayIncludes(this[PROP$3][event], callback)) {\n this[PROP$3][event].push(callback);\n }\n }\n },\n unregisterRootListener: function unregisterRootListener(event, callback) {\n if (this[PROP$3] && this[PROP$3][event]) {\n this[PROP$3][event] = this[PROP$3][event].filter(function (cb) {\n return cb !== callback;\n });\n }\n },\n\n /**\n * Safely register event listeners on the root Vue node\n * While Vue automatically removes listeners for individual components,\n * when a component registers a listener on `$root` and is destroyed,\n * this orphans a callback because the node is gone, but the `$root`\n * does not clear the callback\n *\n * When registering a `$root` listener, it also registers the listener\n * to be removed in the component's `beforeDestroy()` hook\n *\n * @param {string} event\n * @param {function} callback\n */\n listenOnRoot: function listenOnRoot(event, callback) {\n if (this.bvEventRoot) {\n this.bvEventRoot.$on(event, callback);\n this.registerRootListener(event, callback);\n }\n },\n\n /**\n * Safely register a `$once()` event listener on the root Vue node\n * While Vue automatically removes listeners for individual components,\n * when a component registers a listener on `$root` and is destroyed,\n * this orphans a callback because the node is gone, but the `$root`\n * does not clear the callback\n *\n * When registering a `$root` listener, it also registers the listener\n * to be removed in the component's `beforeDestroy()` hook\n *\n * @param {string} event\n * @param {function} callback\n */\n listenOnRootOnce: function listenOnRootOnce(event, callback) {\n var _this2 = this;\n\n if (this.bvEventRoot) {\n var _callback = function _callback() {\n _this2.unregisterRootListener(_callback); // eslint-disable-next-line node/no-callback-literal\n\n\n callback.apply(void 0, arguments);\n };\n\n this.bvEventRoot.$once(event, _callback);\n this.registerRootListener(event, _callback);\n }\n },\n\n /**\n * Safely unregister event listeners from the root Vue node\n *\n * @param {string} event\n * @param {function} callback\n */\n listenOffRoot: function listenOffRoot(event, callback) {\n this.unregisterRootListener(event, callback);\n\n if (this.bvEventRoot) {\n this.bvEventRoot.$off(event, callback);\n }\n },\n\n /**\n * Convenience method for calling `vm.$emit()` on `$root`\n *\n * @param {string} event\n * @param {*} args\n */\n emitOnRoot: function emitOnRoot(event) {\n if (this.bvEventRoot) {\n var _this$bvEventRoot;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n (_this$bvEventRoot = this.bvEventRoot).$emit.apply(_this$bvEventRoot, [event].concat(args));\n }\n }\n }\n });\n\n var listenersMixinVue2 = makePropCacheMixin('$listeners', 'bvListeners');\n var listenersMixinVue3 = extend({\n data: function data() {\n return {\n bvListeners: {}\n };\n },\n created: function created() {\n this.bvListeners = _objectSpread2$3({}, this.$listeners);\n },\n beforeUpdate: function beforeUpdate() {\n this.bvListeners = _objectSpread2$3({}, this.$listeners);\n }\n });\n var listenersMixin = isVue3 ? listenersMixinVue3 : listenersMixinVue2;\n\n var ROOT_EVENT_NAME_CLICKED = getRootEventName(NAME_LINK, 'clicked'); // --- Props ---\n // `` specific props\n\n var routerLinkProps = {\n activeClass: makeProp(PROP_TYPE_STRING),\n append: makeProp(PROP_TYPE_BOOLEAN, false),\n event: makeProp(PROP_TYPE_ARRAY_STRING),\n exact: makeProp(PROP_TYPE_BOOLEAN, false),\n exactActiveClass: makeProp(PROP_TYPE_STRING),\n exactPath: makeProp(PROP_TYPE_BOOLEAN, false),\n exactPathActiveClass: makeProp(PROP_TYPE_STRING),\n replace: makeProp(PROP_TYPE_BOOLEAN, false),\n routerTag: makeProp(PROP_TYPE_STRING),\n to: makeProp(PROP_TYPE_OBJECT_STRING)\n }; // `` specific props\n\n var nuxtLinkProps = {\n noPrefetch: makeProp(PROP_TYPE_BOOLEAN, false),\n // Must be `null` to fall back to the value defined in the\n // `nuxt.config.js` configuration file for `router.prefetchLinks`\n // We convert `null` to `undefined`, so that Nuxt.js will use the\n // compiled default\n // Vue treats `undefined` as default of `false` for Boolean props,\n // so we must set it as `null` here to be a true tri-state prop\n prefetch: makeProp(PROP_TYPE_BOOLEAN, null)\n }; // All `` props\n\n var props$2f = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, nuxtLinkProps), routerLinkProps), {}, {\n active: makeProp(PROP_TYPE_BOOLEAN, false),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n href: makeProp(PROP_TYPE_STRING),\n // Must be `null` if no value provided\n rel: makeProp(PROP_TYPE_STRING, null),\n // To support 3rd party router links based on `` (i.e. `g-link` for Gridsome)\n // Default is to auto choose between `` and ``\n // Gridsome doesn't provide a mechanism to auto detect and has caveats\n // such as not supporting FQDN URLs or hash only URLs\n routerComponentName: makeProp(PROP_TYPE_STRING),\n target: makeProp(PROP_TYPE_STRING, '_self')\n })), NAME_LINK); // --- Main component ---\n // @vue/component\n\n var BLink = /*#__PURE__*/extend({\n name: NAME_LINK,\n // Mixin order is important!\n mixins: [attrsMixin, listenersMixin, listenOnRootMixin, normalizeSlotMixin],\n inheritAttrs: false,\n props: props$2f,\n computed: {\n computedTag: function computedTag() {\n // We don't pass `this` as the first arg as we need reactivity of the props\n var to = this.to,\n disabled = this.disabled,\n routerComponentName = this.routerComponentName;\n return computeTag({\n to: to,\n disabled: disabled,\n routerComponentName: routerComponentName\n }, this);\n },\n isRouterLink: function isRouterLink$1() {\n return isRouterLink(this.computedTag);\n },\n computedRel: function computedRel() {\n // We don't pass `this` as the first arg as we need reactivity of the props\n var target = this.target,\n rel = this.rel;\n return computeRel({\n target: target,\n rel: rel\n });\n },\n computedHref: function computedHref() {\n // We don't pass `this` as the first arg as we need reactivity of the props\n var to = this.to,\n href = this.href;\n return computeHref({\n to: to,\n href: href\n }, this.computedTag);\n },\n computedProps: function computedProps() {\n var event = this.event,\n prefetch = this.prefetch,\n routerTag = this.routerTag;\n return this.isRouterLink ? _objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, pluckProps(omit(_objectSpread2$3(_objectSpread2$3({}, routerLinkProps), this.computedTag === 'nuxt-link' ? nuxtLinkProps : {}), ['event', 'prefetch', 'routerTag']), this)), event ? {\n event: event\n } : {}), isBoolean(prefetch) ? {\n prefetch: prefetch\n } : {}), routerTag ? {\n tag: routerTag\n } : {}) : {};\n },\n computedAttrs: function computedAttrs() {\n var bvAttrs = this.bvAttrs,\n href = this.computedHref,\n rel = this.computedRel,\n disabled = this.disabled,\n target = this.target,\n routerTag = this.routerTag,\n isRouterLink = this.isRouterLink;\n return _objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, bvAttrs), href ? {\n href: href\n } : {}), isRouterLink && routerTag && !isTag(routerTag, 'a') ? {} : {\n rel: rel,\n target: target\n }), {}, {\n tabindex: disabled ? '-1' : isUndefined(bvAttrs.tabindex) ? null : bvAttrs.tabindex,\n 'aria-disabled': disabled ? 'true' : null\n });\n },\n computedListeners: function computedListeners() {\n return _objectSpread2$3(_objectSpread2$3({}, this.bvListeners), {}, {\n // We want to overwrite any click handler since our callback\n // will invoke the user supplied handler(s) if `!this.disabled`\n click: this.onClick\n });\n }\n },\n methods: {\n onClick: function onClick(event) {\n var _arguments = arguments;\n var eventIsEvent = isEvent(event);\n var isRouterLink = this.isRouterLink;\n var suppliedHandler = this.bvListeners.click;\n\n if (eventIsEvent && this.disabled) {\n // Stop event from bubbling up\n // Kill the event loop attached to this specific `EventTarget`\n // Needed to prevent `vue-router` for doing its thing\n stopEvent(event, {\n immediatePropagation: true\n });\n } else {\n // Router links do not emit instance `click` events, so we\n // add in an `$emit('click', event)` on its Vue instance\n //\n // seems not to be required for Vue3 compat build\n\n /* istanbul ignore next: difficult to test, but we know it works */\n if (isRouterLink) {\n var _event$currentTarget$;\n\n (_event$currentTarget$ = event.currentTarget.__vue__) === null || _event$currentTarget$ === void 0 ? void 0 : _event$currentTarget$.$emit(EVENT_NAME_CLICK, event);\n } // Call the suppliedHandler(s), if any provided\n\n\n concat(suppliedHandler).filter(function (h) {\n return isFunction$1(h);\n }).forEach(function (handler) {\n handler.apply(void 0, _toConsumableArray$1(_arguments));\n }); // Emit the global `$root` click event\n\n this.emitOnRoot(ROOT_EVENT_NAME_CLICKED, event); // TODO: Remove deprecated 'clicked::link' event with next major release\n\n this.emitOnRoot('clicked::link', event);\n } // Stop scroll-to-top behavior or navigation on\n // regular links when href is just '#'\n\n\n if (eventIsEvent && !isRouterLink && this.computedHref === '#') {\n stopEvent(event, {\n propagation: false\n });\n }\n },\n focus: function focus() {\n attemptFocus(this.$el);\n },\n blur: function blur() {\n attemptBlur(this.$el);\n }\n },\n render: function render(h) {\n var active = this.active,\n disabled = this.disabled;\n return h(this.computedTag, _defineProperty({\n class: {\n active: active,\n disabled: disabled\n },\n attrs: this.computedAttrs,\n props: this.computedProps\n }, this.isRouterLink ? 'nativeOn' : 'on', this.computedListeners), this.normalizeSlot());\n }\n });\n\n var linkProps$7 = omit(props$2f, ['event', 'routerTag']);\n delete linkProps$7.href.default;\n delete linkProps$7.to.default;\n var props$2e = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, linkProps$7), {}, {\n block: makeProp(PROP_TYPE_BOOLEAN, false),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n pill: makeProp(PROP_TYPE_BOOLEAN, false),\n // Tri-state: `true`, `false` or `null`\n // => On, off, not a toggle\n pressed: makeProp(PROP_TYPE_BOOLEAN, null),\n size: makeProp(PROP_TYPE_STRING),\n squared: makeProp(PROP_TYPE_BOOLEAN, false),\n tag: makeProp(PROP_TYPE_STRING, 'button'),\n type: makeProp(PROP_TYPE_STRING, 'button'),\n variant: makeProp(PROP_TYPE_STRING, 'secondary')\n })), NAME_BUTTON); // --- Helper methods ---\n // Focus handler for toggle buttons\n // Needs class of 'focus' when focused\n\n var handleFocus = function handleFocus(event) {\n if (event.type === 'focusin') {\n addClass(event.target, 'focus');\n } else if (event.type === 'focusout') {\n removeClass(event.target, 'focus');\n }\n }; // Is the requested button a link?\n // If tag prop is set to `a`, we use a to get proper disabled handling\n\n\n var isLink = function isLink(props) {\n return isLink$1(props) || isTag(props.tag, 'a');\n }; // Is the button to be a toggle button?\n\n\n var isToggle = function isToggle(props) {\n return isBoolean(props.pressed);\n }; // Is the button \"really\" a button?\n\n\n var isButton = function isButton(props) {\n return !(isLink(props) || props.tag && !isTag(props.tag, 'button'));\n }; // Is the requested tag not a button or link?\n\n\n var isNonStandardTag$1 = function isNonStandardTag(props) {\n return !isLink(props) && !isButton(props);\n }; // Compute required classes (non static classes)\n\n\n var computeClass = function computeClass(props) {\n var _ref;\n\n return [\"btn-\".concat(props.variant || 'secondary'), (_ref = {}, _defineProperty(_ref, \"btn-\".concat(props.size), props.size), _defineProperty(_ref, 'btn-block', props.block), _defineProperty(_ref, 'rounded-pill', props.pill), _defineProperty(_ref, 'rounded-0', props.squared && !props.pill), _defineProperty(_ref, \"disabled\", props.disabled), _defineProperty(_ref, \"active\", props.pressed), _ref)];\n }; // Compute the link props to pass to b-link (if required)\n\n\n var computeLinkProps = function computeLinkProps(props) {\n return isLink(props) ? pluckProps(linkProps$7, props) : {};\n }; // Compute the attributes for a button\n\n\n var computeAttrs = function computeAttrs(props, data) {\n var button = isButton(props);\n var link = isLink(props);\n var toggle = isToggle(props);\n var nonStandardTag = isNonStandardTag$1(props);\n var hashLink = link && props.href === '#';\n var role = data.attrs && data.attrs.role ? data.attrs.role : null;\n var tabindex = data.attrs ? data.attrs.tabindex : null;\n\n if (nonStandardTag || hashLink) {\n tabindex = '0';\n }\n\n return {\n // Type only used for \"real\" buttons\n type: button && !link ? props.type : null,\n // Disabled only set on \"real\" buttons\n disabled: button ? props.disabled : null,\n // We add a role of button when the tag is not a link or button for ARIA\n // Don't bork any role provided in `data.attrs` when `isLink` or `isButton`\n // Except when link has `href` of `#`\n role: nonStandardTag || hashLink ? 'button' : role,\n // We set the `aria-disabled` state for non-standard tags\n 'aria-disabled': nonStandardTag ? String(props.disabled) : null,\n // For toggles, we need to set the pressed state for ARIA\n 'aria-pressed': toggle ? String(props.pressed) : null,\n // `autocomplete=\"off\"` is needed in toggle mode to prevent some browsers\n // from remembering the previous setting when using the back button\n autocomplete: toggle ? 'off' : null,\n // `tabindex` is used when the component is not a button\n // Links are tabbable, but don't allow disabled, while non buttons or links\n // are not tabbable, so we mimic that functionality by disabling tabbing\n // when disabled, and adding a `tabindex=\"0\"` to non buttons or non links\n tabindex: props.disabled && !button ? '-1' : tabindex\n };\n }; // --- Main component ---\n // @vue/component\n\n\n var BButton = /*#__PURE__*/extend({\n name: NAME_BUTTON,\n functional: true,\n props: props$2e,\n render: function render(h, _ref2) {\n var props = _ref2.props,\n data = _ref2.data,\n listeners = _ref2.listeners,\n children = _ref2.children;\n var toggle = isToggle(props);\n var link = isLink(props);\n var nonStandardTag = isNonStandardTag$1(props);\n var hashLink = link && props.href === '#';\n var on = {\n keydown: function keydown(event) {\n // When the link is a `href=\"#\"` or a non-standard tag (has `role=\"button\"`),\n // we add a keydown handlers for CODE_SPACE/CODE_ENTER\n\n /* istanbul ignore next */\n if (props.disabled || !(nonStandardTag || hashLink)) {\n return;\n }\n\n var keyCode = event.keyCode; // Add CODE_SPACE handler for `href=\"#\"` and CODE_ENTER handler for non-standard tags\n\n if (keyCode === CODE_SPACE || keyCode === CODE_ENTER && nonStandardTag) {\n var target = event.currentTarget || event.target;\n stopEvent(event, {\n propagation: false\n });\n target.click();\n }\n },\n click: function click(event) {\n /* istanbul ignore if: blink/button disabled should handle this */\n if (props.disabled && isEvent(event)) {\n stopEvent(event);\n } else if (toggle && listeners && listeners['update:pressed']) {\n // Send `.sync` updates to any \"pressed\" prop (if `.sync` listeners)\n // `concat()` will normalize the value to an array without\n // double wrapping an array value in an array\n concat(listeners['update:pressed']).forEach(function (fn) {\n if (isFunction$1(fn)) {\n fn(!props.pressed);\n }\n });\n }\n }\n };\n\n if (toggle) {\n on.focusin = handleFocus;\n on.focusout = handleFocus;\n }\n\n var componentData = {\n staticClass: 'btn',\n class: computeClass(props),\n props: computeLinkProps(props),\n attrs: computeAttrs(props, data),\n on: on\n };\n return h(link ? BLink : props.tag, a(_objectSpread2$3(_objectSpread2$3({}, data), {}, {\n props: undefined\n }), componentData), children);\n }\n });\n\n var CLASS_NAME$2 = 'b-avatar';\n var SIZES = ['sm', null, 'lg'];\n var FONT_SIZE_SCALE = 0.4;\n var BADGE_FONT_SIZE_SCALE = FONT_SIZE_SCALE * 0.7; // --- Helper methods ---\n\n var computeSize = function computeSize(value) {\n // Parse to number when value is a float-like string\n value = isString(value) && isNumeric$1(value) ? toFloat(value, 0) : value; // Convert all numbers to pixel values\n\n return isNumber(value) ? \"\".concat(value, \"px\") : value || null;\n }; // --- Props ---\n\n var linkProps$6 = omit(props$2f, ['active', 'event', 'routerTag']);\n var props$2d = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, linkProps$6), {}, {\n alt: makeProp(PROP_TYPE_STRING, 'avatar'),\n ariaLabel: makeProp(PROP_TYPE_STRING),\n badge: makeProp(PROP_TYPE_BOOLEAN_STRING, false),\n badgeLeft: makeProp(PROP_TYPE_BOOLEAN, false),\n badgeOffset: makeProp(PROP_TYPE_STRING),\n badgeTop: makeProp(PROP_TYPE_BOOLEAN, false),\n badgeVariant: makeProp(PROP_TYPE_STRING, 'primary'),\n button: makeProp(PROP_TYPE_BOOLEAN, false),\n buttonType: makeProp(PROP_TYPE_STRING, 'button'),\n icon: makeProp(PROP_TYPE_STRING),\n rounded: makeProp(PROP_TYPE_BOOLEAN_STRING, false),\n size: makeProp(PROP_TYPE_NUMBER_STRING),\n square: makeProp(PROP_TYPE_BOOLEAN, false),\n src: makeProp(PROP_TYPE_STRING),\n text: makeProp(PROP_TYPE_STRING),\n variant: makeProp(PROP_TYPE_STRING, 'secondary')\n })), NAME_AVATAR); // --- Main component ---\n // @vue/component\n\n var BAvatar = /*#__PURE__*/extend({\n name: NAME_AVATAR,\n mixins: [normalizeSlotMixin],\n inject: {\n getBvAvatarGroup: {\n default: function _default() {\n return function () {\n return null;\n };\n }\n }\n },\n props: props$2d,\n data: function data() {\n return {\n localSrc: this.src || null\n };\n },\n computed: {\n bvAvatarGroup: function bvAvatarGroup() {\n return this.getBvAvatarGroup();\n },\n computedSize: function computedSize() {\n // Always use the avatar group size\n var bvAvatarGroup = this.bvAvatarGroup;\n return computeSize(bvAvatarGroup ? bvAvatarGroup.size : this.size);\n },\n computedVariant: function computedVariant() {\n var bvAvatarGroup = this.bvAvatarGroup;\n return bvAvatarGroup && bvAvatarGroup.variant ? bvAvatarGroup.variant : this.variant;\n },\n computedRounded: function computedRounded() {\n var bvAvatarGroup = this.bvAvatarGroup;\n var square = bvAvatarGroup && bvAvatarGroup.square ? true : this.square;\n var rounded = bvAvatarGroup && bvAvatarGroup.rounded ? bvAvatarGroup.rounded : this.rounded;\n return square ? '0' : rounded === '' ? true : rounded || 'circle';\n },\n fontStyle: function fontStyle() {\n var size = this.computedSize;\n var fontSize = SIZES.indexOf(size) === -1 ? \"calc(\".concat(size, \" * \").concat(FONT_SIZE_SCALE, \")\") : null;\n return fontSize ? {\n fontSize: fontSize\n } : {};\n },\n marginStyle: function marginStyle() {\n var size = this.computedSize,\n bvAvatarGroup = this.bvAvatarGroup;\n var overlapScale = bvAvatarGroup ? bvAvatarGroup.overlapScale : 0;\n var value = size && overlapScale ? \"calc(\".concat(size, \" * -\").concat(overlapScale, \")\") : null;\n return value ? {\n marginLeft: value,\n marginRight: value\n } : {};\n },\n badgeStyle: function badgeStyle() {\n var size = this.computedSize,\n badgeTop = this.badgeTop,\n badgeLeft = this.badgeLeft,\n badgeOffset = this.badgeOffset;\n var offset = badgeOffset || '0px';\n return {\n fontSize: SIZES.indexOf(size) === -1 ? \"calc(\".concat(size, \" * \").concat(BADGE_FONT_SIZE_SCALE, \" )\") : null,\n top: badgeTop ? offset : null,\n bottom: badgeTop ? null : offset,\n left: badgeLeft ? offset : null,\n right: badgeLeft ? null : offset\n };\n }\n },\n watch: {\n src: function src(newValue, oldValue) {\n if (newValue !== oldValue) {\n this.localSrc = newValue || null;\n }\n }\n },\n methods: {\n onImgError: function onImgError(event) {\n this.localSrc = null;\n this.$emit(EVENT_NAME_IMG_ERROR, event);\n },\n onClick: function onClick(event) {\n this.$emit(EVENT_NAME_CLICK, event);\n }\n },\n render: function render(h) {\n var _class2;\n\n var variant = this.computedVariant,\n disabled = this.disabled,\n rounded = this.computedRounded,\n icon = this.icon,\n src = this.localSrc,\n text = this.text,\n fontStyle = this.fontStyle,\n marginStyle = this.marginStyle,\n size = this.computedSize,\n button = this.button,\n type = this.buttonType,\n badge = this.badge,\n badgeVariant = this.badgeVariant,\n badgeStyle = this.badgeStyle;\n var link = !button && isLink$1(this);\n var tag = button ? BButton : link ? BLink : 'span';\n var alt = this.alt;\n var ariaLabel = this.ariaLabel || null;\n var $content = null;\n\n if (this.hasNormalizedSlot()) {\n // Default slot overrides props\n $content = h('span', {\n staticClass: 'b-avatar-custom'\n }, [this.normalizeSlot()]);\n } else if (src) {\n $content = h('img', {\n style: variant ? {} : {\n width: '100%',\n height: '100%'\n },\n attrs: {\n src: src,\n alt: alt\n },\n on: {\n error: this.onImgError\n }\n });\n $content = h('span', {\n staticClass: 'b-avatar-img'\n }, [$content]);\n } else if (icon) {\n $content = h(BIcon, {\n props: {\n icon: icon\n },\n attrs: {\n 'aria-hidden': 'true',\n alt: alt\n }\n });\n } else if (text) {\n $content = h('span', {\n staticClass: 'b-avatar-text',\n style: fontStyle\n }, [h('span', text)]);\n } else {\n // Fallback default avatar content\n $content = h(BIconPersonFill, {\n attrs: {\n 'aria-hidden': 'true',\n alt: alt\n }\n });\n }\n\n var $badge = h();\n var hasBadgeSlot = this.hasNormalizedSlot(SLOT_NAME_BADGE);\n\n if (badge || badge === '' || hasBadgeSlot) {\n var badgeText = badge === true ? '' : badge;\n $badge = h('span', {\n staticClass: 'b-avatar-badge',\n class: _defineProperty({}, \"badge-\".concat(badgeVariant), badgeVariant),\n style: badgeStyle\n }, [hasBadgeSlot ? this.normalizeSlot(SLOT_NAME_BADGE) : badgeText]);\n }\n\n var componentData = {\n staticClass: CLASS_NAME$2,\n class: (_class2 = {}, _defineProperty(_class2, \"\".concat(CLASS_NAME$2, \"-\").concat(size), size && SIZES.indexOf(size) !== -1), _defineProperty(_class2, \"badge-\".concat(variant), !button && variant), _defineProperty(_class2, \"rounded\", rounded === true), _defineProperty(_class2, \"rounded-\".concat(rounded), rounded && rounded !== true), _defineProperty(_class2, \"disabled\", disabled), _class2),\n style: _objectSpread2$3(_objectSpread2$3({}, marginStyle), {}, {\n width: size,\n height: size\n }),\n attrs: {\n 'aria-label': ariaLabel || null\n },\n props: button ? {\n variant: variant,\n disabled: disabled,\n type: type\n } : link ? pluckProps(linkProps$6, this) : {},\n on: button || link ? {\n click: this.onClick\n } : {}\n };\n return h(tag, componentData, [$content, $badge]);\n }\n });\n\n var props$2c = makePropsConfigurable({\n overlap: makeProp(PROP_TYPE_NUMBER_STRING, 0.3),\n // Child avatars will prefer this prop (if set) over their own\n rounded: makeProp(PROP_TYPE_BOOLEAN_STRING, false),\n // Child avatars will always use this over their own size\n size: makeProp(PROP_TYPE_STRING),\n // Child avatars will prefer this prop (if set) over their own\n square: makeProp(PROP_TYPE_BOOLEAN, false),\n tag: makeProp(PROP_TYPE_STRING, 'div'),\n // Child avatars will prefer this variant over their own\n variant: makeProp(PROP_TYPE_STRING)\n }, NAME_AVATAR_GROUP); // --- Main component ---\n // @vue/component\n\n var BAvatarGroup = /*#__PURE__*/extend({\n name: NAME_AVATAR_GROUP,\n mixins: [normalizeSlotMixin],\n provide: function provide() {\n var _this = this;\n\n return {\n getBvAvatarGroup: function getBvAvatarGroup() {\n return _this;\n }\n };\n },\n props: props$2c,\n computed: {\n computedSize: function computedSize() {\n return computeSize(this.size);\n },\n overlapScale: function overlapScale() {\n return mathMin(mathMax(toFloat(this.overlap, 0), 0), 1) / 2;\n },\n paddingStyle: function paddingStyle() {\n var value = this.computedSize;\n value = value ? \"calc(\".concat(value, \" * \").concat(this.overlapScale, \")\") : null;\n return value ? {\n paddingLeft: value,\n paddingRight: value\n } : {};\n }\n },\n render: function render(h) {\n var $inner = h('div', {\n staticClass: 'b-avatar-group-inner',\n style: this.paddingStyle\n }, this.normalizeSlot());\n return h(this.tag, {\n staticClass: 'b-avatar-group',\n attrs: {\n role: 'group'\n }\n }, [$inner]);\n }\n });\n\n var AvatarPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BAvatar: BAvatar,\n BAvatarGroup: BAvatarGroup\n }\n });\n\n var linkProps$5 = omit(props$2f, ['event', 'routerTag']);\n delete linkProps$5.href.default;\n delete linkProps$5.to.default;\n var props$2b = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, linkProps$5), {}, {\n pill: makeProp(PROP_TYPE_BOOLEAN, false),\n tag: makeProp(PROP_TYPE_STRING, 'span'),\n variant: makeProp(PROP_TYPE_STRING, 'secondary')\n })), NAME_BADGE); // --- Main component ---\n // @vue/component\n\n var BBadge = /*#__PURE__*/extend({\n name: NAME_BADGE,\n functional: true,\n props: props$2b,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var active = props.active,\n disabled = props.disabled;\n var link = isLink$1(props);\n var tag = link ? BLink : props.tag;\n var variant = props.variant || 'secondary';\n return h(tag, a(data, {\n staticClass: 'badge',\n class: [\"badge-\".concat(variant), {\n 'badge-pill': props.pill,\n active: active,\n disabled: disabled\n }],\n props: link ? pluckProps(linkProps$5, props) : {}\n }), children);\n }\n });\n\n var BadgePlugin = /*#__PURE__*/pluginFactory({\n components: {\n BBadge: BBadge\n }\n });\n\n var stripTags = function stripTags() {\n var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n return String(text).replace(RX_HTML_TAGS, '');\n }; // Generate a `domProps` object for either `innerHTML`, `textContent` or an empty object\n\n var htmlOrText = function htmlOrText(innerHTML, textContent) {\n return innerHTML ? {\n innerHTML: innerHTML\n } : textContent ? {\n textContent: textContent\n } : {};\n };\n\n var props$2a = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, omit(props$2f, ['event', 'routerTag'])), {}, {\n ariaCurrent: makeProp(PROP_TYPE_STRING, 'location'),\n html: makeProp(PROP_TYPE_STRING),\n text: makeProp(PROP_TYPE_STRING)\n })), NAME_BREADCRUMB_LINK); // --- Main component ---\n // @vue/component\n\n var BBreadcrumbLink = /*#__PURE__*/extend({\n name: NAME_BREADCRUMB_LINK,\n functional: true,\n props: props$2a,\n render: function render(h, _ref) {\n var suppliedProps = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var active = suppliedProps.active;\n var tag = active ? 'span' : BLink;\n var componentData = {\n attrs: {\n 'aria-current': active ? suppliedProps.ariaCurrent : null\n },\n props: pluckProps(props$2a, suppliedProps)\n };\n\n if (!children) {\n componentData.domProps = htmlOrText(suppliedProps.html, suppliedProps.text);\n }\n\n return h(tag, a(data, componentData), children);\n }\n });\n\n var props$29 = makePropsConfigurable(props$2a, NAME_BREADCRUMB_ITEM); // --- Main component ---\n // @vue/component\n\n var BBreadcrumbItem = /*#__PURE__*/extend({\n name: NAME_BREADCRUMB_ITEM,\n functional: true,\n props: props$29,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h('li', a(data, {\n staticClass: 'breadcrumb-item',\n class: {\n active: props.active\n }\n }), [h(BBreadcrumbLink, {\n props: props\n }, children)]);\n }\n });\n\n var props$28 = makePropsConfigurable({\n items: makeProp(PROP_TYPE_ARRAY)\n }, NAME_BREADCRUMB); // --- Main component ---\n // @vue/component\n\n var BBreadcrumb = /*#__PURE__*/extend({\n name: NAME_BREADCRUMB,\n functional: true,\n props: props$28,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var items = props.items; // Build child nodes from items, if given\n\n var childNodes = children;\n\n if (isArray(items)) {\n var activeDefined = false;\n childNodes = items.map(function (item, idx) {\n if (!isObject(item)) {\n item = {\n text: toString(item)\n };\n } // Copy the value here so we can normalize it\n\n\n var _item = item,\n active = _item.active;\n\n if (active) {\n activeDefined = true;\n } // Auto-detect active by position in list\n\n\n if (!active && !activeDefined) {\n active = idx + 1 === items.length;\n }\n\n return h(BBreadcrumbItem, {\n props: _objectSpread2$3(_objectSpread2$3({}, item), {}, {\n active: active\n })\n });\n });\n }\n\n return h('ol', a(data, {\n staticClass: 'breadcrumb'\n }), childNodes);\n }\n });\n\n var BreadcrumbPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BBreadcrumb: BBreadcrumb,\n BBreadcrumbItem: BBreadcrumbItem,\n BBreadcrumbLink: BBreadcrumbLink\n }\n });\n\n var ButtonPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BButton: BButton,\n BBtn: BButton,\n BButtonClose: BButtonClose,\n BBtnClose: BButtonClose\n }\n });\n\n var props$27 = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, pick$1(props$2e, ['size'])), {}, {\n ariaRole: makeProp(PROP_TYPE_STRING, 'group'),\n size: makeProp(PROP_TYPE_STRING),\n tag: makeProp(PROP_TYPE_STRING, 'div'),\n vertical: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_BUTTON_GROUP); // --- Main component ---\n // @vue/component\n\n var BButtonGroup = /*#__PURE__*/extend({\n name: NAME_BUTTON_GROUP,\n functional: true,\n props: props$27,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h(props.tag, a(data, {\n class: _defineProperty({\n 'btn-group': !props.vertical,\n 'btn-group-vertical': props.vertical\n }, \"btn-group-\".concat(props.size), props.size),\n attrs: {\n role: props.ariaRole\n }\n }), children);\n }\n });\n\n var ButtonGroupPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BButtonGroup: BButtonGroup,\n BBtnGroup: BButtonGroup\n }\n });\n\n var ITEM_SELECTOR = ['.btn:not(.disabled):not([disabled]):not(.dropdown-item)', '.form-control:not(.disabled):not([disabled])', 'select:not(.disabled):not([disabled])', 'input[type=\"checkbox\"]:not(.disabled)', 'input[type=\"radio\"]:not(.disabled)'].join(','); // --- Props ---\n\n var props$26 = makePropsConfigurable({\n justify: makeProp(PROP_TYPE_BOOLEAN, false),\n keyNav: makeProp(PROP_TYPE_BOOLEAN, false)\n }, NAME_BUTTON_TOOLBAR); // --- Main component ---\n // @vue/component\n\n var BButtonToolbar = /*#__PURE__*/extend({\n name: NAME_BUTTON_TOOLBAR,\n mixins: [normalizeSlotMixin],\n props: props$26,\n mounted: function mounted() {\n // Pre-set the tabindexes if the markup does not include\n // `tabindex=\"-1\"` on the toolbar items\n if (this.keyNav) {\n this.getItems();\n }\n },\n methods: {\n getItems: function getItems() {\n var items = selectAll(ITEM_SELECTOR, this.$el); // Ensure `tabindex=\"-1\"` is set on every item\n\n items.forEach(function (item) {\n item.tabIndex = -1;\n });\n return items.filter(function (el) {\n return isVisible(el);\n });\n },\n focusFirst: function focusFirst() {\n var items = this.getItems();\n attemptFocus(items[0]);\n },\n focusPrev: function focusPrev(event) {\n var items = this.getItems();\n var index = items.indexOf(event.target);\n\n if (index > -1) {\n items = items.slice(0, index).reverse();\n attemptFocus(items[0]);\n }\n },\n focusNext: function focusNext(event) {\n var items = this.getItems();\n var index = items.indexOf(event.target);\n\n if (index > -1) {\n items = items.slice(index + 1);\n attemptFocus(items[0]);\n }\n },\n focusLast: function focusLast() {\n var items = this.getItems().reverse();\n attemptFocus(items[0]);\n },\n onFocusin: function onFocusin(event) {\n var $el = this.$el;\n\n if (event.target === $el && !contains($el, event.relatedTarget)) {\n stopEvent(event);\n this.focusFirst(event);\n }\n },\n onKeydown: function onKeydown(event) {\n var keyCode = event.keyCode,\n shiftKey = event.shiftKey;\n\n if (keyCode === CODE_UP || keyCode === CODE_LEFT) {\n stopEvent(event);\n shiftKey ? this.focusFirst(event) : this.focusPrev(event);\n } else if (keyCode === CODE_DOWN || keyCode === CODE_RIGHT) {\n stopEvent(event);\n shiftKey ? this.focusLast(event) : this.focusNext(event);\n }\n }\n },\n render: function render(h) {\n var keyNav = this.keyNav;\n return h('div', {\n staticClass: 'btn-toolbar',\n class: {\n 'justify-content-between': this.justify\n },\n attrs: {\n role: 'toolbar',\n tabindex: keyNav ? '0' : null\n },\n on: keyNav ? {\n focusin: this.onFocusin,\n keydown: this.onKeydown\n } : {}\n }, [this.normalizeSlot()]);\n }\n });\n\n var ButtonToolbarPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BButtonToolbar: BButtonToolbar,\n BBtnToolbar: BButtonToolbar\n }\n });\n\n var CALENDAR_GREGORY = 'gregory';\n var CALENDAR_LONG = 'long';\n var CALENDAR_NARROW = 'narrow';\n var CALENDAR_SHORT = 'short';\n var DATE_FORMAT_2_DIGIT = '2-digit';\n var DATE_FORMAT_NUMERIC = 'numeric';\n\n // Create or clone a date (`new Date(...)` shortcut)\n\n var createDate = function createDate() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _construct(Date, args);\n }; // Parse a date sting, or Date object, into a Date object (with no time information)\n\n var parseYMD = function parseYMD(date) {\n if (isString(date) && RX_DATE.test(date.trim())) {\n var _date$split$map = date.split(RX_DATE_SPLIT).map(function (v) {\n return toInteger(v, 1);\n }),\n _date$split$map2 = _slicedToArray(_date$split$map, 3),\n year = _date$split$map2[0],\n month = _date$split$map2[1],\n day = _date$split$map2[2];\n\n return createDate(year, month - 1, day);\n } else if (isDate(date)) {\n return createDate(date.getFullYear(), date.getMonth(), date.getDate());\n }\n\n return null;\n }; // Format a date object as `YYYY-MM-DD` format\n\n var formatYMD = function formatYMD(date) {\n date = parseYMD(date);\n\n if (!date) {\n return null;\n }\n\n var year = date.getFullYear();\n var month = \"0\".concat(date.getMonth() + 1).slice(-2);\n var day = \"0\".concat(date.getDate()).slice(-2);\n return \"\".concat(year, \"-\").concat(month, \"-\").concat(day);\n }; // Given a locale (or locales), resolve the browser available locale\n\n var resolveLocale = function resolveLocale(locales)\n /* istanbul ignore next */\n {\n var calendar = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : CALENDAR_GREGORY;\n locales = concat(locales).filter(identity);\n var fmt = new Intl.DateTimeFormat(locales, {\n calendar: calendar\n });\n return fmt.resolvedOptions().locale;\n }; // Create a `Intl.DateTimeFormat` formatter function\n\n var createDateFormatter = function createDateFormatter(locale, options)\n /* istanbul ignore next */\n {\n var dtf = new Intl.DateTimeFormat(locale, options);\n return dtf.format;\n }; // Determine if two dates are the same date (ignoring time portion)\n\n var datesEqual = function datesEqual(date1, date2) {\n // Returns true of the date portion of two date objects are equal\n // We don't compare the time portion\n return formatYMD(date1) === formatYMD(date2);\n }; // --- Date \"math\" utility methods (for BCalendar component mainly) ---\n\n var firstDateOfMonth = function firstDateOfMonth(date) {\n date = createDate(date);\n date.setDate(1);\n return date;\n };\n var lastDateOfMonth = function lastDateOfMonth(date) {\n date = createDate(date);\n date.setMonth(date.getMonth() + 1);\n date.setDate(0);\n return date;\n };\n var addYears = function addYears(date, numberOfYears) {\n date = createDate(date);\n var month = date.getMonth();\n date.setFullYear(date.getFullYear() + numberOfYears); // Handle Feb 29th for leap years\n\n if (date.getMonth() !== month) {\n date.setDate(0);\n }\n\n return date;\n };\n var oneMonthAgo = function oneMonthAgo(date) {\n date = createDate(date);\n var month = date.getMonth();\n date.setMonth(month - 1); // Handle when days in month are different\n\n if (date.getMonth() === month) {\n date.setDate(0);\n }\n\n return date;\n };\n var oneMonthAhead = function oneMonthAhead(date) {\n date = createDate(date);\n var month = date.getMonth();\n date.setMonth(month + 1); // Handle when days in month are different\n\n if (date.getMonth() === (month + 2) % 12) {\n date.setDate(0);\n }\n\n return date;\n };\n var oneYearAgo = function oneYearAgo(date) {\n return addYears(date, -1);\n };\n var oneYearAhead = function oneYearAhead(date) {\n return addYears(date, 1);\n };\n var oneDecadeAgo = function oneDecadeAgo(date) {\n return addYears(date, -10);\n };\n var oneDecadeAhead = function oneDecadeAhead(date) {\n return addYears(date, 10);\n }; // Helper function to constrain a date between two values\n // Always returns a `Date` object or `null` if no date passed\n\n var constrainDate = function constrainDate(date) {\n var min = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n var max = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n // Ensure values are `Date` objects (or `null`)\n date = parseYMD(date);\n min = parseYMD(min) || date;\n max = parseYMD(max) || date; // Return a new `Date` object (or `null`)\n\n return date ? date < min ? min : date > max ? max : date : null;\n };\n\n // Localization utilities\n\n var RTL_LANGS = ['ar', 'az', 'ckb', 'fa', 'he', 'ks', 'lrc', 'mzn', 'ps', 'sd', 'te', 'ug', 'ur', 'yi'].map(function (locale) {\n return locale.toLowerCase();\n }); // Returns true if the locale is RTL\n\n var isLocaleRTL = function isLocaleRTL(locale) {\n // Determines if the locale is RTL (only single locale supported)\n var parts = toString(locale).toLowerCase().replace(RX_STRIP_LOCALE_MODS, '').split('-');\n var locale1 = parts.slice(0, 2).join('-');\n var locale2 = parts[0];\n return arrayIncludes(RTL_LANGS, locale1) || arrayIncludes(RTL_LANGS, locale2);\n };\n\n // SSR safe client-side ID attribute generation\n\n var props$25 = {\n id: makeProp(PROP_TYPE_STRING)\n }; // --- Mixin ---\n // @vue/component\n\n var idMixin = extend({\n props: props$25,\n data: function data() {\n return {\n localId_: null\n };\n },\n computed: {\n safeId: function safeId() {\n // Computed property that returns a dynamic function for creating the ID\n // Reacts to changes in both `.id` and `.localId_` and regenerates a new function\n var id = this.id || this.localId_; // We return a function that accepts an optional suffix string\n // So this computed prop looks and works like a method\n // but benefits from Vue's computed prop caching\n\n var fn = function fn(suffix) {\n if (!id) {\n return null;\n }\n\n suffix = String(suffix || '').replace(/\\s+/g, '_');\n return suffix ? id + '_' + suffix : id;\n };\n\n return fn;\n }\n },\n mounted: function mounted() {\n var _this = this;\n\n // `mounted()` only occurs client-side\n this.$nextTick(function () {\n // Update DOM with auto-generated ID after mount\n // to prevent SSR hydration errors\n _this.localId_ = \"__BVID__\".concat(_this[COMPONENT_UID_KEY]);\n });\n }\n });\n\n var _watch$j;\n\n var _makeModelMixin$j = makeModelMixin('value', {\n type: PROP_TYPE_DATE_STRING\n }),\n modelMixin$i = _makeModelMixin$j.mixin,\n modelProps$i = _makeModelMixin$j.props,\n MODEL_PROP_NAME$i = _makeModelMixin$j.prop,\n MODEL_EVENT_NAME$i = _makeModelMixin$j.event; // --- Props ---\n\n\n var props$24 = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$25), modelProps$i), {}, {\n ariaControls: makeProp(PROP_TYPE_STRING),\n // Makes calendar the full width of its parent container\n block: makeProp(PROP_TYPE_BOOLEAN, false),\n dateDisabledFn: makeProp(PROP_TYPE_FUNCTION),\n // `Intl.DateTimeFormat` object\n dateFormatOptions: makeProp(PROP_TYPE_OBJECT, {\n year: DATE_FORMAT_NUMERIC,\n month: CALENDAR_LONG,\n day: DATE_FORMAT_NUMERIC,\n weekday: CALENDAR_LONG\n }),\n // Function to set a class of (classes) on the date cell\n // if passed a string or an array\n // TODO:\n // If the function returns an object, look for class prop for classes,\n // and other props for handling events/details/descriptions\n dateInfoFn: makeProp(PROP_TYPE_FUNCTION),\n // 'ltr', 'rtl', or `null` (for auto detect)\n direction: makeProp(PROP_TYPE_STRING),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n headerTag: makeProp(PROP_TYPE_STRING, 'header'),\n // When `true`, renders a comment node, but keeps the component instance active\n // Mainly for , so that we can get the component's value and locale\n // But we might just use separate date formatters, using the resolved locale\n // (adjusted for the gregorian calendar)\n hidden: makeProp(PROP_TYPE_BOOLEAN, false),\n // When `true` makes the selected date header `sr-only`\n hideHeader: makeProp(PROP_TYPE_BOOLEAN, false),\n // This specifies the calendar year/month/day that will be shown when\n // first opening the datepicker if no v-model value is provided\n // Default is the current date (or `min`/`max`)\n initialDate: makeProp(PROP_TYPE_DATE_STRING),\n // Labels for buttons and keyboard shortcuts\n labelCalendar: makeProp(PROP_TYPE_STRING, 'Calendar'),\n labelCurrentMonth: makeProp(PROP_TYPE_STRING, 'Current month'),\n labelHelp: makeProp(PROP_TYPE_STRING, 'Use cursor keys to navigate calendar dates'),\n labelNav: makeProp(PROP_TYPE_STRING, 'Calendar navigation'),\n labelNextDecade: makeProp(PROP_TYPE_STRING, 'Next decade'),\n labelNextMonth: makeProp(PROP_TYPE_STRING, 'Next month'),\n labelNextYear: makeProp(PROP_TYPE_STRING, 'Next year'),\n labelNoDateSelected: makeProp(PROP_TYPE_STRING, 'No date selected'),\n labelPrevDecade: makeProp(PROP_TYPE_STRING, 'Previous decade'),\n labelPrevMonth: makeProp(PROP_TYPE_STRING, 'Previous month'),\n labelPrevYear: makeProp(PROP_TYPE_STRING, 'Previous year'),\n labelSelected: makeProp(PROP_TYPE_STRING, 'Selected date'),\n labelToday: makeProp(PROP_TYPE_STRING, 'Today'),\n // Locale(s) to use\n // Default is to use page/browser default setting\n locale: makeProp(PROP_TYPE_ARRAY_STRING),\n max: makeProp(PROP_TYPE_DATE_STRING),\n min: makeProp(PROP_TYPE_DATE_STRING),\n // Variant color to use for the navigation buttons\n navButtonVariant: makeProp(PROP_TYPE_STRING, 'secondary'),\n // Disable highlighting today's date\n noHighlightToday: makeProp(PROP_TYPE_BOOLEAN, false),\n noKeyNav: makeProp(PROP_TYPE_BOOLEAN, false),\n readonly: makeProp(PROP_TYPE_BOOLEAN, false),\n roleDescription: makeProp(PROP_TYPE_STRING),\n // Variant color to use for the selected date\n selectedVariant: makeProp(PROP_TYPE_STRING, 'primary'),\n // When `true` enables the decade navigation buttons\n showDecadeNav: makeProp(PROP_TYPE_BOOLEAN, false),\n // Day of week to start calendar on\n // `0` (Sunday), `1` (Monday), ... `6` (Saturday)\n startWeekday: makeProp(PROP_TYPE_NUMBER_STRING, 0),\n // Variant color to use for today's date (defaults to `selectedVariant`)\n todayVariant: makeProp(PROP_TYPE_STRING),\n // Always return the `v-model` value as a date object\n valueAsDate: makeProp(PROP_TYPE_BOOLEAN, false),\n // Format of the weekday names at the top of the calendar\n // `short` is typically a 3 letter abbreviation,\n // `narrow` is typically a single letter\n // `long` is the full week day name\n // Although some locales may override this (i.e `ar`, etc.)\n weekdayHeaderFormat: makeProp(PROP_TYPE_STRING, CALENDAR_SHORT, function (value) {\n return arrayIncludes([CALENDAR_LONG, CALENDAR_SHORT, CALENDAR_NARROW], value);\n }),\n // Has no effect if prop `block` is set\n width: makeProp(PROP_TYPE_STRING, '270px')\n })), NAME_CALENDAR); // --- Main component ---\n // @vue/component\n\n var BCalendar = extend({\n name: NAME_CALENDAR,\n // Mixin order is important!\n mixins: [attrsMixin, idMixin, modelMixin$i, normalizeSlotMixin],\n props: props$24,\n data: function data() {\n var selected = formatYMD(this[MODEL_PROP_NAME$i]) || '';\n return {\n // Selected date\n selectedYMD: selected,\n // Date in calendar grid that has `tabindex` of `0`\n activeYMD: selected || formatYMD(constrainDate(this.initialDate || this.getToday()), this.min, this.max),\n // Will be true if the calendar grid has/contains focus\n gridHasFocus: false,\n // Flag to enable the `aria-live` region(s) after mount\n // to prevent screen reader \"outbursts\" when mounting\n isLive: false\n };\n },\n computed: {\n valueId: function valueId() {\n return this.safeId();\n },\n widgetId: function widgetId() {\n return this.safeId('_calendar-wrapper_');\n },\n navId: function navId() {\n return this.safeId('_calendar-nav_');\n },\n gridId: function gridId() {\n return this.safeId('_calendar-grid_');\n },\n gridCaptionId: function gridCaptionId() {\n return this.safeId('_calendar-grid-caption_');\n },\n gridHelpId: function gridHelpId() {\n return this.safeId('_calendar-grid-help_');\n },\n activeId: function activeId() {\n return this.activeYMD ? this.safeId(\"_cell-\".concat(this.activeYMD, \"_\")) : null;\n },\n // TODO: Use computed props to convert `YYYY-MM-DD` to `Date` object\n selectedDate: function selectedDate() {\n // Selected as a `Date` object\n return parseYMD(this.selectedYMD);\n },\n activeDate: function activeDate() {\n // Active as a `Date` object\n return parseYMD(this.activeYMD);\n },\n computedMin: function computedMin() {\n return parseYMD(this.min);\n },\n computedMax: function computedMax() {\n return parseYMD(this.max);\n },\n computedWeekStarts: function computedWeekStarts() {\n // `startWeekday` is a prop (constrained to `0` through `6`)\n return mathMax(toInteger(this.startWeekday, 0), 0) % 7;\n },\n computedLocale: function computedLocale() {\n // Returns the resolved locale used by the calendar\n return resolveLocale(concat(this.locale).filter(identity), CALENDAR_GREGORY);\n },\n computedDateDisabledFn: function computedDateDisabledFn() {\n var dateDisabledFn = this.dateDisabledFn;\n return hasPropFunction(dateDisabledFn) ? dateDisabledFn : function () {\n return false;\n };\n },\n // TODO: Change `dateInfoFn` to handle events and notes as well as classes\n computedDateInfoFn: function computedDateInfoFn() {\n var dateInfoFn = this.dateInfoFn;\n return hasPropFunction(dateInfoFn) ? dateInfoFn : function () {\n return {};\n };\n },\n calendarLocale: function calendarLocale() {\n // This locale enforces the gregorian calendar (for use in formatter functions)\n // Needed because IE 11 resolves `ar-IR` as islamic-civil calendar\n // and IE 11 (and some other browsers) do not support the `calendar` option\n // And we currently only support the gregorian calendar\n var fmt = new Intl.DateTimeFormat(this.computedLocale, {\n calendar: CALENDAR_GREGORY\n });\n var calendar = fmt.resolvedOptions().calendar;\n var locale = fmt.resolvedOptions().locale;\n /* istanbul ignore if: mainly for IE 11 and a few other browsers, hard to test in JSDOM */\n\n if (calendar !== CALENDAR_GREGORY) {\n // Ensure the locale requests the gregorian calendar\n // Mainly for IE 11, and currently we can't handle non-gregorian calendars\n // TODO: Should we always return this value?\n locale = locale.replace(/-u-.+$/i, '').concat('-u-ca-gregory');\n }\n\n return locale;\n },\n calendarYear: function calendarYear() {\n return this.activeDate.getFullYear();\n },\n calendarMonth: function calendarMonth() {\n return this.activeDate.getMonth();\n },\n calendarFirstDay: function calendarFirstDay() {\n // We set the time for this date to 12pm to work around\n // date formatting issues in Firefox and Safari\n // See: https://github.com/bootstrap-vue/bootstrap-vue/issues/5818\n return createDate(this.calendarYear, this.calendarMonth, 1, 12);\n },\n calendarDaysInMonth: function calendarDaysInMonth() {\n // We create a new date as to not mutate the original\n var date = createDate(this.calendarFirstDay);\n date.setMonth(date.getMonth() + 1, 0);\n return date.getDate();\n },\n computedVariant: function computedVariant() {\n return \"btn-\".concat(this.selectedVariant || 'primary');\n },\n computedTodayVariant: function computedTodayVariant() {\n return \"btn-outline-\".concat(this.todayVariant || this.selectedVariant || 'primary');\n },\n computedNavButtonVariant: function computedNavButtonVariant() {\n return \"btn-outline-\".concat(this.navButtonVariant || 'primary');\n },\n isRTL: function isRTL() {\n // `true` if the language requested is RTL\n var dir = toString(this.direction).toLowerCase();\n\n if (dir === 'rtl') {\n /* istanbul ignore next */\n return true;\n } else if (dir === 'ltr') {\n /* istanbul ignore next */\n return false;\n }\n\n return isLocaleRTL(this.computedLocale);\n },\n context: function context() {\n var selectedYMD = this.selectedYMD,\n activeYMD = this.activeYMD;\n var selectedDate = parseYMD(selectedYMD);\n var activeDate = parseYMD(activeYMD);\n return {\n // The current value of the `v-model`\n selectedYMD: selectedYMD,\n selectedDate: selectedDate,\n selectedFormatted: selectedDate ? this.formatDateString(selectedDate) : this.labelNoDateSelected,\n // Which date cell is considered active due to navigation\n activeYMD: activeYMD,\n activeDate: activeDate,\n activeFormatted: activeDate ? this.formatDateString(activeDate) : '',\n // `true` if the date is disabled (when using keyboard navigation)\n disabled: this.dateDisabled(activeDate),\n // Locales used in formatting dates\n locale: this.computedLocale,\n calendarLocale: this.calendarLocale,\n rtl: this.isRTL\n };\n },\n // Computed props that return a function reference\n dateOutOfRange: function dateOutOfRange() {\n // Check whether a date is within the min/max range\n // Returns a new function ref if the pops change\n // We do this as we need to trigger the calendar computed prop\n // to update when these props update\n var min = this.computedMin,\n max = this.computedMax;\n return function (date) {\n // Handle both `YYYY-MM-DD` and `Date` objects\n date = parseYMD(date);\n return min && date < min || max && date > max;\n };\n },\n dateDisabled: function dateDisabled() {\n var _this = this;\n\n // Returns a function for validating if a date is within range\n // We grab this variables first to ensure a new function ref\n // is generated when the props value changes\n // We do this as we need to trigger the calendar computed prop\n // to update when these props update\n var rangeFn = this.dateOutOfRange; // Return the function ref\n\n return function (date) {\n // Handle both `YYYY-MM-DD` and `Date` objects\n date = parseYMD(date);\n var ymd = formatYMD(date);\n return !!(rangeFn(date) || _this.computedDateDisabledFn(ymd, date));\n };\n },\n // Computed props that return date formatter functions\n formatDateString: function formatDateString() {\n // Returns a date formatter function\n return createDateFormatter(this.calendarLocale, _objectSpread2$3(_objectSpread2$3({\n // Ensure we have year, month, day shown for screen readers/ARIA\n // If users really want to leave one of these out, they can\n // pass `undefined` for the property value\n year: DATE_FORMAT_NUMERIC,\n month: DATE_FORMAT_2_DIGIT,\n day: DATE_FORMAT_2_DIGIT\n }, this.dateFormatOptions), {}, {\n // Ensure hours/minutes/seconds are not shown\n // As we do not support the time portion (yet)\n hour: undefined,\n minute: undefined,\n second: undefined,\n // Ensure calendar is gregorian\n calendar: CALENDAR_GREGORY\n }));\n },\n formatYearMonth: function formatYearMonth() {\n // Returns a date formatter function\n return createDateFormatter(this.calendarLocale, {\n year: DATE_FORMAT_NUMERIC,\n month: CALENDAR_LONG,\n calendar: CALENDAR_GREGORY\n });\n },\n formatWeekdayName: function formatWeekdayName() {\n // Long weekday name for weekday header aria-label\n return createDateFormatter(this.calendarLocale, {\n weekday: CALENDAR_LONG,\n calendar: CALENDAR_GREGORY\n });\n },\n formatWeekdayNameShort: function formatWeekdayNameShort() {\n // Weekday header cell format\n // defaults to 'short' 3 letter days, where possible\n return createDateFormatter(this.calendarLocale, {\n weekday: this.weekdayHeaderFormat || CALENDAR_SHORT,\n calendar: CALENDAR_GREGORY\n });\n },\n formatDay: function formatDay() {\n // Calendar grid day number formatter\n // We don't use DateTimeFormatter here as it can place extra\n // character(s) after the number (i.e the `zh` locale)\n var nf = new Intl.NumberFormat([this.computedLocale], {\n style: 'decimal',\n minimumIntegerDigits: 1,\n minimumFractionDigits: 0,\n maximumFractionDigits: 0,\n notation: 'standard'\n }); // Return a formatter function instance\n\n return function (date) {\n return nf.format(date.getDate());\n };\n },\n // Disabled states for the nav buttons\n prevDecadeDisabled: function prevDecadeDisabled() {\n var min = this.computedMin;\n return this.disabled || min && lastDateOfMonth(oneDecadeAgo(this.activeDate)) < min;\n },\n prevYearDisabled: function prevYearDisabled() {\n var min = this.computedMin;\n return this.disabled || min && lastDateOfMonth(oneYearAgo(this.activeDate)) < min;\n },\n prevMonthDisabled: function prevMonthDisabled() {\n var min = this.computedMin;\n return this.disabled || min && lastDateOfMonth(oneMonthAgo(this.activeDate)) < min;\n },\n thisMonthDisabled: function thisMonthDisabled() {\n // TODO: We could/should check if today is out of range\n return this.disabled;\n },\n nextMonthDisabled: function nextMonthDisabled() {\n var max = this.computedMax;\n return this.disabled || max && firstDateOfMonth(oneMonthAhead(this.activeDate)) > max;\n },\n nextYearDisabled: function nextYearDisabled() {\n var max = this.computedMax;\n return this.disabled || max && firstDateOfMonth(oneYearAhead(this.activeDate)) > max;\n },\n nextDecadeDisabled: function nextDecadeDisabled() {\n var max = this.computedMax;\n return this.disabled || max && firstDateOfMonth(oneDecadeAhead(this.activeDate)) > max;\n },\n // Calendar dates generation\n calendar: function calendar() {\n var matrix = [];\n var firstDay = this.calendarFirstDay;\n var calendarYear = firstDay.getFullYear();\n var calendarMonth = firstDay.getMonth();\n var daysInMonth = this.calendarDaysInMonth;\n var startIndex = firstDay.getDay(); // `0`..`6`\n\n var weekOffset = (this.computedWeekStarts > startIndex ? 7 : 0) - this.computedWeekStarts; // Build the calendar matrix\n\n var currentDay = 0 - weekOffset - startIndex;\n\n for (var week = 0; week < 6 && currentDay < daysInMonth; week++) {\n // For each week\n matrix[week] = []; // The following could be a map function\n\n for (var j = 0; j < 7; j++) {\n // For each day in week\n currentDay++;\n var date = createDate(calendarYear, calendarMonth, currentDay);\n var month = date.getMonth();\n var dayYMD = formatYMD(date);\n var dayDisabled = this.dateDisabled(date); // TODO: This could be a normalizer method\n\n var dateInfo = this.computedDateInfoFn(dayYMD, parseYMD(dayYMD));\n dateInfo = isString(dateInfo) || isArray(dateInfo) ?\n /* istanbul ignore next */\n {\n class: dateInfo\n } : isPlainObject(dateInfo) ? _objectSpread2$3({\n class: ''\n }, dateInfo) :\n /* istanbul ignore next */\n {\n class: ''\n };\n matrix[week].push({\n ymd: dayYMD,\n // Cell content\n day: this.formatDay(date),\n label: this.formatDateString(date),\n // Flags for styling\n isThisMonth: month === calendarMonth,\n isDisabled: dayDisabled,\n // TODO: Handle other dateInfo properties such as notes/events\n info: dateInfo\n });\n }\n }\n\n return matrix;\n },\n calendarHeadings: function calendarHeadings() {\n var _this2 = this;\n\n return this.calendar[0].map(function (d) {\n return {\n text: _this2.formatWeekdayNameShort(parseYMD(d.ymd)),\n label: _this2.formatWeekdayName(parseYMD(d.ymd))\n };\n });\n }\n },\n watch: (_watch$j = {}, _defineProperty(_watch$j, MODEL_PROP_NAME$i, function (newValue, oldValue) {\n var selected = formatYMD(newValue) || '';\n var old = formatYMD(oldValue) || '';\n\n if (!datesEqual(selected, old)) {\n this.activeYMD = selected || this.activeYMD;\n this.selectedYMD = selected;\n }\n }), _defineProperty(_watch$j, \"selectedYMD\", function selectedYMD(newYMD, oldYMD) {\n // TODO:\n // Should we compare to `formatYMD(this.value)` and emit\n // only if they are different?\n if (newYMD !== oldYMD) {\n this.$emit(MODEL_EVENT_NAME$i, this.valueAsDate ? parseYMD(newYMD) || null : newYMD || '');\n }\n }), _defineProperty(_watch$j, \"context\", function context(newValue, oldValue) {\n if (!looseEqual(newValue, oldValue)) {\n this.$emit(EVENT_NAME_CONTEXT, newValue);\n }\n }), _defineProperty(_watch$j, \"hidden\", function hidden(newValue) {\n // Reset the active focused day when hidden\n this.activeYMD = this.selectedYMD || formatYMD(this[MODEL_PROP_NAME$i] || this.constrainDate(this.initialDate || this.getToday())); // Enable/disable the live regions\n\n this.setLive(!newValue);\n }), _watch$j),\n created: function created() {\n var _this3 = this;\n\n this.$nextTick(function () {\n _this3.$emit(EVENT_NAME_CONTEXT, _this3.context);\n });\n },\n mounted: function mounted() {\n this.setLive(true);\n },\n\n /* istanbul ignore next */\n activated: function activated() {\n this.setLive(true);\n },\n\n /* istanbul ignore next */\n deactivated: function deactivated() {\n this.setLive(false);\n },\n beforeDestroy: function beforeDestroy() {\n this.setLive(false);\n },\n methods: {\n // Public method(s)\n focus: function focus() {\n if (!this.disabled) {\n attemptFocus(this.$refs.grid);\n }\n },\n blur: function blur() {\n if (!this.disabled) {\n attemptBlur(this.$refs.grid);\n }\n },\n // Private methods\n setLive: function setLive(on) {\n var _this4 = this;\n\n if (on) {\n this.$nextTick(function () {\n requestAF(function () {\n _this4.isLive = true;\n });\n });\n } else {\n this.isLive = false;\n }\n },\n getToday: function getToday() {\n return parseYMD(createDate());\n },\n constrainDate: function constrainDate$1(date) {\n // Constrains a date between min and max\n // returns a new `Date` object instance\n return constrainDate(date, this.computedMin, this.computedMax);\n },\n emitSelected: function emitSelected(date) {\n var _this5 = this;\n\n // Performed in a `$nextTick()` to (probably) ensure\n // the input event has emitted first\n this.$nextTick(function () {\n _this5.$emit(EVENT_NAME_SELECTED, formatYMD(date) || '', parseYMD(date) || null);\n });\n },\n // Event handlers\n setGridFocusFlag: function setGridFocusFlag(event) {\n // Sets the gridHasFocus flag to make date \"button\" look focused\n this.gridHasFocus = !this.disabled && event.type === 'focus';\n },\n onKeydownWrapper: function onKeydownWrapper(event) {\n // Calendar keyboard navigation\n // Handles PAGEUP/PAGEDOWN/END/HOME/LEFT/UP/RIGHT/DOWN\n // Focuses grid after updating\n if (this.noKeyNav) {\n /* istanbul ignore next */\n return;\n }\n\n var altKey = event.altKey,\n ctrlKey = event.ctrlKey,\n keyCode = event.keyCode;\n\n if (!arrayIncludes([CODE_PAGEUP, CODE_PAGEDOWN, CODE_END, CODE_HOME, CODE_LEFT, CODE_UP, CODE_RIGHT, CODE_DOWN], keyCode)) {\n /* istanbul ignore next */\n return;\n }\n\n stopEvent(event);\n var activeDate = createDate(this.activeDate);\n var checkDate = createDate(this.activeDate);\n var day = activeDate.getDate();\n var constrainedToday = this.constrainDate(this.getToday());\n var isRTL = this.isRTL;\n\n if (keyCode === CODE_PAGEUP) {\n // PAGEUP - Previous month/year\n activeDate = (altKey ? ctrlKey ? oneDecadeAgo : oneYearAgo : oneMonthAgo)(activeDate); // We check the first day of month to be in rage\n\n checkDate = createDate(activeDate);\n checkDate.setDate(1);\n } else if (keyCode === CODE_PAGEDOWN) {\n // PAGEDOWN - Next month/year\n activeDate = (altKey ? ctrlKey ? oneDecadeAhead : oneYearAhead : oneMonthAhead)(activeDate); // We check the last day of month to be in rage\n\n checkDate = createDate(activeDate);\n checkDate.setMonth(checkDate.getMonth() + 1);\n checkDate.setDate(0);\n } else if (keyCode === CODE_LEFT) {\n // LEFT - Previous day (or next day for RTL)\n activeDate.setDate(day + (isRTL ? 1 : -1));\n activeDate = this.constrainDate(activeDate);\n checkDate = activeDate;\n } else if (keyCode === CODE_RIGHT) {\n // RIGHT - Next day (or previous day for RTL)\n activeDate.setDate(day + (isRTL ? -1 : 1));\n activeDate = this.constrainDate(activeDate);\n checkDate = activeDate;\n } else if (keyCode === CODE_UP) {\n // UP - Previous week\n activeDate.setDate(day - 7);\n activeDate = this.constrainDate(activeDate);\n checkDate = activeDate;\n } else if (keyCode === CODE_DOWN) {\n // DOWN - Next week\n activeDate.setDate(day + 7);\n activeDate = this.constrainDate(activeDate);\n checkDate = activeDate;\n } else if (keyCode === CODE_HOME) {\n // HOME - Today\n activeDate = constrainedToday;\n checkDate = activeDate;\n } else if (keyCode === CODE_END) {\n // END - Selected date, or today if no selected date\n activeDate = parseYMD(this.selectedDate) || constrainedToday;\n checkDate = activeDate;\n }\n\n if (!this.dateOutOfRange(checkDate) && !datesEqual(activeDate, this.activeDate)) {\n // We only jump to date if within min/max\n // We don't check for individual disabled dates though (via user function)\n this.activeYMD = formatYMD(activeDate);\n } // Ensure grid is focused\n\n\n this.focus();\n },\n onKeydownGrid: function onKeydownGrid(event) {\n // Pressing enter/space on grid to select active date\n var keyCode = event.keyCode;\n var activeDate = this.activeDate;\n\n if (keyCode === CODE_ENTER || keyCode === CODE_SPACE) {\n stopEvent(event);\n\n if (!this.disabled && !this.readonly && !this.dateDisabled(activeDate)) {\n this.selectedYMD = formatYMD(activeDate);\n this.emitSelected(activeDate);\n } // Ensure grid is focused\n\n\n this.focus();\n }\n },\n onClickDay: function onClickDay(day) {\n // Clicking on a date \"button\" to select it\n var selectedDate = this.selectedDate,\n activeDate = this.activeDate;\n var clickedDate = parseYMD(day.ymd);\n\n if (!this.disabled && !day.isDisabled && !this.dateDisabled(clickedDate)) {\n if (!this.readonly) {\n // If readonly mode, we don't set the selected date, just the active date\n // If the clicked date is equal to the already selected date, we don't update the model\n this.selectedYMD = formatYMD(datesEqual(clickedDate, selectedDate) ? selectedDate : clickedDate);\n this.emitSelected(clickedDate);\n }\n\n this.activeYMD = formatYMD(datesEqual(clickedDate, activeDate) ? activeDate : createDate(clickedDate)); // Ensure grid is focused\n\n this.focus();\n }\n },\n gotoPrevDecade: function gotoPrevDecade() {\n this.activeYMD = formatYMD(this.constrainDate(oneDecadeAgo(this.activeDate)));\n },\n gotoPrevYear: function gotoPrevYear() {\n this.activeYMD = formatYMD(this.constrainDate(oneYearAgo(this.activeDate)));\n },\n gotoPrevMonth: function gotoPrevMonth() {\n this.activeYMD = formatYMD(this.constrainDate(oneMonthAgo(this.activeDate)));\n },\n gotoCurrentMonth: function gotoCurrentMonth() {\n // TODO: Maybe this goto date should be configurable?\n this.activeYMD = formatYMD(this.constrainDate(this.getToday()));\n },\n gotoNextMonth: function gotoNextMonth() {\n this.activeYMD = formatYMD(this.constrainDate(oneMonthAhead(this.activeDate)));\n },\n gotoNextYear: function gotoNextYear() {\n this.activeYMD = formatYMD(this.constrainDate(oneYearAhead(this.activeDate)));\n },\n gotoNextDecade: function gotoNextDecade() {\n this.activeYMD = formatYMD(this.constrainDate(oneDecadeAhead(this.activeDate)));\n },\n onHeaderClick: function onHeaderClick() {\n if (!this.disabled) {\n this.activeYMD = this.selectedYMD || formatYMD(this.getToday());\n this.focus();\n }\n }\n },\n render: function render(h) {\n var _this6 = this;\n\n // If `hidden` prop is set, render just a placeholder node\n if (this.hidden) {\n return h();\n }\n\n var valueId = this.valueId,\n widgetId = this.widgetId,\n navId = this.navId,\n gridId = this.gridId,\n gridCaptionId = this.gridCaptionId,\n gridHelpId = this.gridHelpId,\n activeId = this.activeId,\n disabled = this.disabled,\n noKeyNav = this.noKeyNav,\n isLive = this.isLive,\n isRTL = this.isRTL,\n activeYMD = this.activeYMD,\n selectedYMD = this.selectedYMD,\n safeId = this.safeId;\n var hideDecadeNav = !this.showDecadeNav;\n var todayYMD = formatYMD(this.getToday());\n var highlightToday = !this.noHighlightToday; // Header showing current selected date\n\n var $header = h('output', {\n staticClass: 'form-control form-control-sm text-center',\n class: {\n 'text-muted': disabled,\n readonly: this.readonly || disabled\n },\n attrs: {\n id: valueId,\n for: gridId,\n role: 'status',\n tabindex: disabled ? null : '-1',\n // Mainly for testing purposes, as we do not know\n // the exact format `Intl` will format the date string\n 'data-selected': toString(selectedYMD),\n // We wait until after mount to enable `aria-live`\n // to prevent initial announcement on page render\n 'aria-live': isLive ? 'polite' : 'off',\n 'aria-atomic': isLive ? 'true' : null\n },\n on: {\n // Transfer focus/click to focus grid\n // and focus active date (or today if no selection)\n click: this.onHeaderClick,\n focus: this.onHeaderClick\n }\n }, this.selectedDate ? [// We use `bdi` elements here in case the label doesn't match the locale\n // Although IE 11 does not deal with at all (equivalent to a span)\n h('bdi', {\n staticClass: 'sr-only'\n }, \" (\".concat(toString(this.labelSelected), \") \")), h('bdi', this.formatDateString(this.selectedDate))] : this.labelNoDateSelected || \"\\xA0\" // ' '\n );\n $header = h(this.headerTag, {\n staticClass: 'b-calendar-header',\n class: {\n 'sr-only': this.hideHeader\n },\n attrs: {\n title: this.selectedDate ? this.labelSelected || null : null\n }\n }, [$header]); // Content for the date navigation buttons\n\n var navScope = {\n isRTL: isRTL\n };\n var navProps = {\n shiftV: 0.5\n };\n\n var navPrevProps = _objectSpread2$3(_objectSpread2$3({}, navProps), {}, {\n flipH: isRTL\n });\n\n var navNextProps = _objectSpread2$3(_objectSpread2$3({}, navProps), {}, {\n flipH: !isRTL\n });\n\n var $prevDecadeIcon = this.normalizeSlot(SLOT_NAME_NAV_PEV_DECADE, navScope) || h(BIconChevronBarLeft, {\n props: navPrevProps\n });\n var $prevYearIcon = this.normalizeSlot(SLOT_NAME_NAV_PEV_YEAR, navScope) || h(BIconChevronDoubleLeft, {\n props: navPrevProps\n });\n var $prevMonthIcon = this.normalizeSlot(SLOT_NAME_NAV_PEV_MONTH, navScope) || h(BIconChevronLeft, {\n props: navPrevProps\n });\n var $thisMonthIcon = this.normalizeSlot(SLOT_NAME_NAV_THIS_MONTH, navScope) || h(BIconCircleFill, {\n props: navProps\n });\n var $nextMonthIcon = this.normalizeSlot(SLOT_NAME_NAV_NEXT_MONTH, navScope) || h(BIconChevronLeft, {\n props: navNextProps\n });\n var $nextYearIcon = this.normalizeSlot(SLOT_NAME_NAV_NEXT_YEAR, navScope) || h(BIconChevronDoubleLeft, {\n props: navNextProps\n });\n var $nextDecadeIcon = this.normalizeSlot(SLOT_NAME_NAV_NEXT_DECADE, navScope) || h(BIconChevronBarLeft, {\n props: navNextProps\n }); // Utility to create the date navigation buttons\n\n var makeNavBtn = function makeNavBtn(content, label, handler, btnDisabled, shortcut) {\n return h('button', {\n staticClass: 'btn btn-sm border-0 flex-fill',\n class: [_this6.computedNavButtonVariant, {\n disabled: btnDisabled\n }],\n attrs: {\n title: label || null,\n type: 'button',\n tabindex: noKeyNav ? '-1' : null,\n 'aria-label': label || null,\n 'aria-disabled': btnDisabled ? 'true' : null,\n 'aria-keyshortcuts': shortcut || null\n },\n on: btnDisabled ? {} : {\n click: handler\n }\n }, [h('div', {\n attrs: {\n 'aria-hidden': 'true'\n }\n }, [content])]);\n }; // Generate the date navigation buttons\n\n\n var $nav = h('div', {\n staticClass: 'b-calendar-nav d-flex',\n attrs: {\n id: navId,\n role: 'group',\n tabindex: noKeyNav ? '-1' : null,\n 'aria-hidden': disabled ? 'true' : null,\n 'aria-label': this.labelNav || null,\n 'aria-controls': gridId\n }\n }, [hideDecadeNav ? h() : makeNavBtn($prevDecadeIcon, this.labelPrevDecade, this.gotoPrevDecade, this.prevDecadeDisabled, 'Ctrl+Alt+PageDown'), makeNavBtn($prevYearIcon, this.labelPrevYear, this.gotoPrevYear, this.prevYearDisabled, 'Alt+PageDown'), makeNavBtn($prevMonthIcon, this.labelPrevMonth, this.gotoPrevMonth, this.prevMonthDisabled, 'PageDown'), makeNavBtn($thisMonthIcon, this.labelCurrentMonth, this.gotoCurrentMonth, this.thisMonthDisabled, 'Home'), makeNavBtn($nextMonthIcon, this.labelNextMonth, this.gotoNextMonth, this.nextMonthDisabled, 'PageUp'), makeNavBtn($nextYearIcon, this.labelNextYear, this.gotoNextYear, this.nextYearDisabled, 'Alt+PageUp'), hideDecadeNav ? h() : makeNavBtn($nextDecadeIcon, this.labelNextDecade, this.gotoNextDecade, this.nextDecadeDisabled, 'Ctrl+Alt+PageUp')]); // Caption for calendar grid\n\n var $gridCaption = h('div', {\n staticClass: 'b-calendar-grid-caption text-center font-weight-bold',\n class: {\n 'text-muted': disabled\n },\n attrs: {\n id: gridCaptionId,\n 'aria-live': isLive ? 'polite' : null,\n 'aria-atomic': isLive ? 'true' : null\n },\n key: 'grid-caption'\n }, this.formatYearMonth(this.calendarFirstDay)); // Calendar weekday headings\n\n var $gridWeekDays = h('div', {\n staticClass: 'b-calendar-grid-weekdays row no-gutters border-bottom',\n attrs: {\n 'aria-hidden': 'true'\n }\n }, this.calendarHeadings.map(function (d, idx) {\n return h('small', {\n staticClass: 'col text-truncate',\n class: {\n 'text-muted': disabled\n },\n attrs: {\n title: d.label === d.text ? null : d.label,\n 'aria-label': d.label\n },\n key: idx\n }, d.text);\n })); // Calendar day grid\n\n var $gridBody = this.calendar.map(function (week) {\n var $cells = week.map(function (day, dIndex) {\n var _class;\n\n var isSelected = day.ymd === selectedYMD;\n var isActive = day.ymd === activeYMD;\n var isToday = day.ymd === todayYMD;\n var idCell = safeId(\"_cell-\".concat(day.ymd, \"_\")); // \"fake\" button\n\n var $btn = h('span', {\n staticClass: 'btn border-0 rounded-circle text-nowrap',\n // Should we add some classes to signify if today/selected/etc?\n class: (_class = {\n // Give the fake button a focus ring\n focus: isActive && _this6.gridHasFocus,\n // Styling\n disabled: day.isDisabled || disabled,\n active: isSelected\n }, _defineProperty(_class, _this6.computedVariant, isSelected), _defineProperty(_class, _this6.computedTodayVariant, isToday && highlightToday && !isSelected && day.isThisMonth), _defineProperty(_class, 'btn-outline-light', !(isToday && highlightToday) && !isSelected && !isActive), _defineProperty(_class, 'btn-light', !(isToday && highlightToday) && !isSelected && isActive), _defineProperty(_class, 'text-muted', !day.isThisMonth && !isSelected), _defineProperty(_class, 'text-dark', !(isToday && highlightToday) && !isSelected && !isActive && day.isThisMonth), _defineProperty(_class, 'font-weight-bold', (isSelected || day.isThisMonth) && !day.isDisabled), _class),\n on: {\n click: function click() {\n return _this6.onClickDay(day);\n }\n }\n }, day.day);\n return h('div', // Cell with button\n {\n staticClass: 'col p-0',\n class: day.isDisabled ? 'bg-light' : day.info.class || '',\n attrs: {\n id: idCell,\n role: 'button',\n 'data-date': day.ymd,\n // Primarily for testing purposes\n // Only days in the month are presented as buttons to screen readers\n 'aria-hidden': day.isThisMonth ? null : 'true',\n 'aria-disabled': day.isDisabled || disabled ? 'true' : null,\n 'aria-label': [day.label, isSelected ? \"(\".concat(_this6.labelSelected, \")\") : null, isToday ? \"(\".concat(_this6.labelToday, \")\") : null].filter(identity).join(' '),\n // NVDA doesn't convey `aria-selected`, but does `aria-current`,\n // ChromeVox doesn't convey `aria-current`, but does `aria-selected`,\n // so we set both attributes for robustness\n 'aria-selected': isSelected ? 'true' : null,\n 'aria-current': isSelected ? 'date' : null\n },\n key: dIndex\n }, [$btn]);\n }); // Return the week \"row\"\n // We use the first day of the weeks YMD value as a\n // key for efficient DOM patching / element re-use\n\n return h('div', {\n staticClass: 'row no-gutters',\n key: week[0].ymd\n }, $cells);\n });\n $gridBody = h('div', {\n // A key is only required on the body if we add in transition support\n staticClass: 'b-calendar-grid-body',\n style: disabled ? {\n pointerEvents: 'none'\n } : {} // key: this.activeYMD.slice(0, -3)\n\n }, $gridBody);\n var $gridHelp = h('div', {\n staticClass: 'b-calendar-grid-help border-top small text-muted text-center bg-light',\n attrs: {\n id: gridHelpId\n }\n }, [h('div', {\n staticClass: 'small'\n }, this.labelHelp)]);\n var $grid = h('div', {\n staticClass: 'b-calendar-grid form-control h-auto text-center',\n attrs: {\n id: gridId,\n role: 'application',\n tabindex: noKeyNav ? '-1' : disabled ? null : '0',\n 'data-month': activeYMD.slice(0, -3),\n // `YYYY-MM`, mainly for testing\n 'aria-roledescription': this.labelCalendar || null,\n 'aria-labelledby': gridCaptionId,\n 'aria-describedby': gridHelpId,\n // `aria-readonly` is not considered valid on `role=\"application\"`\n // https://www.w3.org/TR/wai-aria-1.1/#aria-readonly\n // 'aria-readonly': this.readonly && !disabled ? 'true' : null,\n 'aria-disabled': disabled ? 'true' : null,\n 'aria-activedescendant': activeId\n },\n on: {\n keydown: this.onKeydownGrid,\n focus: this.setGridFocusFlag,\n blur: this.setGridFocusFlag\n },\n ref: 'grid'\n }, [$gridCaption, $gridWeekDays, $gridBody, $gridHelp]); // Optional bottom slot\n\n var $slot = this.normalizeSlot();\n $slot = $slot ? h('footer', {\n staticClass: 'b-calendar-footer'\n }, $slot) : h();\n var $widget = h('div', {\n staticClass: 'b-calendar-inner',\n style: this.block ? {} : {\n width: this.width\n },\n attrs: {\n id: widgetId,\n dir: isRTL ? 'rtl' : 'ltr',\n lang: this.computedLocale || null,\n role: 'group',\n 'aria-disabled': disabled ? 'true' : null,\n // If datepicker controls an input, this will specify the ID of the input\n 'aria-controls': this.ariaControls || null,\n // This should be a prop (so it can be changed to Date picker, etc, localized\n 'aria-roledescription': this.roleDescription || null,\n 'aria-describedby': [// Should the attr (if present) go last?\n // Or should this attr be a prop?\n this.bvAttrs['aria-describedby'], valueId, gridHelpId].filter(identity).join(' ')\n },\n on: {\n keydown: this.onKeydownWrapper\n }\n }, [$header, $nav, $grid, $slot]); // Wrap in an outer div that can be styled\n\n return h('div', {\n staticClass: 'b-calendar',\n class: {\n 'd-block': this.block\n }\n }, [$widget]);\n }\n });\n\n var CalendarPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BCalendar: BCalendar\n }\n });\n\n var props$23 = makePropsConfigurable({\n bgVariant: makeProp(PROP_TYPE_STRING),\n borderVariant: makeProp(PROP_TYPE_STRING),\n tag: makeProp(PROP_TYPE_STRING, 'div'),\n textVariant: makeProp(PROP_TYPE_STRING)\n }, NAME_CARD); // --- Mixin ---\n // @vue/component\n\n extend({\n props: props$23\n });\n\n var props$22 = makePropsConfigurable({\n title: makeProp(PROP_TYPE_STRING),\n titleTag: makeProp(PROP_TYPE_STRING, 'h4')\n }, NAME_CARD_TITLE); // --- Main component ---\n // @vue/component\n\n var BCardTitle = /*#__PURE__*/extend({\n name: NAME_CARD_TITLE,\n functional: true,\n props: props$22,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h(props.titleTag, a(data, {\n staticClass: 'card-title'\n }), children || toString(props.title));\n }\n });\n\n var props$21 = makePropsConfigurable({\n subTitle: makeProp(PROP_TYPE_STRING),\n subTitleTag: makeProp(PROP_TYPE_STRING, 'h6'),\n subTitleTextVariant: makeProp(PROP_TYPE_STRING, 'muted')\n }, NAME_CARD_SUB_TITLE); // --- Main component ---\n // @vue/component\n\n var BCardSubTitle = /*#__PURE__*/extend({\n name: NAME_CARD_SUB_TITLE,\n functional: true,\n props: props$21,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h(props.subTitleTag, a(data, {\n staticClass: 'card-subtitle',\n class: [props.subTitleTextVariant ? \"text-\".concat(props.subTitleTextVariant) : null]\n }), children || toString(props.subTitle));\n }\n });\n\n var props$20 = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$22), props$21), copyProps(props$23, prefixPropName.bind(null, 'body'))), {}, {\n bodyClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n overlay: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_CARD_BODY); // --- Main component ---\n // @vue/component\n\n var BCardBody = /*#__PURE__*/extend({\n name: NAME_CARD_BODY,\n functional: true,\n props: props$20,\n render: function render(h, _ref) {\n var _ref2;\n\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var bodyBgVariant = props.bodyBgVariant,\n bodyBorderVariant = props.bodyBorderVariant,\n bodyTextVariant = props.bodyTextVariant;\n var $title = h();\n\n if (props.title) {\n $title = h(BCardTitle, {\n props: pluckProps(props$22, props)\n });\n }\n\n var $subTitle = h();\n\n if (props.subTitle) {\n $subTitle = h(BCardSubTitle, {\n props: pluckProps(props$21, props),\n class: ['mb-2']\n });\n }\n\n return h(props.bodyTag, a(data, {\n staticClass: 'card-body',\n class: [(_ref2 = {\n 'card-img-overlay': props.overlay\n }, _defineProperty(_ref2, \"bg-\".concat(bodyBgVariant), bodyBgVariant), _defineProperty(_ref2, \"border-\".concat(bodyBorderVariant), bodyBorderVariant), _defineProperty(_ref2, \"text-\".concat(bodyTextVariant), bodyTextVariant), _ref2), props.bodyClass]\n }), [$title, $subTitle, children]);\n }\n });\n\n var props$1$ = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, copyProps(props$23, prefixPropName.bind(null, 'header'))), {}, {\n header: makeProp(PROP_TYPE_STRING),\n headerClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n headerHtml: makeProp(PROP_TYPE_STRING)\n })), NAME_CARD_HEADER); // --- Main component ---\n // @vue/component\n\n var BCardHeader = /*#__PURE__*/extend({\n name: NAME_CARD_HEADER,\n functional: true,\n props: props$1$,\n render: function render(h, _ref) {\n var _ref2;\n\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var headerBgVariant = props.headerBgVariant,\n headerBorderVariant = props.headerBorderVariant,\n headerTextVariant = props.headerTextVariant;\n return h(props.headerTag, a(data, {\n staticClass: 'card-header',\n class: [props.headerClass, (_ref2 = {}, _defineProperty(_ref2, \"bg-\".concat(headerBgVariant), headerBgVariant), _defineProperty(_ref2, \"border-\".concat(headerBorderVariant), headerBorderVariant), _defineProperty(_ref2, \"text-\".concat(headerTextVariant), headerTextVariant), _ref2)],\n domProps: children ? {} : htmlOrText(props.headerHtml, props.header)\n }), children);\n }\n });\n\n var props$1_ = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, copyProps(props$23, prefixPropName.bind(null, 'footer'))), {}, {\n footer: makeProp(PROP_TYPE_STRING),\n footerClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n footerHtml: makeProp(PROP_TYPE_STRING)\n })), NAME_CARD_FOOTER); // --- Main component ---\n // @vue/component\n\n var BCardFooter = /*#__PURE__*/extend({\n name: NAME_CARD_FOOTER,\n functional: true,\n props: props$1_,\n render: function render(h, _ref) {\n var _ref2;\n\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var footerBgVariant = props.footerBgVariant,\n footerBorderVariant = props.footerBorderVariant,\n footerTextVariant = props.footerTextVariant;\n return h(props.footerTag, a(data, {\n staticClass: 'card-footer',\n class: [props.footerClass, (_ref2 = {}, _defineProperty(_ref2, \"bg-\".concat(footerBgVariant), footerBgVariant), _defineProperty(_ref2, \"border-\".concat(footerBorderVariant), footerBorderVariant), _defineProperty(_ref2, \"text-\".concat(footerTextVariant), footerTextVariant), _ref2)],\n domProps: children ? {} : htmlOrText(props.footerHtml, props.footer)\n }), children);\n }\n });\n\n // Blank image with fill template\n\n var BLANK_TEMPLATE = '' + '' + ''; // --- Helper methods ---\n\n var makeBlankImgSrc = function makeBlankImgSrc(width, height, color) {\n var src = encodeURIComponent(BLANK_TEMPLATE.replace('%{w}', toString(width)).replace('%{h}', toString(height)).replace('%{f}', color));\n return \"data:image/svg+xml;charset=UTF-8,\".concat(src);\n }; // --- Props ---\n\n\n var props$1Z = makePropsConfigurable({\n alt: makeProp(PROP_TYPE_STRING),\n blank: makeProp(PROP_TYPE_BOOLEAN, false),\n blankColor: makeProp(PROP_TYPE_STRING, 'transparent'),\n block: makeProp(PROP_TYPE_BOOLEAN, false),\n center: makeProp(PROP_TYPE_BOOLEAN, false),\n fluid: makeProp(PROP_TYPE_BOOLEAN, false),\n // Gives fluid images class `w-100` to make them grow to fit container\n fluidGrow: makeProp(PROP_TYPE_BOOLEAN, false),\n height: makeProp(PROP_TYPE_NUMBER_STRING),\n left: makeProp(PROP_TYPE_BOOLEAN, false),\n right: makeProp(PROP_TYPE_BOOLEAN, false),\n // Possible values:\n // `false`: no rounding of corners\n // `true`: slightly rounded corners\n // 'top': top corners rounded\n // 'right': right corners rounded\n // 'bottom': bottom corners rounded\n // 'left': left corners rounded\n // 'circle': circle/oval\n // '0': force rounding off\n rounded: makeProp(PROP_TYPE_BOOLEAN_STRING, false),\n sizes: makeProp(PROP_TYPE_ARRAY_STRING),\n src: makeProp(PROP_TYPE_STRING),\n srcset: makeProp(PROP_TYPE_ARRAY_STRING),\n thumbnail: makeProp(PROP_TYPE_BOOLEAN, false),\n width: makeProp(PROP_TYPE_NUMBER_STRING)\n }, NAME_IMG); // --- Main component ---\n // @vue/component\n\n var BImg = /*#__PURE__*/extend({\n name: NAME_IMG,\n functional: true,\n props: props$1Z,\n render: function render(h, _ref) {\n var _class;\n\n var props = _ref.props,\n data = _ref.data;\n var alt = props.alt,\n src = props.src,\n block = props.block,\n fluidGrow = props.fluidGrow,\n rounded = props.rounded;\n var width = toInteger(props.width) || null;\n var height = toInteger(props.height) || null;\n var align = null;\n var srcset = concat(props.srcset).filter(identity).join(',');\n var sizes = concat(props.sizes).filter(identity).join(',');\n\n if (props.blank) {\n if (!height && width) {\n height = width;\n } else if (!width && height) {\n width = height;\n }\n\n if (!width && !height) {\n width = 1;\n height = 1;\n } // Make a blank SVG image\n\n\n src = makeBlankImgSrc(width, height, props.blankColor || 'transparent'); // Disable srcset and sizes\n\n srcset = null;\n sizes = null;\n }\n\n if (props.left) {\n align = 'float-left';\n } else if (props.right) {\n align = 'float-right';\n } else if (props.center) {\n align = 'mx-auto';\n block = true;\n }\n\n return h('img', a(data, {\n attrs: {\n src: src,\n alt: alt,\n width: width ? toString(width) : null,\n height: height ? toString(height) : null,\n srcset: srcset || null,\n sizes: sizes || null\n },\n class: (_class = {\n 'img-thumbnail': props.thumbnail,\n 'img-fluid': props.fluid || fluidGrow,\n 'w-100': fluidGrow,\n rounded: rounded === '' || rounded === true\n }, _defineProperty(_class, \"rounded-\".concat(rounded), isString(rounded) && rounded !== ''), _defineProperty(_class, align, align), _defineProperty(_class, 'd-block', block), _class)\n }));\n }\n });\n\n var props$1Y = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, pick$1(props$1Z, ['src', 'alt', 'width', 'height', 'left', 'right'])), {}, {\n bottom: makeProp(PROP_TYPE_BOOLEAN, false),\n end: makeProp(PROP_TYPE_BOOLEAN, false),\n start: makeProp(PROP_TYPE_BOOLEAN, false),\n top: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_CARD_IMG); // --- Main component ---\n // @vue/component\n\n var BCardImg = /*#__PURE__*/extend({\n name: NAME_CARD_IMG,\n functional: true,\n props: props$1Y,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data;\n var src = props.src,\n alt = props.alt,\n width = props.width,\n height = props.height;\n var baseClass = 'card-img';\n\n if (props.top) {\n baseClass += '-top';\n } else if (props.right || props.end) {\n baseClass += '-right';\n } else if (props.bottom) {\n baseClass += '-bottom';\n } else if (props.left || props.start) {\n baseClass += '-left';\n }\n\n return h('img', a(data, {\n class: baseClass,\n attrs: {\n src: src,\n alt: alt,\n width: width,\n height: height\n }\n }));\n }\n });\n\n var cardImgProps = copyProps(props$1Y, prefixPropName.bind(null, 'img'));\n cardImgProps.imgSrc.required = false;\n var props$1X = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$20), props$1$), props$1_), cardImgProps), props$23), {}, {\n align: makeProp(PROP_TYPE_STRING),\n noBody: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_CARD); // --- Main component ---\n // @vue/component\n\n var BCard = /*#__PURE__*/extend({\n name: NAME_CARD,\n functional: true,\n props: props$1X,\n render: function render(h, _ref) {\n var _class;\n\n var props = _ref.props,\n data = _ref.data,\n slots = _ref.slots,\n scopedSlots = _ref.scopedSlots;\n var imgSrc = props.imgSrc,\n imgLeft = props.imgLeft,\n imgRight = props.imgRight,\n imgStart = props.imgStart,\n imgEnd = props.imgEnd,\n imgBottom = props.imgBottom,\n header = props.header,\n headerHtml = props.headerHtml,\n footer = props.footer,\n footerHtml = props.footerHtml,\n align = props.align,\n textVariant = props.textVariant,\n bgVariant = props.bgVariant,\n borderVariant = props.borderVariant;\n var $scopedSlots = scopedSlots || {};\n var $slots = slots();\n var slotScope = {};\n var $imgFirst = h();\n var $imgLast = h();\n\n if (imgSrc) {\n var $img = h(BCardImg, {\n props: pluckProps(cardImgProps, props, unprefixPropName.bind(null, 'img'))\n });\n\n if (imgBottom) {\n $imgLast = $img;\n } else {\n $imgFirst = $img;\n }\n }\n\n var $header = h();\n var hasHeaderSlot = hasNormalizedSlot(SLOT_NAME_HEADER, $scopedSlots, $slots);\n\n if (hasHeaderSlot || header || headerHtml) {\n $header = h(BCardHeader, {\n props: pluckProps(props$1$, props),\n domProps: hasHeaderSlot ? {} : htmlOrText(headerHtml, header)\n }, normalizeSlot(SLOT_NAME_HEADER, slotScope, $scopedSlots, $slots));\n }\n\n var $content = normalizeSlot(SLOT_NAME_DEFAULT, slotScope, $scopedSlots, $slots); // Wrap content in `` when `noBody` prop set\n\n if (!props.noBody) {\n $content = h(BCardBody, {\n props: pluckProps(props$20, props)\n }, $content); // When the `overlap` prop is set we need to wrap the `` and ``\n // into a relative positioned wrapper to don't distract a potential header or footer\n\n if (props.overlay && imgSrc) {\n $content = h('div', {\n staticClass: 'position-relative'\n }, [$imgFirst, $content, $imgLast]); // Reset image variables since they are already in the wrapper\n\n $imgFirst = h();\n $imgLast = h();\n }\n }\n\n var $footer = h();\n var hasFooterSlot = hasNormalizedSlot(SLOT_NAME_FOOTER, $scopedSlots, $slots);\n\n if (hasFooterSlot || footer || footerHtml) {\n $footer = h(BCardFooter, {\n props: pluckProps(props$1_, props),\n domProps: hasHeaderSlot ? {} : htmlOrText(footerHtml, footer)\n }, normalizeSlot(SLOT_NAME_FOOTER, slotScope, $scopedSlots, $slots));\n }\n\n return h(props.tag, a(data, {\n staticClass: 'card',\n class: (_class = {\n 'flex-row': imgLeft || imgStart,\n 'flex-row-reverse': (imgRight || imgEnd) && !(imgLeft || imgStart)\n }, _defineProperty(_class, \"text-\".concat(align), align), _defineProperty(_class, \"bg-\".concat(bgVariant), bgVariant), _defineProperty(_class, \"border-\".concat(borderVariant), borderVariant), _defineProperty(_class, \"text-\".concat(textVariant), textVariant), _class)\n }), [$imgFirst, $header, $content, $footer, $imgLast]);\n }\n });\n\n var OBSERVER_PROP_NAME = '__bv__visibility_observer';\n\n var VisibilityObserver = /*#__PURE__*/function () {\n function VisibilityObserver(el, options) {\n _classCallCheck(this, VisibilityObserver);\n\n this.el = el;\n this.callback = options.callback;\n this.margin = options.margin || 0;\n this.once = options.once || false;\n this.observer = null;\n this.visible = undefined;\n this.doneOnce = false; // Create the observer instance (if possible)\n\n this.createObserver();\n }\n\n _createClass(VisibilityObserver, [{\n key: \"createObserver\",\n value: function createObserver() {\n var _this = this;\n\n // Remove any previous observer\n if (this.observer) {\n /* istanbul ignore next */\n this.stop();\n } // Should only be called once and `callback` prop should be a function\n\n\n if (this.doneOnce || !isFunction$1(this.callback)) {\n /* istanbul ignore next */\n return;\n } // Create the observer instance\n\n\n try {\n // Future: Possibly add in other modifiers for left/right/top/bottom\n // offsets, root element reference, and thresholds\n this.observer = new IntersectionObserver(this.handler.bind(this), {\n // `null` = 'viewport'\n root: null,\n // Pixels away from view port to consider \"visible\"\n rootMargin: this.margin,\n // Intersection ratio of el and root (as a value from 0 to 1)\n threshold: 0\n });\n } catch (_unused) {\n // No IntersectionObserver support, so just stop trying to observe\n this.doneOnce = true;\n this.observer = undefined;\n this.callback(null);\n return;\n } // Start observing in a `$nextTick()` (to allow DOM to complete rendering)\n\n /* istanbul ignore next: IntersectionObserver not supported in JSDOM */\n\n\n nextTick(function () {\n requestAF(function () {\n // Placed in an `if` just in case we were destroyed before\n // this `requestAnimationFrame` runs\n if (_this.observer) {\n _this.observer.observe(_this.el);\n }\n });\n });\n }\n /* istanbul ignore next */\n\n }, {\n key: \"handler\",\n value: function handler(entries) {\n var entry = entries ? entries[0] : {};\n var isIntersecting = Boolean(entry.isIntersecting || entry.intersectionRatio > 0.0);\n\n if (isIntersecting !== this.visible) {\n this.visible = isIntersecting;\n this.callback(isIntersecting);\n\n if (this.once && this.visible) {\n this.doneOnce = true;\n this.stop();\n }\n }\n }\n }, {\n key: \"stop\",\n value: function stop() {\n /* istanbul ignore next */\n this.observer && this.observer.disconnect();\n this.observer = null;\n }\n }]);\n\n return VisibilityObserver;\n }();\n\n var destroy$1 = function destroy(el) {\n var observer = el[OBSERVER_PROP_NAME];\n\n if (observer && observer.stop) {\n observer.stop();\n }\n\n delete el[OBSERVER_PROP_NAME];\n };\n\n var bind$1 = function bind(el, _ref) {\n var value = _ref.value,\n modifiers = _ref.modifiers;\n // `value` is the callback function\n var options = {\n margin: '0px',\n once: false,\n callback: value\n }; // Parse modifiers\n\n keys(modifiers).forEach(function (mod) {\n /* istanbul ignore else: Until is switched to use this directive */\n if (RX_DIGITS.test(mod)) {\n options.margin = \"\".concat(mod, \"px\");\n } else if (mod.toLowerCase() === 'once') {\n options.once = true;\n }\n }); // Destroy any previous observer\n\n destroy$1(el); // Create new observer\n\n el[OBSERVER_PROP_NAME] = new VisibilityObserver(el, options); // Store the current modifiers on the object (cloned)\n\n el[OBSERVER_PROP_NAME]._prevModifiers = clone(modifiers);\n }; // When the directive options may have been updated (or element)\n\n\n var componentUpdated$1 = function componentUpdated(el, _ref2, vnode) {\n var value = _ref2.value,\n oldValue = _ref2.oldValue,\n modifiers = _ref2.modifiers;\n // Compare value/oldValue and modifiers to see if anything has changed\n // and if so, destroy old observer and create new observer\n\n /* istanbul ignore next */\n modifiers = clone(modifiers);\n /* istanbul ignore next */\n\n if (el && (value !== oldValue || !el[OBSERVER_PROP_NAME] || !looseEqual(modifiers, el[OBSERVER_PROP_NAME]._prevModifiers))) {\n // Re-bind on element\n bind$1(el, {\n value: value,\n modifiers: modifiers\n });\n }\n }; // When directive un-binds from element\n\n\n var unbind$1 = function unbind(el) {\n // Remove the observer\n destroy$1(el);\n }; // Export the directive\n\n\n var VBVisible = {\n bind: bind$1,\n componentUpdated: componentUpdated$1,\n unbind: unbind$1\n };\n\n var _watch$i;\n\n var MODEL_PROP_NAME_SHOW$1 = 'show';\n var MODEL_EVENT_NAME_SHOW$1 = MODEL_EVENT_NAME_PREFIX + MODEL_PROP_NAME_SHOW$1; // --- Props ---\n\n var imgProps$1 = omit(props$1Z, ['blank']);\n var props$1W = makePropsConfigurable(_objectSpread2$3(_objectSpread2$3({}, imgProps$1), {}, _defineProperty({\n blankHeight: makeProp(PROP_TYPE_NUMBER_STRING),\n // If `null`, a blank image is generated\n blankSrc: makeProp(PROP_TYPE_STRING, null),\n blankWidth: makeProp(PROP_TYPE_NUMBER_STRING),\n // Distance away from viewport (in pixels)\n // before being considered \"visible\"\n offset: makeProp(PROP_TYPE_NUMBER_STRING, 360)\n }, MODEL_PROP_NAME_SHOW$1, makeProp(PROP_TYPE_BOOLEAN, false))), NAME_IMG_LAZY); // --- Main component ---\n // @vue/component\n\n var BImgLazy = /*#__PURE__*/extend({\n name: NAME_IMG_LAZY,\n directives: {\n 'b-visible': VBVisible\n },\n props: props$1W,\n data: function data() {\n return {\n isShown: this[MODEL_PROP_NAME_SHOW$1]\n };\n },\n computed: {\n computedSrc: function computedSrc() {\n var blankSrc = this.blankSrc;\n return !blankSrc || this.isShown ? this.src : blankSrc;\n },\n computedBlank: function computedBlank() {\n return !(this.isShown || this.blankSrc);\n },\n computedWidth: function computedWidth() {\n var width = this.width;\n return this.isShown ? width : this.blankWidth || width;\n },\n computedHeight: function computedHeight() {\n var height = this.height;\n return this.isShown ? height : this.blankHeight || height;\n },\n computedSrcset: function computedSrcset() {\n var srcset = concat(this.srcset).filter(identity).join(',');\n return srcset && (!this.blankSrc || this.isShown) ? srcset : null;\n },\n computedSizes: function computedSizes() {\n var sizes = concat(this.sizes).filter(identity).join(',');\n return sizes && (!this.blankSrc || this.isShown) ? sizes : null;\n }\n },\n watch: (_watch$i = {}, _defineProperty(_watch$i, MODEL_PROP_NAME_SHOW$1, function (newValue, oldValue) {\n if (newValue !== oldValue) {\n // If `IntersectionObserver` support is not available, image is always shown\n var visible = HAS_INTERACTION_OBSERVER_SUPPORT ? newValue : true;\n this.isShown = visible; // Ensure the show prop is synced (when no `IntersectionObserver`)\n\n if (newValue !== visible) {\n this.$nextTick(this.updateShowProp);\n }\n }\n }), _defineProperty(_watch$i, \"isShown\", function isShown(newValue, oldValue) {\n // Update synched show prop\n if (newValue !== oldValue) {\n this.updateShowProp();\n }\n }), _watch$i),\n mounted: function mounted() {\n var _this = this;\n\n // If `IntersectionObserver` is not available, image is always shown\n this.$nextTick(function () {\n _this.isShown = HAS_INTERACTION_OBSERVER_SUPPORT ? _this[MODEL_PROP_NAME_SHOW$1] : true;\n });\n },\n methods: {\n updateShowProp: function updateShowProp() {\n this.$emit(MODEL_EVENT_NAME_SHOW$1, this.isShown);\n },\n doShow: function doShow(visible) {\n var _this2 = this;\n\n // If IntersectionObserver is not supported, the callback\n // will be called with `null` rather than `true` or `false`\n if ((visible || visible === null) && !this.isShown) {\n // In a `requestAF()` to render the `blank` placeholder properly\n // for fast loading images in some browsers (i.e. Firefox)\n requestAF(function () {\n _this2.isShown = true;\n });\n }\n }\n },\n render: function render(h) {\n var directives = [];\n\n if (!this.isShown) {\n var _modifiers;\n\n // We only add the visible directive if we are not shown\n directives.push({\n // Visible directive will silently do nothing if\n // `IntersectionObserver` is not supported\n name: 'b-visible',\n // Value expects a callback (passed one arg of `visible` = `true` or `false`)\n value: this.doShow,\n modifiers: (_modifiers = {}, _defineProperty(_modifiers, \"\".concat(toInteger(this.offset, 0)), true), _defineProperty(_modifiers, \"once\", true), _modifiers)\n });\n }\n\n return h(BImg, {\n directives: directives,\n props: _objectSpread2$3(_objectSpread2$3({}, pluckProps(imgProps$1, this.$props)), {}, {\n // Computed value props\n src: this.computedSrc,\n blank: this.computedBlank,\n width: this.computedWidth,\n height: this.computedHeight,\n srcset: this.computedSrcset,\n sizes: this.computedSizes\n })\n });\n }\n });\n\n var props$1V = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, omit(props$1W, keys(props$1Z))), omit(props$1Y, ['src', 'alt', 'width', 'height']))), NAME_CARD_IMG_LAZY); // --- Main component ---\n // @vue/component\n\n var BCardImgLazy = /*#__PURE__*/extend({\n name: NAME_CARD_IMG_LAZY,\n functional: true,\n props: props$1V,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data;\n var baseClass = 'card-img';\n\n if (props.top) {\n baseClass += '-top';\n } else if (props.right || props.end) {\n baseClass += '-right';\n } else if (props.bottom) {\n baseClass += '-bottom';\n } else if (props.left || props.start) {\n baseClass += '-left';\n }\n\n return h(BImgLazy, a(data, {\n class: [baseClass],\n // Exclude `left` and `right` props before passing to ``\n props: omit(props, ['left', 'right'])\n }));\n }\n });\n\n var props$1U = makePropsConfigurable({\n textTag: makeProp(PROP_TYPE_STRING, 'p')\n }, NAME_CARD_TEXT); // --- Main component ---\n // @vue/component\n\n var BCardText = /*#__PURE__*/extend({\n name: NAME_CARD_TEXT,\n functional: true,\n props: props$1U,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h(props.textTag, a(data, {\n staticClass: 'card-text'\n }), children);\n }\n });\n\n var props$1T = makePropsConfigurable({\n columns: makeProp(PROP_TYPE_BOOLEAN, false),\n deck: makeProp(PROP_TYPE_BOOLEAN, false),\n tag: makeProp(PROP_TYPE_STRING, 'div')\n }, NAME_CARD_GROUP); // --- Main component ---\n // @vue/component\n\n var BCardGroup = /*#__PURE__*/extend({\n name: NAME_CARD_GROUP,\n functional: true,\n props: props$1T,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h(props.tag, a(data, {\n class: props.deck ? 'card-deck' : props.columns ? 'card-columns' : 'card-group'\n }), children);\n }\n });\n\n var CardPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BCard: BCard,\n BCardHeader: BCardHeader,\n BCardBody: BCardBody,\n BCardTitle: BCardTitle,\n BCardSubTitle: BCardSubTitle,\n BCardFooter: BCardFooter,\n BCardImg: BCardImg,\n BCardImgLazy: BCardImgLazy,\n BCardText: BCardText,\n BCardGroup: BCardGroup\n }\n });\n\n var noop = function noop() {};\n\n /**\n * Observe a DOM element changes, falls back to eventListener mode\n * @param {Element} el The DOM element to observe\n * @param {Function} callback callback to be called on change\n * @param {object} [options={childList: true, subtree: true}] observe options\n * @see https://stackoverflow.com/questions/3219758\n */\n\n var observeDom = function observeDom(el, callback, options)\n /* istanbul ignore next: difficult to test in JSDOM */\n {\n // Handle cases where we might be passed a Vue instance\n el = el ? el.$el || el : null; // Early exit when we have no element\n\n /* istanbul ignore next: difficult to test in JSDOM */\n\n if (!isElement(el)) {\n return null;\n } // Exit and throw a warning when `MutationObserver` isn't available\n\n\n if (warnNoMutationObserverSupport('observeDom')) {\n return null;\n } // Define a new observer\n\n\n var obs = new MutationObs(function (mutations) {\n var changed = false; // A mutation can contain several change records, so we loop\n // through them to see what has changed\n // We break out of the loop early if any \"significant\" change\n // has been detected\n\n for (var i = 0; i < mutations.length && !changed; i++) {\n // The mutation record\n var mutation = mutations[i]; // Mutation type\n\n var type = mutation.type; // DOM node (could be any DOM node type - HTMLElement, Text, comment, etc.)\n\n var target = mutation.target; // Detect whether a change happened based on type and target\n\n if (type === 'characterData' && target.nodeType === Node.TEXT_NODE) {\n // We ignore nodes that are not TEXT (i.e. comments, etc.)\n // as they don't change layout\n changed = true;\n } else if (type === 'attributes') {\n changed = true;\n } else if (type === 'childList' && (mutation.addedNodes.length > 0 || mutation.removedNodes.length > 0)) {\n // This includes HTMLElement and text nodes being\n // added/removed/re-arranged\n changed = true;\n }\n } // We only call the callback if a change that could affect\n // layout/size truly happened\n\n\n if (changed) {\n callback();\n }\n }); // Have the observer observe foo for changes in children, etc\n\n obs.observe(el, _objectSpread2$3({\n childList: true,\n subtree: true\n }, options)); // We return a reference to the observer so that `obs.disconnect()`\n // can be called if necessary\n // To reduce overhead when the root element is hidden\n\n return obs;\n };\n\n var _watch$h;\n\n var _makeModelMixin$i = makeModelMixin('value', {\n type: PROP_TYPE_NUMBER,\n defaultValue: 0\n }),\n modelMixin$h = _makeModelMixin$i.mixin,\n modelProps$h = _makeModelMixin$i.props,\n MODEL_PROP_NAME$h = _makeModelMixin$i.prop,\n MODEL_EVENT_NAME$h = _makeModelMixin$i.event; // Slide directional classes\n\n\n var DIRECTION = {\n next: {\n dirClass: 'carousel-item-left',\n overlayClass: 'carousel-item-next'\n },\n prev: {\n dirClass: 'carousel-item-right',\n overlayClass: 'carousel-item-prev'\n }\n }; // Fallback Transition duration (with a little buffer) in ms\n\n var TRANS_DURATION = 600 + 50; // Time for mouse compat events to fire after touch\n\n var TOUCH_EVENT_COMPAT_WAIT = 500; // Number of pixels to consider touch move a swipe\n\n var SWIPE_THRESHOLD = 40; // PointerEvent pointer types\n\n var PointerType = {\n TOUCH: 'touch',\n PEN: 'pen'\n }; // Transition Event names\n\n var TransitionEndEvents$1 = {\n WebkitTransition: 'webkitTransitionEnd',\n MozTransition: 'transitionend',\n OTransition: 'otransitionend oTransitionEnd',\n transition: 'transitionend'\n }; // --- Helper methods ---\n // Return the browser specific transitionEnd event name\n\n var getTransitionEndEvent = function getTransitionEndEvent(el) {\n for (var name in TransitionEndEvents$1) {\n if (!isUndefined(el.style[name])) {\n return TransitionEndEvents$1[name];\n }\n } // Fallback\n\n /* istanbul ignore next */\n\n\n return null;\n }; // --- Props ---\n\n\n var props$1S = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$25), modelProps$h), {}, {\n background: makeProp(PROP_TYPE_STRING),\n controls: makeProp(PROP_TYPE_BOOLEAN, false),\n // Enable cross-fade animation instead of slide animation\n fade: makeProp(PROP_TYPE_BOOLEAN, false),\n // Sniffed by carousel-slide\n imgHeight: makeProp(PROP_TYPE_NUMBER_STRING),\n // Sniffed by carousel-slide\n imgWidth: makeProp(PROP_TYPE_NUMBER_STRING),\n indicators: makeProp(PROP_TYPE_BOOLEAN, false),\n interval: makeProp(PROP_TYPE_NUMBER, 5000),\n labelGotoSlide: makeProp(PROP_TYPE_STRING, 'Goto slide'),\n labelIndicators: makeProp(PROP_TYPE_STRING, 'Select a slide to display'),\n labelNext: makeProp(PROP_TYPE_STRING, 'Next slide'),\n labelPrev: makeProp(PROP_TYPE_STRING, 'Previous slide'),\n // Disable slide/fade animation\n noAnimation: makeProp(PROP_TYPE_BOOLEAN, false),\n // Disable pause on hover\n noHoverPause: makeProp(PROP_TYPE_BOOLEAN, false),\n // Sniffed by carousel-slide\n noTouch: makeProp(PROP_TYPE_BOOLEAN, false),\n // Disable wrapping/looping when start/end is reached\n noWrap: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_CAROUSEL); // --- Main component ---\n // @vue/component\n\n var BCarousel = /*#__PURE__*/extend({\n name: NAME_CAROUSEL,\n mixins: [idMixin, modelMixin$h, normalizeSlotMixin],\n provide: function provide() {\n var _this = this;\n\n return {\n getBvCarousel: function getBvCarousel() {\n return _this;\n }\n };\n },\n props: props$1S,\n data: function data() {\n return {\n index: this[MODEL_PROP_NAME$h] || 0,\n isSliding: false,\n transitionEndEvent: null,\n slides: [],\n direction: null,\n isPaused: !(toInteger(this.interval, 0) > 0),\n // Touch event handling values\n touchStartX: 0,\n touchDeltaX: 0\n };\n },\n computed: {\n numSlides: function numSlides() {\n return this.slides.length;\n }\n },\n watch: (_watch$h = {}, _defineProperty(_watch$h, MODEL_PROP_NAME$h, function (newValue, oldValue) {\n if (newValue !== oldValue) {\n this.setSlide(toInteger(newValue, 0));\n }\n }), _defineProperty(_watch$h, \"interval\", function interval(newValue, oldValue) {\n /* istanbul ignore next */\n if (newValue === oldValue) {\n return;\n }\n\n if (!newValue) {\n // Pausing slide show\n this.pause(false);\n } else {\n // Restarting or Changing interval\n this.pause(true);\n this.start(false);\n }\n }), _defineProperty(_watch$h, \"isPaused\", function isPaused(newValue, oldValue) {\n if (newValue !== oldValue) {\n this.$emit(newValue ? EVENT_NAME_PAUSED : EVENT_NAME_UNPAUSED);\n }\n }), _defineProperty(_watch$h, \"index\", function index(to, from) {\n /* istanbul ignore next */\n if (to === from || this.isSliding) {\n return;\n }\n\n this.doSlide(to, from);\n }), _watch$h),\n created: function created() {\n // Create private non-reactive props\n this.$_interval = null;\n this.$_animationTimeout = null;\n this.$_touchTimeout = null;\n this.$_observer = null; // Set initial paused state\n\n this.isPaused = !(toInteger(this.interval, 0) > 0);\n },\n mounted: function mounted() {\n // Cache current browser transitionend event name\n this.transitionEndEvent = getTransitionEndEvent(this.$el) || null; // Get all slides\n\n this.updateSlides(); // Observe child changes so we can update slide list\n\n this.setObserver(true);\n },\n beforeDestroy: function beforeDestroy() {\n this.clearInterval();\n this.clearAnimationTimeout();\n this.clearTouchTimeout();\n this.setObserver(false);\n },\n methods: {\n clearInterval: function (_clearInterval) {\n function clearInterval() {\n return _clearInterval.apply(this, arguments);\n }\n\n clearInterval.toString = function () {\n return _clearInterval.toString();\n };\n\n return clearInterval;\n }(function () {\n clearInterval(this.$_interval);\n this.$_interval = null;\n }),\n clearAnimationTimeout: function clearAnimationTimeout() {\n clearTimeout(this.$_animationTimeout);\n this.$_animationTimeout = null;\n },\n clearTouchTimeout: function clearTouchTimeout() {\n clearTimeout(this.$_touchTimeout);\n this.$_touchTimeout = null;\n },\n setObserver: function setObserver() {\n var on = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n this.$_observer && this.$_observer.disconnect();\n this.$_observer = null;\n\n if (on) {\n this.$_observer = observeDom(this.$refs.inner, this.updateSlides.bind(this), {\n subtree: false,\n childList: true,\n attributes: true,\n attributeFilter: ['id']\n });\n }\n },\n // Set slide\n setSlide: function setSlide(slide) {\n var _this2 = this;\n\n var direction = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n\n // Don't animate when page is not visible\n\n /* istanbul ignore if: difficult to test */\n if (IS_BROWSER && document.visibilityState && document.hidden) {\n return;\n }\n\n var noWrap = this.noWrap;\n var numSlides = this.numSlides; // Make sure we have an integer (you never know!)\n\n slide = mathFloor(slide); // Don't do anything if nothing to slide to\n\n if (numSlides === 0) {\n return;\n } // Don't change slide while transitioning, wait until transition is done\n\n\n if (this.isSliding) {\n // Schedule slide after sliding complete\n this.$once(EVENT_NAME_SLIDING_END, function () {\n // Wrap in `requestAF()` to allow the slide to properly finish to avoid glitching\n requestAF(function () {\n return _this2.setSlide(slide, direction);\n });\n });\n return;\n }\n\n this.direction = direction; // Set new slide index\n // Wrap around if necessary (if no-wrap not enabled)\n\n this.index = slide >= numSlides ? noWrap ? numSlides - 1 : 0 : slide < 0 ? noWrap ? 0 : numSlides - 1 : slide; // Ensure the v-model is synched up if no-wrap is enabled\n // and user tried to slide pass either ends\n\n if (noWrap && this.index !== slide && this.index !== this[MODEL_PROP_NAME$h]) {\n this.$emit(MODEL_EVENT_NAME$h, this.index);\n }\n },\n // Previous slide\n prev: function prev() {\n this.setSlide(this.index - 1, 'prev');\n },\n // Next slide\n next: function next() {\n this.setSlide(this.index + 1, 'next');\n },\n // Pause auto rotation\n pause: function pause(event) {\n if (!event) {\n this.isPaused = true;\n }\n\n this.clearInterval();\n },\n // Start auto rotate slides\n start: function start(event) {\n if (!event) {\n this.isPaused = false;\n }\n /* istanbul ignore next: most likely will never happen, but just in case */\n\n\n this.clearInterval(); // Don't start if no interval, or less than 2 slides\n\n if (this.interval && this.numSlides > 1) {\n this.$_interval = setInterval(this.next, mathMax(1000, this.interval));\n }\n },\n // Restart auto rotate slides when focus/hover leaves the carousel\n\n /* istanbul ignore next */\n restart: function restart() {\n if (!this.$el.contains(getActiveElement())) {\n this.start();\n }\n },\n doSlide: function doSlide(to, from) {\n var _this3 = this;\n\n var isCycling = Boolean(this.interval); // Determine sliding direction\n\n var direction = this.calcDirection(this.direction, from, to);\n var overlayClass = direction.overlayClass;\n var dirClass = direction.dirClass; // Determine current and next slides\n\n var currentSlide = this.slides[from];\n var nextSlide = this.slides[to]; // Don't do anything if there aren't any slides to slide to\n\n if (!currentSlide || !nextSlide) {\n /* istanbul ignore next */\n return;\n } // Start animating\n\n\n this.isSliding = true;\n\n if (isCycling) {\n this.pause(false);\n }\n\n this.$emit(EVENT_NAME_SLIDING_START, to); // Update v-model\n\n this.$emit(MODEL_EVENT_NAME$h, this.index);\n\n if (this.noAnimation) {\n addClass(nextSlide, 'active');\n removeClass(currentSlide, 'active');\n this.isSliding = false; // Notify ourselves that we're done sliding (slid)\n\n this.$nextTick(function () {\n return _this3.$emit(EVENT_NAME_SLIDING_END, to);\n });\n } else {\n addClass(nextSlide, overlayClass); // Trigger a reflow of next slide\n\n reflow(nextSlide);\n addClass(currentSlide, dirClass);\n addClass(nextSlide, dirClass); // Transition End handler\n\n var called = false;\n /* istanbul ignore next: difficult to test */\n\n var onceTransEnd = function onceTransEnd() {\n if (called) {\n return;\n }\n\n called = true;\n /* istanbul ignore if: transition events cant be tested in JSDOM */\n\n if (_this3.transitionEndEvent) {\n var events = _this3.transitionEndEvent.split(/\\s+/);\n\n events.forEach(function (event) {\n return eventOff(nextSlide, event, onceTransEnd, EVENT_OPTIONS_NO_CAPTURE);\n });\n }\n\n _this3.clearAnimationTimeout();\n\n removeClass(nextSlide, dirClass);\n removeClass(nextSlide, overlayClass);\n addClass(nextSlide, 'active');\n removeClass(currentSlide, 'active');\n removeClass(currentSlide, dirClass);\n removeClass(currentSlide, overlayClass);\n setAttr(currentSlide, 'aria-current', 'false');\n setAttr(nextSlide, 'aria-current', 'true');\n setAttr(currentSlide, 'aria-hidden', 'true');\n setAttr(nextSlide, 'aria-hidden', 'false');\n _this3.isSliding = false;\n _this3.direction = null; // Notify ourselves that we're done sliding (slid)\n\n _this3.$nextTick(function () {\n return _this3.$emit(EVENT_NAME_SLIDING_END, to);\n });\n }; // Set up transitionend handler\n\n /* istanbul ignore if: transition events cant be tested in JSDOM */\n\n\n if (this.transitionEndEvent) {\n var events = this.transitionEndEvent.split(/\\s+/);\n events.forEach(function (event) {\n return eventOn(nextSlide, event, onceTransEnd, EVENT_OPTIONS_NO_CAPTURE);\n });\n } // Fallback to setTimeout()\n\n\n this.$_animationTimeout = setTimeout(onceTransEnd, TRANS_DURATION);\n }\n\n if (isCycling) {\n this.start(false);\n }\n },\n // Update slide list\n updateSlides: function updateSlides() {\n this.pause(true); // Get all slides as DOM elements\n\n this.slides = selectAll('.carousel-item', this.$refs.inner);\n var numSlides = this.slides.length; // Keep slide number in range\n\n var index = mathMax(0, mathMin(mathFloor(this.index), numSlides - 1));\n this.slides.forEach(function (slide, idx) {\n var n = idx + 1;\n\n if (idx === index) {\n addClass(slide, 'active');\n setAttr(slide, 'aria-current', 'true');\n } else {\n removeClass(slide, 'active');\n setAttr(slide, 'aria-current', 'false');\n }\n\n setAttr(slide, 'aria-posinset', String(n));\n setAttr(slide, 'aria-setsize', String(numSlides));\n }); // Set slide as active\n\n this.setSlide(index);\n this.start(this.isPaused);\n },\n calcDirection: function calcDirection() {\n var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;\n var curIndex = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;\n var nextIndex = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;\n\n if (!direction) {\n return nextIndex > curIndex ? DIRECTION.next : DIRECTION.prev;\n }\n\n return DIRECTION[direction];\n },\n handleClick: function handleClick(event, fn) {\n var keyCode = event.keyCode;\n\n if (event.type === 'click' || keyCode === CODE_SPACE || keyCode === CODE_ENTER) {\n stopEvent(event);\n fn();\n }\n },\n\n /* istanbul ignore next: JSDOM doesn't support touch events */\n handleSwipe: function handleSwipe() {\n var absDeltaX = mathAbs(this.touchDeltaX);\n\n if (absDeltaX <= SWIPE_THRESHOLD) {\n return;\n }\n\n var direction = absDeltaX / this.touchDeltaX; // Reset touch delta X\n // https://github.com/twbs/bootstrap/pull/28558\n\n this.touchDeltaX = 0;\n\n if (direction > 0) {\n // Swipe left\n this.prev();\n } else if (direction < 0) {\n // Swipe right\n this.next();\n }\n },\n\n /* istanbul ignore next: JSDOM doesn't support touch events */\n touchStart: function touchStart(event) {\n if (HAS_POINTER_EVENT_SUPPORT && PointerType[event.pointerType.toUpperCase()]) {\n this.touchStartX = event.clientX;\n } else if (!HAS_POINTER_EVENT_SUPPORT) {\n this.touchStartX = event.touches[0].clientX;\n }\n },\n\n /* istanbul ignore next: JSDOM doesn't support touch events */\n touchMove: function touchMove(event) {\n // Ensure swiping with one touch and not pinching\n if (event.touches && event.touches.length > 1) {\n this.touchDeltaX = 0;\n } else {\n this.touchDeltaX = event.touches[0].clientX - this.touchStartX;\n }\n },\n\n /* istanbul ignore next: JSDOM doesn't support touch events */\n touchEnd: function touchEnd(event) {\n if (HAS_POINTER_EVENT_SUPPORT && PointerType[event.pointerType.toUpperCase()]) {\n this.touchDeltaX = event.clientX - this.touchStartX;\n }\n\n this.handleSwipe(); // If it's a touch-enabled device, mouseenter/leave are fired as\n // part of the mouse compatibility events on first tap - the carousel\n // would stop cycling until user tapped out of it;\n // here, we listen for touchend, explicitly pause the carousel\n // (as if it's the second time we tap on it, mouseenter compat event\n // is NOT fired) and after a timeout (to allow for mouse compatibility\n // events to fire) we explicitly restart cycling\n\n this.pause(false);\n this.clearTouchTimeout();\n this.$_touchTimeout = setTimeout(this.start, TOUCH_EVENT_COMPAT_WAIT + mathMax(1000, this.interval));\n }\n },\n render: function render(h) {\n var _this4 = this;\n\n var indicators = this.indicators,\n background = this.background,\n noAnimation = this.noAnimation,\n noHoverPause = this.noHoverPause,\n noTouch = this.noTouch,\n index = this.index,\n isSliding = this.isSliding,\n pause = this.pause,\n restart = this.restart,\n touchStart = this.touchStart,\n touchEnd = this.touchEnd;\n var idInner = this.safeId('__BV_inner_'); // Wrapper for slides\n\n var $inner = h('div', {\n staticClass: 'carousel-inner',\n attrs: {\n id: idInner,\n role: 'list'\n },\n ref: 'inner'\n }, [this.normalizeSlot()]); // Prev and next controls\n\n var $controls = h();\n\n if (this.controls) {\n var makeControl = function makeControl(direction, label, handler) {\n var handlerWrapper = function handlerWrapper(event) {\n /* istanbul ignore next */\n if (!isSliding) {\n _this4.handleClick(event, handler);\n } else {\n stopEvent(event, {\n propagation: false\n });\n }\n };\n\n return h('a', {\n staticClass: \"carousel-control-\".concat(direction),\n attrs: {\n href: '#',\n role: 'button',\n 'aria-controls': idInner,\n 'aria-disabled': isSliding ? 'true' : null\n },\n on: {\n click: handlerWrapper,\n keydown: handlerWrapper\n }\n }, [h('span', {\n staticClass: \"carousel-control-\".concat(direction, \"-icon\"),\n attrs: {\n 'aria-hidden': 'true'\n }\n }), h('span', {\n class: 'sr-only'\n }, [label])]);\n };\n\n $controls = [makeControl('prev', this.labelPrev, this.prev), makeControl('next', this.labelNext, this.next)];\n } // Indicators\n\n\n var $indicators = h('ol', {\n staticClass: 'carousel-indicators',\n directives: [{\n name: 'show',\n value: indicators\n }],\n attrs: {\n id: this.safeId('__BV_indicators_'),\n 'aria-hidden': indicators ? 'false' : 'true',\n 'aria-label': this.labelIndicators,\n 'aria-owns': idInner\n }\n }, this.slides.map(function (slide, i) {\n var handler = function handler(event) {\n _this4.handleClick(event, function () {\n _this4.setSlide(i);\n });\n };\n\n return h('li', {\n class: {\n active: i === index\n },\n attrs: {\n role: 'button',\n id: _this4.safeId(\"__BV_indicator_\".concat(i + 1, \"_\")),\n tabindex: indicators ? '0' : '-1',\n 'aria-current': i === index ? 'true' : 'false',\n 'aria-label': \"\".concat(_this4.labelGotoSlide, \" \").concat(i + 1),\n 'aria-describedby': slide.id || null,\n 'aria-controls': idInner\n },\n on: {\n click: handler,\n keydown: handler\n },\n key: \"slide_\".concat(i)\n });\n }));\n var on = {\n mouseenter: noHoverPause ? noop : pause,\n mouseleave: noHoverPause ? noop : restart,\n focusin: pause,\n focusout: restart,\n keydown: function keydown(event) {\n /* istanbul ignore next */\n if (/input|textarea/i.test(event.target.tagName)) {\n return;\n }\n\n var keyCode = event.keyCode;\n\n if (keyCode === CODE_LEFT || keyCode === CODE_RIGHT) {\n stopEvent(event);\n\n _this4[keyCode === CODE_LEFT ? 'prev' : 'next']();\n }\n }\n }; // Touch support event handlers for environment\n\n if (HAS_TOUCH_SUPPORT && !noTouch) {\n // Attach appropriate listeners (prepend event name with '&' for passive mode)\n\n /* istanbul ignore next: JSDOM doesn't support touch events */\n if (HAS_POINTER_EVENT_SUPPORT) {\n on['&pointerdown'] = touchStart;\n on['&pointerup'] = touchEnd;\n } else {\n on['&touchstart'] = touchStart;\n on['&touchmove'] = this.touchMove;\n on['&touchend'] = touchEnd;\n }\n } // Return the carousel\n\n\n return h('div', {\n staticClass: 'carousel',\n class: {\n slide: !noAnimation,\n 'carousel-fade': !noAnimation && this.fade,\n 'pointer-event': HAS_TOUCH_SUPPORT && HAS_POINTER_EVENT_SUPPORT && !noTouch\n },\n style: {\n background: background\n },\n attrs: {\n role: 'region',\n id: this.safeId(),\n 'aria-busy': isSliding ? 'true' : 'false'\n },\n on: on\n }, [$inner, $controls, $indicators]);\n }\n });\n\n var imgProps = {\n imgAlt: makeProp(PROP_TYPE_STRING),\n imgBlank: makeProp(PROP_TYPE_BOOLEAN, false),\n imgBlankColor: makeProp(PROP_TYPE_STRING, 'transparent'),\n imgHeight: makeProp(PROP_TYPE_NUMBER_STRING),\n imgSrc: makeProp(PROP_TYPE_STRING),\n imgWidth: makeProp(PROP_TYPE_NUMBER_STRING)\n };\n var props$1R = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$25), imgProps), {}, {\n background: makeProp(PROP_TYPE_STRING),\n caption: makeProp(PROP_TYPE_STRING),\n captionHtml: makeProp(PROP_TYPE_STRING),\n captionTag: makeProp(PROP_TYPE_STRING, 'h3'),\n contentTag: makeProp(PROP_TYPE_STRING, 'div'),\n contentVisibleUp: makeProp(PROP_TYPE_STRING),\n text: makeProp(PROP_TYPE_STRING),\n textHtml: makeProp(PROP_TYPE_STRING),\n textTag: makeProp(PROP_TYPE_STRING, 'p')\n })), NAME_CAROUSEL_SLIDE); // --- Main component ---\n // @vue/component\n\n var BCarouselSlide = /*#__PURE__*/extend({\n name: NAME_CAROUSEL_SLIDE,\n mixins: [idMixin, normalizeSlotMixin],\n inject: {\n getBvCarousel: {\n // Explicitly disable touch if not a child of carousel\n default: function _default() {\n return function () {\n return {\n noTouch: true\n };\n };\n }\n }\n },\n props: props$1R,\n computed: {\n bvCarousel: function bvCarousel() {\n return this.getBvCarousel();\n },\n contentClasses: function contentClasses() {\n return [this.contentVisibleUp ? 'd-none' : '', this.contentVisibleUp ? \"d-\".concat(this.contentVisibleUp, \"-block\") : ''];\n },\n computedWidth: function computedWidth() {\n // Use local width, or try parent width\n return this.imgWidth || this.bvCarousel.imgWidth || null;\n },\n computedHeight: function computedHeight() {\n // Use local height, or try parent height\n return this.imgHeight || this.bvCarousel.imgHeight || null;\n }\n },\n render: function render(h) {\n var $img = this.normalizeSlot(SLOT_NAME_IMG);\n\n if (!$img && (this.imgSrc || this.imgBlank)) {\n var on = {}; // Touch support event handler\n\n /* istanbul ignore if: difficult to test in JSDOM */\n\n if (!this.bvCarousel.noTouch && HAS_TOUCH_SUPPORT) {\n on.dragstart = function (event) {\n return stopEvent(event, {\n propagation: false\n });\n };\n }\n\n $img = h(BImg, {\n props: _objectSpread2$3(_objectSpread2$3({}, pluckProps(imgProps, this.$props, unprefixPropName.bind(null, 'img'))), {}, {\n width: this.computedWidth,\n height: this.computedHeight,\n fluidGrow: true,\n block: true\n }),\n on: on\n });\n }\n\n var $contentChildren = [// Caption\n this.caption || this.captionHtml ? h(this.captionTag, {\n domProps: htmlOrText(this.captionHtml, this.caption)\n }) : false, // Text\n this.text || this.textHtml ? h(this.textTag, {\n domProps: htmlOrText(this.textHtml, this.text)\n }) : false, // Children\n this.normalizeSlot() || false];\n var $content = h();\n\n if ($contentChildren.some(identity)) {\n $content = h(this.contentTag, {\n staticClass: 'carousel-caption',\n class: this.contentClasses\n }, $contentChildren.map(function ($child) {\n return $child || h();\n }));\n }\n\n return h('div', {\n staticClass: 'carousel-item',\n style: {\n background: this.background || this.bvCarousel.background || null\n },\n attrs: {\n id: this.safeId(),\n role: 'listitem'\n }\n }, [$img, $content]);\n }\n });\n\n var CarouselPlugin =\n /*#__PURE*/\n pluginFactory({\n components: {\n BCarousel: BCarousel,\n BCarouselSlide: BCarouselSlide\n }\n });\n\n var CLASS_NAME_SHOW = 'show';\n\n // Generic collapse transion helper component\n // Transition event handler helpers\n\n var onEnter = function onEnter(el) {\n setStyle(el, 'height', 0); // In a `requestAF()` for `appear` to work\n\n requestAF(function () {\n reflow(el);\n setStyle(el, 'height', \"\".concat(el.scrollHeight, \"px\"));\n });\n };\n\n var onAfterEnter = function onAfterEnter(el) {\n removeStyle(el, 'height');\n };\n\n var onLeave = function onLeave(el) {\n setStyle(el, 'height', 'auto');\n setStyle(el, 'display', 'block');\n setStyle(el, 'height', \"\".concat(getBCR(el).height, \"px\"));\n reflow(el);\n setStyle(el, 'height', 0);\n };\n\n var onAfterLeave = function onAfterLeave(el) {\n removeStyle(el, 'height');\n }; // --- Constants ---\n // Default transition props\n // `appear` will use the enter classes\n\n\n var TRANSITION_PROPS = {\n css: true,\n enterClass: '',\n enterActiveClass: 'collapsing',\n enterToClass: 'collapse show',\n leaveClass: 'collapse show',\n leaveActiveClass: 'collapsing',\n leaveToClass: 'collapse'\n }; // Default transition handlers\n // `appear` will use the enter handlers\n\n var TRANSITION_HANDLERS = {\n enter: onEnter,\n afterEnter: onAfterEnter,\n leave: onLeave,\n afterLeave: onAfterLeave\n }; // --- Main component ---\n\n var props$1Q = {\n // // If `true` (and `visible` is `true` on mount), animate initially visible\n appear: makeProp(PROP_TYPE_BOOLEAN, false)\n }; // --- Main component ---\n // @vue/component\n\n var BVCollapse = /*#__PURE__*/extend({\n name: NAME_COLLAPSE_HELPER,\n functional: true,\n props: props$1Q,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h('transition', // We merge in the `appear` prop last\n a(data, {\n props: TRANSITION_PROPS,\n on: TRANSITION_HANDLERS\n }, {\n props: props\n }), // Note: `` supports a single root element only\n children);\n }\n });\n\n var _watch$g;\n\n var ROOT_ACTION_EVENT_NAME_TOGGLE$2 = getRootActionEventName(NAME_COLLAPSE, 'toggle');\n var ROOT_ACTION_EVENT_NAME_REQUEST_STATE$2 = getRootActionEventName(NAME_COLLAPSE, 'request-state');\n var ROOT_EVENT_NAME_ACCORDION = getRootEventName(NAME_COLLAPSE, 'accordion');\n var ROOT_EVENT_NAME_STATE$3 = getRootEventName(NAME_COLLAPSE, 'state');\n var ROOT_EVENT_NAME_SYNC_STATE$3 = getRootEventName(NAME_COLLAPSE, 'sync-state');\n\n var _makeModelMixin$h = makeModelMixin('visible', {\n type: PROP_TYPE_BOOLEAN,\n defaultValue: false\n }),\n modelMixin$g = _makeModelMixin$h.mixin,\n modelProps$g = _makeModelMixin$h.props,\n MODEL_PROP_NAME$g = _makeModelMixin$h.prop,\n MODEL_EVENT_NAME$g = _makeModelMixin$h.event; // --- Props ---\n\n\n var props$1P = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$25), modelProps$g), {}, {\n // If `true` (and `visible` is `true` on mount), animate initially visible\n accordion: makeProp(PROP_TYPE_STRING),\n appear: makeProp(PROP_TYPE_BOOLEAN, false),\n isNav: makeProp(PROP_TYPE_BOOLEAN, false),\n tag: makeProp(PROP_TYPE_STRING, 'div')\n })), NAME_COLLAPSE); // --- Main component ---\n // @vue/component\n\n var BCollapse = /*#__PURE__*/extend({\n name: NAME_COLLAPSE,\n mixins: [idMixin, modelMixin$g, normalizeSlotMixin, listenOnRootMixin],\n props: props$1P,\n data: function data() {\n return {\n show: this[MODEL_PROP_NAME$g],\n transitioning: false\n };\n },\n computed: {\n classObject: function classObject() {\n var transitioning = this.transitioning;\n return {\n 'navbar-collapse': this.isNav,\n collapse: !transitioning,\n show: this.show && !transitioning\n };\n },\n slotScope: function slotScope() {\n var _this = this;\n\n return {\n visible: this.show,\n close: function close() {\n _this.show = false;\n }\n };\n }\n },\n watch: (_watch$g = {}, _defineProperty(_watch$g, MODEL_PROP_NAME$g, function (newValue) {\n if (newValue !== this.show) {\n this.show = newValue;\n }\n }), _defineProperty(_watch$g, \"show\", function show(newValue, oldValue) {\n if (newValue !== oldValue) {\n this.emitState();\n }\n }), _watch$g),\n created: function created() {\n this.show = this[MODEL_PROP_NAME$g];\n },\n mounted: function mounted() {\n var _this2 = this;\n\n this.show = this[MODEL_PROP_NAME$g]; // Listen for toggle events to open/close us\n\n this.listenOnRoot(ROOT_ACTION_EVENT_NAME_TOGGLE$2, this.handleToggleEvent); // Listen to other collapses for accordion events\n\n this.listenOnRoot(ROOT_EVENT_NAME_ACCORDION, this.handleAccordionEvent);\n\n if (this.isNav) {\n // Set up handlers\n this.setWindowEvents(true);\n this.handleResize();\n }\n\n this.$nextTick(function () {\n _this2.emitState();\n }); // Listen for \"Sync state\" requests from `v-b-toggle`\n\n this.listenOnRoot(ROOT_ACTION_EVENT_NAME_REQUEST_STATE$2, function (id) {\n if (id === _this2.safeId()) {\n _this2.$nextTick(_this2.emitSync);\n }\n });\n },\n updated: function updated() {\n // Emit a private event every time this component updates to ensure\n // the toggle button is in sync with the collapse's state\n // It is emitted regardless if the visible state changes\n this.emitSync();\n },\n\n /* istanbul ignore next */\n deactivated: function deactivated() {\n if (this.isNav) {\n this.setWindowEvents(false);\n }\n },\n\n /* istanbul ignore next */\n activated: function activated() {\n if (this.isNav) {\n this.setWindowEvents(true);\n }\n\n this.emitSync();\n },\n beforeDestroy: function beforeDestroy() {\n // Trigger state emit if needed\n this.show = false;\n\n if (this.isNav && IS_BROWSER) {\n this.setWindowEvents(false);\n }\n },\n methods: {\n setWindowEvents: function setWindowEvents(on) {\n eventOnOff(on, window, 'resize', this.handleResize, EVENT_OPTIONS_NO_CAPTURE);\n eventOnOff(on, window, 'orientationchange', this.handleResize, EVENT_OPTIONS_NO_CAPTURE);\n },\n toggle: function toggle() {\n this.show = !this.show;\n },\n onEnter: function onEnter() {\n this.transitioning = true; // This should be moved out so we can add cancellable events\n\n this.$emit(EVENT_NAME_SHOW);\n },\n onAfterEnter: function onAfterEnter() {\n this.transitioning = false;\n this.$emit(EVENT_NAME_SHOWN);\n },\n onLeave: function onLeave() {\n this.transitioning = true; // This should be moved out so we can add cancellable events\n\n this.$emit(EVENT_NAME_HIDE);\n },\n onAfterLeave: function onAfterLeave() {\n this.transitioning = false;\n this.$emit(EVENT_NAME_HIDDEN);\n },\n emitState: function emitState() {\n var show = this.show,\n accordion = this.accordion;\n var id = this.safeId();\n this.$emit(MODEL_EVENT_NAME$g, show); // Let `v-b-toggle` know the state of this collapse\n\n this.emitOnRoot(ROOT_EVENT_NAME_STATE$3, id, show);\n\n if (accordion && show) {\n // Tell the other collapses in this accordion to close\n this.emitOnRoot(ROOT_EVENT_NAME_ACCORDION, id, accordion);\n }\n },\n emitSync: function emitSync() {\n // Emit a private event every time this component updates to ensure\n // the toggle button is in sync with the collapse's state\n // It is emitted regardless if the visible state changes\n this.emitOnRoot(ROOT_EVENT_NAME_SYNC_STATE$3, this.safeId(), this.show);\n },\n checkDisplayBlock: function checkDisplayBlock() {\n // Check to see if the collapse has `display: block !important` set\n // We can't set `display: none` directly on `this.$el`, as it would\n // trigger a new transition to start (or cancel a current one)\n var $el = this.$el;\n var restore = hasClass($el, CLASS_NAME_SHOW);\n removeClass($el, CLASS_NAME_SHOW);\n var isBlock = getCS($el).display === 'block';\n\n if (restore) {\n addClass($el, CLASS_NAME_SHOW);\n }\n\n return isBlock;\n },\n clickHandler: function clickHandler(event) {\n var el = event.target; // If we are in a nav/navbar, close the collapse when non-disabled link clicked\n\n /* istanbul ignore next: can't test `getComputedStyle()` in JSDOM */\n\n if (!this.isNav || !el || getCS(this.$el).display !== 'block') {\n return;\n } // Only close the collapse if it is not forced to be `display: block !important`\n\n\n if ((matches(el, '.nav-link,.dropdown-item') || closest('.nav-link,.dropdown-item', el)) && !this.checkDisplayBlock()) {\n this.show = false;\n }\n },\n handleToggleEvent: function handleToggleEvent(id) {\n if (id === this.safeId()) {\n this.toggle();\n }\n },\n handleAccordionEvent: function handleAccordionEvent(openedId, openAccordion) {\n var accordion = this.accordion,\n show = this.show;\n\n if (!accordion || accordion !== openAccordion) {\n return;\n }\n\n var isThis = openedId === this.safeId(); // Open this collapse if not shown or\n // close this collapse if shown\n\n if (isThis && !show || !isThis && show) {\n this.toggle();\n }\n },\n handleResize: function handleResize() {\n // Handler for orientation/resize to set collapsed state in nav/navbar\n this.show = getCS(this.$el).display === 'block';\n }\n },\n render: function render(h) {\n var appear = this.appear;\n var $content = h(this.tag, {\n class: this.classObject,\n directives: [{\n name: 'show',\n value: this.show\n }],\n attrs: {\n id: this.safeId()\n },\n on: {\n click: this.clickHandler\n }\n }, this.normalizeSlot(SLOT_NAME_DEFAULT, this.slotScope));\n return h(BVCollapse, {\n props: {\n appear: appear\n },\n on: {\n enter: this.onEnter,\n afterEnter: this.onAfterEnter,\n leave: this.onLeave,\n afterLeave: this.onAfterLeave\n }\n }, [$content]);\n }\n });\n\n var getInstanceFromDirective = function getInstanceFromDirective(vnode, bindings) {\n return isVue3 ? bindings.instance : vnode.context;\n };\n\n // Classes to apply to trigger element\n\n var CLASS_BV_TOGGLE_COLLAPSED = 'collapsed';\n var CLASS_BV_TOGGLE_NOT_COLLAPSED = 'not-collapsed'; // Property key for handler storage\n\n var BV_BASE = '__BV_toggle'; // Root event listener property (Function)\n\n var BV_TOGGLE_ROOT_HANDLER = \"\".concat(BV_BASE, \"_HANDLER__\"); // Trigger element click handler property (Function)\n\n var BV_TOGGLE_CLICK_HANDLER = \"\".concat(BV_BASE, \"_CLICK__\"); // Target visibility state property (Boolean)\n\n var BV_TOGGLE_STATE = \"\".concat(BV_BASE, \"_STATE__\"); // Target ID list property (Array)\n\n var BV_TOGGLE_TARGETS = \"\".concat(BV_BASE, \"_TARGETS__\"); // Commonly used strings\n\n var STRING_FALSE = 'false';\n var STRING_TRUE = 'true'; // Commonly used attribute names\n\n var ATTR_ARIA_CONTROLS = 'aria-controls';\n var ATTR_ARIA_EXPANDED = 'aria-expanded';\n var ATTR_ROLE = 'role';\n var ATTR_TABINDEX = 'tabindex'; // Commonly used style properties\n\n var STYLE_OVERFLOW_ANCHOR = 'overflow-anchor'; // Emitted control event for collapse (emitted to collapse)\n\n var ROOT_ACTION_EVENT_NAME_TOGGLE$1 = getRootActionEventName(NAME_COLLAPSE, 'toggle'); // Listen to event for toggle state update (emitted by collapse)\n\n var ROOT_EVENT_NAME_STATE$2 = getRootEventName(NAME_COLLAPSE, 'state'); // Private event emitted on `$root` to ensure the toggle state is always synced\n // Gets emitted even if the state of b-collapse has not changed\n // This event is NOT to be documented as people should not be using it\n\n var ROOT_EVENT_NAME_SYNC_STATE$2 = getRootEventName(NAME_COLLAPSE, 'sync-state'); // Private event we send to collapse to request state update sync event\n\n var ROOT_ACTION_EVENT_NAME_REQUEST_STATE$1 = getRootActionEventName(NAME_COLLAPSE, 'request-state');\n var KEYDOWN_KEY_CODES = [CODE_ENTER, CODE_SPACE]; // --- Helper methods ---\n\n var isNonStandardTag = function isNonStandardTag(el) {\n return !arrayIncludes(['button', 'a'], el.tagName.toLowerCase());\n };\n\n var getTargets = function getTargets(_ref, el) {\n var modifiers = _ref.modifiers,\n arg = _ref.arg,\n value = _ref.value;\n // Any modifiers are considered target IDs\n var targets = keys(modifiers || {}); // If value is a string, split out individual targets (if space delimited)\n\n value = isString(value) ? value.split(RX_SPACE_SPLIT) : value; // Support target ID as link href (`href=\"#id\"`)\n\n if (isTag(el.tagName, 'a')) {\n var href = getAttr(el, 'href') || '';\n\n if (RX_HASH_ID.test(href)) {\n targets.push(href.replace(RX_HASH, ''));\n }\n } // Add ID from `arg` (if provided), and support value\n // as a single string ID or an array of string IDs\n // If `value` is not an array or string, then it gets filtered out\n\n\n concat(arg, value).forEach(function (t) {\n return isString(t) && targets.push(t);\n }); // Return only unique and truthy target IDs\n\n return targets.filter(function (t, index, arr) {\n return t && arr.indexOf(t) === index;\n });\n };\n\n var removeClickListener = function removeClickListener(el) {\n var handler = el[BV_TOGGLE_CLICK_HANDLER];\n\n if (handler) {\n eventOff(el, 'click', handler, EVENT_OPTIONS_PASSIVE);\n eventOff(el, 'keydown', handler, EVENT_OPTIONS_PASSIVE);\n }\n\n el[BV_TOGGLE_CLICK_HANDLER] = null;\n };\n\n var addClickListener = function addClickListener(el, instance) {\n removeClickListener(el);\n\n if (instance) {\n var handler = function handler(event) {\n if (!(event.type === 'keydown' && !arrayIncludes(KEYDOWN_KEY_CODES, event.keyCode)) && !isDisabled(el)) {\n var targets = el[BV_TOGGLE_TARGETS] || [];\n targets.forEach(function (target) {\n getEventRoot(instance).$emit(ROOT_ACTION_EVENT_NAME_TOGGLE$1, target);\n });\n }\n };\n\n el[BV_TOGGLE_CLICK_HANDLER] = handler;\n eventOn(el, 'click', handler, EVENT_OPTIONS_PASSIVE);\n\n if (isNonStandardTag(el)) {\n eventOn(el, 'keydown', handler, EVENT_OPTIONS_PASSIVE);\n }\n }\n };\n\n var removeRootListeners = function removeRootListeners(el, instance) {\n if (el[BV_TOGGLE_ROOT_HANDLER] && instance) {\n getEventRoot(instance).$off([ROOT_EVENT_NAME_STATE$2, ROOT_EVENT_NAME_SYNC_STATE$2], el[BV_TOGGLE_ROOT_HANDLER]);\n }\n\n el[BV_TOGGLE_ROOT_HANDLER] = null;\n };\n\n var addRootListeners = function addRootListeners(el, instance) {\n removeRootListeners(el, instance);\n\n if (instance) {\n var handler = function handler(id, state) {\n // `state` will be `true` if target is expanded\n if (arrayIncludes(el[BV_TOGGLE_TARGETS] || [], id)) {\n // Set/Clear 'collapsed' visibility class state\n el[BV_TOGGLE_STATE] = state; // Set `aria-expanded` and class state on trigger element\n\n setToggleState(el, state);\n }\n };\n\n el[BV_TOGGLE_ROOT_HANDLER] = handler; // Listen for toggle state changes (public) and sync (private)\n\n getEventRoot(instance).$on([ROOT_EVENT_NAME_STATE$2, ROOT_EVENT_NAME_SYNC_STATE$2], handler);\n }\n };\n\n var setToggleState = function setToggleState(el, state) {\n // State refers to the visibility of the collapse/sidebar\n if (state) {\n removeClass(el, CLASS_BV_TOGGLE_COLLAPSED);\n addClass(el, CLASS_BV_TOGGLE_NOT_COLLAPSED);\n setAttr(el, ATTR_ARIA_EXPANDED, STRING_TRUE);\n } else {\n removeClass(el, CLASS_BV_TOGGLE_NOT_COLLAPSED);\n addClass(el, CLASS_BV_TOGGLE_COLLAPSED);\n setAttr(el, ATTR_ARIA_EXPANDED, STRING_FALSE);\n }\n }; // Reset and remove a property from the provided element\n\n\n var resetProp = function resetProp(el, prop) {\n el[prop] = null;\n delete el[prop];\n }; // Handle directive updates\n\n\n var handleUpdate = function handleUpdate(el, binding, vnode) {\n /* istanbul ignore next: should never happen */\n if (!IS_BROWSER || !getInstanceFromDirective(vnode, binding)) {\n return;\n } // If element is not a button or link, we add `role=\"button\"`\n // and `tabindex=\"0\"` for accessibility reasons\n\n\n if (isNonStandardTag(el)) {\n if (!hasAttr(el, ATTR_ROLE)) {\n setAttr(el, ATTR_ROLE, 'button');\n }\n\n if (!hasAttr(el, ATTR_TABINDEX)) {\n setAttr(el, ATTR_TABINDEX, '0');\n }\n } // Ensure the collapse class and `aria-*` attributes persist\n // after element is updated (either by parent re-rendering\n // or changes to this element or its contents)\n\n\n setToggleState(el, el[BV_TOGGLE_STATE]); // Parse list of target IDs\n\n var targets = getTargets(binding, el); // Ensure the `aria-controls` hasn't been overwritten\n // or removed when vnode updates\n // Also ensure to set `overflow-anchor` to `none` to prevent\n // the browser's scroll anchoring behavior\n\n /* istanbul ignore else */\n\n if (targets.length > 0) {\n setAttr(el, ATTR_ARIA_CONTROLS, targets.join(' '));\n setStyle(el, STYLE_OVERFLOW_ANCHOR, 'none');\n } else {\n removeAttr(el, ATTR_ARIA_CONTROLS);\n removeStyle(el, STYLE_OVERFLOW_ANCHOR);\n } // Add/Update our click listener(s)\n // Wrap in a `requestAF()` to allow any previous\n // click handling to occur first\n\n\n requestAF(function () {\n addClickListener(el, getInstanceFromDirective(vnode, binding));\n }); // If targets array has changed, update\n\n if (!looseEqual(targets, el[BV_TOGGLE_TARGETS])) {\n // Update targets array to element storage\n el[BV_TOGGLE_TARGETS] = targets; // Ensure `aria-controls` is up to date\n // Request a state update from targets so that we can\n // ensure expanded state is correct (in most cases)\n\n targets.forEach(function (target) {\n getEventRoot(getInstanceFromDirective(vnode, binding)).$emit(ROOT_ACTION_EVENT_NAME_REQUEST_STATE$1, target);\n });\n }\n };\n /*\n * Export our directive\n */\n\n\n var VBToggle = {\n bind: function bind(el, binding, vnode) {\n // State is initially collapsed until we receive a state event\n el[BV_TOGGLE_STATE] = false; // Assume no targets initially\n\n el[BV_TOGGLE_TARGETS] = []; // Add our root listeners\n\n addRootListeners(el, getInstanceFromDirective(vnode, binding)); // Initial update of trigger\n\n handleUpdate(el, binding, vnode);\n },\n componentUpdated: handleUpdate,\n updated: handleUpdate,\n unbind: function unbind(el, binding, vnode) {\n removeClickListener(el); // Remove our $root listener\n\n removeRootListeners(el, getInstanceFromDirective(vnode, binding)); // Reset custom props\n\n resetProp(el, BV_TOGGLE_ROOT_HANDLER);\n resetProp(el, BV_TOGGLE_CLICK_HANDLER);\n resetProp(el, BV_TOGGLE_STATE);\n resetProp(el, BV_TOGGLE_TARGETS); // Reset classes/attrs/styles\n\n removeClass(el, CLASS_BV_TOGGLE_COLLAPSED);\n removeClass(el, CLASS_BV_TOGGLE_NOT_COLLAPSED);\n removeAttr(el, ATTR_ARIA_EXPANDED);\n removeAttr(el, ATTR_ARIA_CONTROLS);\n removeAttr(el, ATTR_ROLE);\n removeStyle(el, STYLE_OVERFLOW_ANCHOR);\n }\n };\n\n var VBTogglePlugin = /*#__PURE__*/pluginFactory({\n directives: {\n VBToggle: VBToggle\n }\n });\n\n var CollapsePlugin = /*#__PURE__*/pluginFactory({\n components: {\n BCollapse: BCollapse\n },\n plugins: {\n VBTogglePlugin: VBTogglePlugin\n }\n });\n\n /**!\n * @fileOverview Kickass library to create and place poppers near their reference elements.\n * @version 1.16.1\n * @license\n * Copyright (c) 2016 Federico Zivolo and contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all\n * copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\n * SOFTWARE.\n */\n var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined' && typeof navigator !== 'undefined';\n\n var timeoutDuration = function () {\n var longerTimeoutBrowsers = ['Edge', 'Trident', 'Firefox'];\n for (var i = 0; i < longerTimeoutBrowsers.length; i += 1) {\n if (isBrowser && navigator.userAgent.indexOf(longerTimeoutBrowsers[i]) >= 0) {\n return 1;\n }\n }\n return 0;\n }();\n\n function microtaskDebounce(fn) {\n var called = false;\n return function () {\n if (called) {\n return;\n }\n called = true;\n window.Promise.resolve().then(function () {\n called = false;\n fn();\n });\n };\n }\n\n function taskDebounce(fn) {\n var scheduled = false;\n return function () {\n if (!scheduled) {\n scheduled = true;\n setTimeout(function () {\n scheduled = false;\n fn();\n }, timeoutDuration);\n }\n };\n }\n\n var supportsMicroTasks = isBrowser && window.Promise;\n\n /**\n * Create a debounced version of a method, that's asynchronously deferred\n * but called in the minimum time possible.\n *\n * @method\n * @memberof Popper.Utils\n * @argument {Function} fn\n * @returns {Function}\n */\n var debounce = supportsMicroTasks ? microtaskDebounce : taskDebounce;\n\n /**\n * Check if the given variable is a function\n * @method\n * @memberof Popper.Utils\n * @argument {Any} functionToCheck - variable to check\n * @returns {Boolean} answer to: is a function?\n */\n function isFunction(functionToCheck) {\n var getType = {};\n return functionToCheck && getType.toString.call(functionToCheck) === '[object Function]';\n }\n\n /**\n * Get CSS computed property of the given element\n * @method\n * @memberof Popper.Utils\n * @argument {Eement} element\n * @argument {String} property\n */\n function getStyleComputedProperty(element, property) {\n if (element.nodeType !== 1) {\n return [];\n }\n // NOTE: 1 DOM access here\n var window = element.ownerDocument.defaultView;\n var css = window.getComputedStyle(element, null);\n return property ? css[property] : css;\n }\n\n /**\n * Returns the parentNode or the host of the element\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @returns {Element} parent\n */\n function getParentNode(element) {\n if (element.nodeName === 'HTML') {\n return element;\n }\n return element.parentNode || element.host;\n }\n\n /**\n * Returns the scrolling parent of the given element\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @returns {Element} scroll parent\n */\n function getScrollParent(element) {\n // Return body, `getScroll` will take care to get the correct `scrollTop` from it\n if (!element) {\n return document.body;\n }\n\n switch (element.nodeName) {\n case 'HTML':\n case 'BODY':\n return element.ownerDocument.body;\n case '#document':\n return element.body;\n }\n\n // Firefox want us to check `-x` and `-y` variations as well\n\n var _getStyleComputedProp = getStyleComputedProperty(element),\n overflow = _getStyleComputedProp.overflow,\n overflowX = _getStyleComputedProp.overflowX,\n overflowY = _getStyleComputedProp.overflowY;\n\n if (/(auto|scroll|overlay)/.test(overflow + overflowY + overflowX)) {\n return element;\n }\n\n return getScrollParent(getParentNode(element));\n }\n\n /**\n * Returns the reference node of the reference object, or the reference object itself.\n * @method\n * @memberof Popper.Utils\n * @param {Element|Object} reference - the reference element (the popper will be relative to this)\n * @returns {Element} parent\n */\n function getReferenceNode(reference) {\n return reference && reference.referenceNode ? reference.referenceNode : reference;\n }\n\n var isIE11 = isBrowser && !!(window.MSInputMethodContext && document.documentMode);\n var isIE10 = isBrowser && /MSIE 10/.test(navigator.userAgent);\n\n /**\n * Determines if the browser is Internet Explorer\n * @method\n * @memberof Popper.Utils\n * @param {Number} version to check\n * @returns {Boolean} isIE\n */\n function isIE(version) {\n if (version === 11) {\n return isIE11;\n }\n if (version === 10) {\n return isIE10;\n }\n return isIE11 || isIE10;\n }\n\n /**\n * Returns the offset parent of the given element\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @returns {Element} offset parent\n */\n function getOffsetParent(element) {\n if (!element) {\n return document.documentElement;\n }\n\n var noOffsetParent = isIE(10) ? document.body : null;\n\n // NOTE: 1 DOM access here\n var offsetParent = element.offsetParent || null;\n // Skip hidden elements which don't have an offsetParent\n while (offsetParent === noOffsetParent && element.nextElementSibling) {\n offsetParent = (element = element.nextElementSibling).offsetParent;\n }\n\n var nodeName = offsetParent && offsetParent.nodeName;\n\n if (!nodeName || nodeName === 'BODY' || nodeName === 'HTML') {\n return element ? element.ownerDocument.documentElement : document.documentElement;\n }\n\n // .offsetParent will return the closest TH, TD or TABLE in case\n // no offsetParent is present, I hate this job...\n if (['TH', 'TD', 'TABLE'].indexOf(offsetParent.nodeName) !== -1 && getStyleComputedProperty(offsetParent, 'position') === 'static') {\n return getOffsetParent(offsetParent);\n }\n\n return offsetParent;\n }\n\n function isOffsetContainer(element) {\n var nodeName = element.nodeName;\n\n if (nodeName === 'BODY') {\n return false;\n }\n return nodeName === 'HTML' || getOffsetParent(element.firstElementChild) === element;\n }\n\n /**\n * Finds the root node (document, shadowDOM root) of the given element\n * @method\n * @memberof Popper.Utils\n * @argument {Element} node\n * @returns {Element} root node\n */\n function getRoot(node) {\n if (node.parentNode !== null) {\n return getRoot(node.parentNode);\n }\n\n return node;\n }\n\n /**\n * Finds the offset parent common to the two provided nodes\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element1\n * @argument {Element} element2\n * @returns {Element} common offset parent\n */\n function findCommonOffsetParent(element1, element2) {\n // This check is needed to avoid errors in case one of the elements isn't defined for any reason\n if (!element1 || !element1.nodeType || !element2 || !element2.nodeType) {\n return document.documentElement;\n }\n\n // Here we make sure to give as \"start\" the element that comes first in the DOM\n var order = element1.compareDocumentPosition(element2) & Node.DOCUMENT_POSITION_FOLLOWING;\n var start = order ? element1 : element2;\n var end = order ? element2 : element1;\n\n // Get common ancestor container\n var range = document.createRange();\n range.setStart(start, 0);\n range.setEnd(end, 0);\n var commonAncestorContainer = range.commonAncestorContainer;\n\n // Both nodes are inside #document\n\n if (element1 !== commonAncestorContainer && element2 !== commonAncestorContainer || start.contains(end)) {\n if (isOffsetContainer(commonAncestorContainer)) {\n return commonAncestorContainer;\n }\n\n return getOffsetParent(commonAncestorContainer);\n }\n\n // one of the nodes is inside shadowDOM, find which one\n var element1root = getRoot(element1);\n if (element1root.host) {\n return findCommonOffsetParent(element1root.host, element2);\n } else {\n return findCommonOffsetParent(element1, getRoot(element2).host);\n }\n }\n\n /**\n * Gets the scroll value of the given element in the given side (top and left)\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @argument {String} side `top` or `left`\n * @returns {number} amount of scrolled pixels\n */\n function getScroll(element) {\n var side = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'top';\n\n var upperSide = side === 'top' ? 'scrollTop' : 'scrollLeft';\n var nodeName = element.nodeName;\n\n if (nodeName === 'BODY' || nodeName === 'HTML') {\n var html = element.ownerDocument.documentElement;\n var scrollingElement = element.ownerDocument.scrollingElement || html;\n return scrollingElement[upperSide];\n }\n\n return element[upperSide];\n }\n\n /*\n * Sum or subtract the element scroll values (left and top) from a given rect object\n * @method\n * @memberof Popper.Utils\n * @param {Object} rect - Rect object you want to change\n * @param {HTMLElement} element - The element from the function reads the scroll values\n * @param {Boolean} subtract - set to true if you want to subtract the scroll values\n * @return {Object} rect - The modifier rect object\n */\n function includeScroll(rect, element) {\n var subtract = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n var scrollTop = getScroll(element, 'top');\n var scrollLeft = getScroll(element, 'left');\n var modifier = subtract ? -1 : 1;\n rect.top += scrollTop * modifier;\n rect.bottom += scrollTop * modifier;\n rect.left += scrollLeft * modifier;\n rect.right += scrollLeft * modifier;\n return rect;\n }\n\n /*\n * Helper to detect borders of a given element\n * @method\n * @memberof Popper.Utils\n * @param {CSSStyleDeclaration} styles\n * Result of `getStyleComputedProperty` on the given element\n * @param {String} axis - `x` or `y`\n * @return {number} borders - The borders size of the given axis\n */\n\n function getBordersSize(styles, axis) {\n var sideA = axis === 'x' ? 'Left' : 'Top';\n var sideB = sideA === 'Left' ? 'Right' : 'Bottom';\n\n return parseFloat(styles['border' + sideA + 'Width']) + parseFloat(styles['border' + sideB + 'Width']);\n }\n\n function getSize(axis, body, html, computedStyle) {\n return Math.max(body['offset' + axis], body['scroll' + axis], html['client' + axis], html['offset' + axis], html['scroll' + axis], isIE(10) ? parseInt(html['offset' + axis]) + parseInt(computedStyle['margin' + (axis === 'Height' ? 'Top' : 'Left')]) + parseInt(computedStyle['margin' + (axis === 'Height' ? 'Bottom' : 'Right')]) : 0);\n }\n\n function getWindowSizes(document) {\n var body = document.body;\n var html = document.documentElement;\n var computedStyle = isIE(10) && getComputedStyle(html);\n\n return {\n height: getSize('Height', body, html, computedStyle),\n width: getSize('Width', body, html, computedStyle)\n };\n }\n\n var classCallCheck = function (instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n };\n\n var createClass = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n }();\n\n\n\n\n\n var defineProperty = function (obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n };\n\n var _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n };\n\n /**\n * Given element offsets, generate an output similar to getBoundingClientRect\n * @method\n * @memberof Popper.Utils\n * @argument {Object} offsets\n * @returns {Object} ClientRect like output\n */\n function getClientRect(offsets) {\n return _extends({}, offsets, {\n right: offsets.left + offsets.width,\n bottom: offsets.top + offsets.height\n });\n }\n\n /**\n * Get bounding client rect of given element\n * @method\n * @memberof Popper.Utils\n * @param {HTMLElement} element\n * @return {Object} client rect\n */\n function getBoundingClientRect(element) {\n var rect = {};\n\n // IE10 10 FIX: Please, don't ask, the element isn't\n // considered in DOM in some circumstances...\n // This isn't reproducible in IE10 compatibility mode of IE11\n try {\n if (isIE(10)) {\n rect = element.getBoundingClientRect();\n var scrollTop = getScroll(element, 'top');\n var scrollLeft = getScroll(element, 'left');\n rect.top += scrollTop;\n rect.left += scrollLeft;\n rect.bottom += scrollTop;\n rect.right += scrollLeft;\n } else {\n rect = element.getBoundingClientRect();\n }\n } catch (e) {}\n\n var result = {\n left: rect.left,\n top: rect.top,\n width: rect.right - rect.left,\n height: rect.bottom - rect.top\n };\n\n // subtract scrollbar size from sizes\n var sizes = element.nodeName === 'HTML' ? getWindowSizes(element.ownerDocument) : {};\n var width = sizes.width || element.clientWidth || result.width;\n var height = sizes.height || element.clientHeight || result.height;\n\n var horizScrollbar = element.offsetWidth - width;\n var vertScrollbar = element.offsetHeight - height;\n\n // if an hypothetical scrollbar is detected, we must be sure it's not a `border`\n // we make this check conditional for performance reasons\n if (horizScrollbar || vertScrollbar) {\n var styles = getStyleComputedProperty(element);\n horizScrollbar -= getBordersSize(styles, 'x');\n vertScrollbar -= getBordersSize(styles, 'y');\n\n result.width -= horizScrollbar;\n result.height -= vertScrollbar;\n }\n\n return getClientRect(result);\n }\n\n function getOffsetRectRelativeToArbitraryNode(children, parent) {\n var fixedPosition = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n var isIE10 = isIE(10);\n var isHTML = parent.nodeName === 'HTML';\n var childrenRect = getBoundingClientRect(children);\n var parentRect = getBoundingClientRect(parent);\n var scrollParent = getScrollParent(children);\n\n var styles = getStyleComputedProperty(parent);\n var borderTopWidth = parseFloat(styles.borderTopWidth);\n var borderLeftWidth = parseFloat(styles.borderLeftWidth);\n\n // In cases where the parent is fixed, we must ignore negative scroll in offset calc\n if (fixedPosition && isHTML) {\n parentRect.top = Math.max(parentRect.top, 0);\n parentRect.left = Math.max(parentRect.left, 0);\n }\n var offsets = getClientRect({\n top: childrenRect.top - parentRect.top - borderTopWidth,\n left: childrenRect.left - parentRect.left - borderLeftWidth,\n width: childrenRect.width,\n height: childrenRect.height\n });\n offsets.marginTop = 0;\n offsets.marginLeft = 0;\n\n // Subtract margins of documentElement in case it's being used as parent\n // we do this only on HTML because it's the only element that behaves\n // differently when margins are applied to it. The margins are included in\n // the box of the documentElement, in the other cases not.\n if (!isIE10 && isHTML) {\n var marginTop = parseFloat(styles.marginTop);\n var marginLeft = parseFloat(styles.marginLeft);\n\n offsets.top -= borderTopWidth - marginTop;\n offsets.bottom -= borderTopWidth - marginTop;\n offsets.left -= borderLeftWidth - marginLeft;\n offsets.right -= borderLeftWidth - marginLeft;\n\n // Attach marginTop and marginLeft because in some circumstances we may need them\n offsets.marginTop = marginTop;\n offsets.marginLeft = marginLeft;\n }\n\n if (isIE10 && !fixedPosition ? parent.contains(scrollParent) : parent === scrollParent && scrollParent.nodeName !== 'BODY') {\n offsets = includeScroll(offsets, parent);\n }\n\n return offsets;\n }\n\n function getViewportOffsetRectRelativeToArtbitraryNode(element) {\n var excludeScroll = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n var html = element.ownerDocument.documentElement;\n var relativeOffset = getOffsetRectRelativeToArbitraryNode(element, html);\n var width = Math.max(html.clientWidth, window.innerWidth || 0);\n var height = Math.max(html.clientHeight, window.innerHeight || 0);\n\n var scrollTop = !excludeScroll ? getScroll(html) : 0;\n var scrollLeft = !excludeScroll ? getScroll(html, 'left') : 0;\n\n var offset = {\n top: scrollTop - relativeOffset.top + relativeOffset.marginTop,\n left: scrollLeft - relativeOffset.left + relativeOffset.marginLeft,\n width: width,\n height: height\n };\n\n return getClientRect(offset);\n }\n\n /**\n * Check if the given element is fixed or is inside a fixed parent\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @argument {Element} customContainer\n * @returns {Boolean} answer to \"isFixed?\"\n */\n function isFixed(element) {\n var nodeName = element.nodeName;\n if (nodeName === 'BODY' || nodeName === 'HTML') {\n return false;\n }\n if (getStyleComputedProperty(element, 'position') === 'fixed') {\n return true;\n }\n var parentNode = getParentNode(element);\n if (!parentNode) {\n return false;\n }\n return isFixed(parentNode);\n }\n\n /**\n * Finds the first parent of an element that has a transformed property defined\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @returns {Element} first transformed parent or documentElement\n */\n\n function getFixedPositionOffsetParent(element) {\n // This check is needed to avoid errors in case one of the elements isn't defined for any reason\n if (!element || !element.parentElement || isIE()) {\n return document.documentElement;\n }\n var el = element.parentElement;\n while (el && getStyleComputedProperty(el, 'transform') === 'none') {\n el = el.parentElement;\n }\n return el || document.documentElement;\n }\n\n /**\n * Computed the boundaries limits and return them\n * @method\n * @memberof Popper.Utils\n * @param {HTMLElement} popper\n * @param {HTMLElement} reference\n * @param {number} padding\n * @param {HTMLElement} boundariesElement - Element used to define the boundaries\n * @param {Boolean} fixedPosition - Is in fixed position mode\n * @returns {Object} Coordinates of the boundaries\n */\n function getBoundaries(popper, reference, padding, boundariesElement) {\n var fixedPosition = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;\n\n // NOTE: 1 DOM access here\n\n var boundaries = { top: 0, left: 0 };\n var offsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper, getReferenceNode(reference));\n\n // Handle viewport case\n if (boundariesElement === 'viewport') {\n boundaries = getViewportOffsetRectRelativeToArtbitraryNode(offsetParent, fixedPosition);\n } else {\n // Handle other cases based on DOM element used as boundaries\n var boundariesNode = void 0;\n if (boundariesElement === 'scrollParent') {\n boundariesNode = getScrollParent(getParentNode(reference));\n if (boundariesNode.nodeName === 'BODY') {\n boundariesNode = popper.ownerDocument.documentElement;\n }\n } else if (boundariesElement === 'window') {\n boundariesNode = popper.ownerDocument.documentElement;\n } else {\n boundariesNode = boundariesElement;\n }\n\n var offsets = getOffsetRectRelativeToArbitraryNode(boundariesNode, offsetParent, fixedPosition);\n\n // In case of HTML, we need a different computation\n if (boundariesNode.nodeName === 'HTML' && !isFixed(offsetParent)) {\n var _getWindowSizes = getWindowSizes(popper.ownerDocument),\n height = _getWindowSizes.height,\n width = _getWindowSizes.width;\n\n boundaries.top += offsets.top - offsets.marginTop;\n boundaries.bottom = height + offsets.top;\n boundaries.left += offsets.left - offsets.marginLeft;\n boundaries.right = width + offsets.left;\n } else {\n // for all the other DOM elements, this one is good\n boundaries = offsets;\n }\n }\n\n // Add paddings\n padding = padding || 0;\n var isPaddingNumber = typeof padding === 'number';\n boundaries.left += isPaddingNumber ? padding : padding.left || 0;\n boundaries.top += isPaddingNumber ? padding : padding.top || 0;\n boundaries.right -= isPaddingNumber ? padding : padding.right || 0;\n boundaries.bottom -= isPaddingNumber ? padding : padding.bottom || 0;\n\n return boundaries;\n }\n\n function getArea(_ref) {\n var width = _ref.width,\n height = _ref.height;\n\n return width * height;\n }\n\n /**\n * Utility used to transform the `auto` placement to the placement with more\n * available space.\n * @method\n * @memberof Popper.Utils\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function computeAutoPlacement(placement, refRect, popper, reference, boundariesElement) {\n var padding = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : 0;\n\n if (placement.indexOf('auto') === -1) {\n return placement;\n }\n\n var boundaries = getBoundaries(popper, reference, padding, boundariesElement);\n\n var rects = {\n top: {\n width: boundaries.width,\n height: refRect.top - boundaries.top\n },\n right: {\n width: boundaries.right - refRect.right,\n height: boundaries.height\n },\n bottom: {\n width: boundaries.width,\n height: boundaries.bottom - refRect.bottom\n },\n left: {\n width: refRect.left - boundaries.left,\n height: boundaries.height\n }\n };\n\n var sortedAreas = Object.keys(rects).map(function (key) {\n return _extends({\n key: key\n }, rects[key], {\n area: getArea(rects[key])\n });\n }).sort(function (a, b) {\n return b.area - a.area;\n });\n\n var filteredAreas = sortedAreas.filter(function (_ref2) {\n var width = _ref2.width,\n height = _ref2.height;\n return width >= popper.clientWidth && height >= popper.clientHeight;\n });\n\n var computedPlacement = filteredAreas.length > 0 ? filteredAreas[0].key : sortedAreas[0].key;\n\n var variation = placement.split('-')[1];\n\n return computedPlacement + (variation ? '-' + variation : '');\n }\n\n /**\n * Get offsets to the reference element\n * @method\n * @memberof Popper.Utils\n * @param {Object} state\n * @param {Element} popper - the popper element\n * @param {Element} reference - the reference element (the popper will be relative to this)\n * @param {Element} fixedPosition - is in fixed position mode\n * @returns {Object} An object containing the offsets which will be applied to the popper\n */\n function getReferenceOffsets(state, popper, reference) {\n var fixedPosition = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;\n\n var commonOffsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper, getReferenceNode(reference));\n return getOffsetRectRelativeToArbitraryNode(reference, commonOffsetParent, fixedPosition);\n }\n\n /**\n * Get the outer sizes of the given element (offset size + margins)\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element\n * @returns {Object} object containing width and height properties\n */\n function getOuterSizes(element) {\n var window = element.ownerDocument.defaultView;\n var styles = window.getComputedStyle(element);\n var x = parseFloat(styles.marginTop || 0) + parseFloat(styles.marginBottom || 0);\n var y = parseFloat(styles.marginLeft || 0) + parseFloat(styles.marginRight || 0);\n var result = {\n width: element.offsetWidth + y,\n height: element.offsetHeight + x\n };\n return result;\n }\n\n /**\n * Get the opposite placement of the given one\n * @method\n * @memberof Popper.Utils\n * @argument {String} placement\n * @returns {String} flipped placement\n */\n function getOppositePlacement(placement) {\n var hash = { left: 'right', right: 'left', bottom: 'top', top: 'bottom' };\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n }\n\n /**\n * Get offsets to the popper\n * @method\n * @memberof Popper.Utils\n * @param {Object} position - CSS position the Popper will get applied\n * @param {HTMLElement} popper - the popper element\n * @param {Object} referenceOffsets - the reference offsets (the popper will be relative to this)\n * @param {String} placement - one of the valid placement options\n * @returns {Object} popperOffsets - An object containing the offsets which will be applied to the popper\n */\n function getPopperOffsets(popper, referenceOffsets, placement) {\n placement = placement.split('-')[0];\n\n // Get popper node sizes\n var popperRect = getOuterSizes(popper);\n\n // Add position, width and height to our offsets object\n var popperOffsets = {\n width: popperRect.width,\n height: popperRect.height\n };\n\n // depending by the popper placement we have to compute its offsets slightly differently\n var isHoriz = ['right', 'left'].indexOf(placement) !== -1;\n var mainSide = isHoriz ? 'top' : 'left';\n var secondarySide = isHoriz ? 'left' : 'top';\n var measurement = isHoriz ? 'height' : 'width';\n var secondaryMeasurement = !isHoriz ? 'height' : 'width';\n\n popperOffsets[mainSide] = referenceOffsets[mainSide] + referenceOffsets[measurement] / 2 - popperRect[measurement] / 2;\n if (placement === secondarySide) {\n popperOffsets[secondarySide] = referenceOffsets[secondarySide] - popperRect[secondaryMeasurement];\n } else {\n popperOffsets[secondarySide] = referenceOffsets[getOppositePlacement(secondarySide)];\n }\n\n return popperOffsets;\n }\n\n /**\n * Mimics the `find` method of Array\n * @method\n * @memberof Popper.Utils\n * @argument {Array} arr\n * @argument prop\n * @argument value\n * @returns index or -1\n */\n function find(arr, check) {\n // use native find if supported\n if (Array.prototype.find) {\n return arr.find(check);\n }\n\n // use `filter` to obtain the same behavior of `find`\n return arr.filter(check)[0];\n }\n\n /**\n * Return the index of the matching object\n * @method\n * @memberof Popper.Utils\n * @argument {Array} arr\n * @argument prop\n * @argument value\n * @returns index or -1\n */\n function findIndex(arr, prop, value) {\n // use native findIndex if supported\n if (Array.prototype.findIndex) {\n return arr.findIndex(function (cur) {\n return cur[prop] === value;\n });\n }\n\n // use `find` + `indexOf` if `findIndex` isn't supported\n var match = find(arr, function (obj) {\n return obj[prop] === value;\n });\n return arr.indexOf(match);\n }\n\n /**\n * Loop trough the list of modifiers and run them in order,\n * each of them will then edit the data object.\n * @method\n * @memberof Popper.Utils\n * @param {dataObject} data\n * @param {Array} modifiers\n * @param {String} ends - Optional modifier name used as stopper\n * @returns {dataObject}\n */\n function runModifiers(modifiers, data, ends) {\n var modifiersToRun = ends === undefined ? modifiers : modifiers.slice(0, findIndex(modifiers, 'name', ends));\n\n modifiersToRun.forEach(function (modifier) {\n if (modifier['function']) {\n // eslint-disable-line dot-notation\n console.warn('`modifier.function` is deprecated, use `modifier.fn`!');\n }\n var fn = modifier['function'] || modifier.fn; // eslint-disable-line dot-notation\n if (modifier.enabled && isFunction(fn)) {\n // Add properties to offsets to make them a complete clientRect object\n // we do this before each modifier to make sure the previous one doesn't\n // mess with these values\n data.offsets.popper = getClientRect(data.offsets.popper);\n data.offsets.reference = getClientRect(data.offsets.reference);\n\n data = fn(data, modifier);\n }\n });\n\n return data;\n }\n\n /**\n * Updates the position of the popper, computing the new offsets and applying\n * the new style.
\n * Prefer `scheduleUpdate` over `update` because of performance reasons.\n * @method\n * @memberof Popper\n */\n function update() {\n // if popper is destroyed, don't perform any further update\n if (this.state.isDestroyed) {\n return;\n }\n\n var data = {\n instance: this,\n styles: {},\n arrowStyles: {},\n attributes: {},\n flipped: false,\n offsets: {}\n };\n\n // compute reference element offsets\n data.offsets.reference = getReferenceOffsets(this.state, this.popper, this.reference, this.options.positionFixed);\n\n // compute auto placement, store placement inside the data object,\n // modifiers will be able to edit `placement` if needed\n // and refer to originalPlacement to know the original value\n data.placement = computeAutoPlacement(this.options.placement, data.offsets.reference, this.popper, this.reference, this.options.modifiers.flip.boundariesElement, this.options.modifiers.flip.padding);\n\n // store the computed placement inside `originalPlacement`\n data.originalPlacement = data.placement;\n\n data.positionFixed = this.options.positionFixed;\n\n // compute the popper offsets\n data.offsets.popper = getPopperOffsets(this.popper, data.offsets.reference, data.placement);\n\n data.offsets.popper.position = this.options.positionFixed ? 'fixed' : 'absolute';\n\n // run the modifiers\n data = runModifiers(this.modifiers, data);\n\n // the first `update` will call `onCreate` callback\n // the other ones will call `onUpdate` callback\n if (!this.state.isCreated) {\n this.state.isCreated = true;\n this.options.onCreate(data);\n } else {\n this.options.onUpdate(data);\n }\n }\n\n /**\n * Helper used to know if the given modifier is enabled.\n * @method\n * @memberof Popper.Utils\n * @returns {Boolean}\n */\n function isModifierEnabled(modifiers, modifierName) {\n return modifiers.some(function (_ref) {\n var name = _ref.name,\n enabled = _ref.enabled;\n return enabled && name === modifierName;\n });\n }\n\n /**\n * Get the prefixed supported property name\n * @method\n * @memberof Popper.Utils\n * @argument {String} property (camelCase)\n * @returns {String} prefixed property (camelCase or PascalCase, depending on the vendor prefix)\n */\n function getSupportedPropertyName(property) {\n var prefixes = [false, 'ms', 'Webkit', 'Moz', 'O'];\n var upperProp = property.charAt(0).toUpperCase() + property.slice(1);\n\n for (var i = 0; i < prefixes.length; i++) {\n var prefix = prefixes[i];\n var toCheck = prefix ? '' + prefix + upperProp : property;\n if (typeof document.body.style[toCheck] !== 'undefined') {\n return toCheck;\n }\n }\n return null;\n }\n\n /**\n * Destroys the popper.\n * @method\n * @memberof Popper\n */\n function destroy() {\n this.state.isDestroyed = true;\n\n // touch DOM only if `applyStyle` modifier is enabled\n if (isModifierEnabled(this.modifiers, 'applyStyle')) {\n this.popper.removeAttribute('x-placement');\n this.popper.style.position = '';\n this.popper.style.top = '';\n this.popper.style.left = '';\n this.popper.style.right = '';\n this.popper.style.bottom = '';\n this.popper.style.willChange = '';\n this.popper.style[getSupportedPropertyName('transform')] = '';\n }\n\n this.disableEventListeners();\n\n // remove the popper if user explicitly asked for the deletion on destroy\n // do not use `remove` because IE11 doesn't support it\n if (this.options.removeOnDestroy) {\n this.popper.parentNode.removeChild(this.popper);\n }\n return this;\n }\n\n /**\n * Get the window associated with the element\n * @argument {Element} element\n * @returns {Window}\n */\n function getWindow(element) {\n var ownerDocument = element.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView : window;\n }\n\n function attachToScrollParents(scrollParent, event, callback, scrollParents) {\n var isBody = scrollParent.nodeName === 'BODY';\n var target = isBody ? scrollParent.ownerDocument.defaultView : scrollParent;\n target.addEventListener(event, callback, { passive: true });\n\n if (!isBody) {\n attachToScrollParents(getScrollParent(target.parentNode), event, callback, scrollParents);\n }\n scrollParents.push(target);\n }\n\n /**\n * Setup needed event listeners used to update the popper position\n * @method\n * @memberof Popper.Utils\n * @private\n */\n function setupEventListeners(reference, options, state, updateBound) {\n // Resize event listener on window\n state.updateBound = updateBound;\n getWindow(reference).addEventListener('resize', state.updateBound, { passive: true });\n\n // Scroll event listener on scroll parents\n var scrollElement = getScrollParent(reference);\n attachToScrollParents(scrollElement, 'scroll', state.updateBound, state.scrollParents);\n state.scrollElement = scrollElement;\n state.eventsEnabled = true;\n\n return state;\n }\n\n /**\n * It will add resize/scroll events and start recalculating\n * position of the popper element when they are triggered.\n * @method\n * @memberof Popper\n */\n function enableEventListeners() {\n if (!this.state.eventsEnabled) {\n this.state = setupEventListeners(this.reference, this.options, this.state, this.scheduleUpdate);\n }\n }\n\n /**\n * Remove event listeners used to update the popper position\n * @method\n * @memberof Popper.Utils\n * @private\n */\n function removeEventListeners(reference, state) {\n // Remove resize event listener on window\n getWindow(reference).removeEventListener('resize', state.updateBound);\n\n // Remove scroll event listener on scroll parents\n state.scrollParents.forEach(function (target) {\n target.removeEventListener('scroll', state.updateBound);\n });\n\n // Reset state\n state.updateBound = null;\n state.scrollParents = [];\n state.scrollElement = null;\n state.eventsEnabled = false;\n return state;\n }\n\n /**\n * It will remove resize/scroll events and won't recalculate popper position\n * when they are triggered. It also won't trigger `onUpdate` callback anymore,\n * unless you call `update` method manually.\n * @method\n * @memberof Popper\n */\n function disableEventListeners() {\n if (this.state.eventsEnabled) {\n cancelAnimationFrame(this.scheduleUpdate);\n this.state = removeEventListeners(this.reference, this.state);\n }\n }\n\n /**\n * Tells if a given input is a number\n * @method\n * @memberof Popper.Utils\n * @param {*} input to check\n * @return {Boolean}\n */\n function isNumeric(n) {\n return n !== '' && !isNaN(parseFloat(n)) && isFinite(n);\n }\n\n /**\n * Set the style to the given popper\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element - Element to apply the style to\n * @argument {Object} styles\n * Object with a list of properties and values which will be applied to the element\n */\n function setStyles(element, styles) {\n Object.keys(styles).forEach(function (prop) {\n var unit = '';\n // add unit if the value is numeric and is one of the following\n if (['width', 'height', 'top', 'right', 'bottom', 'left'].indexOf(prop) !== -1 && isNumeric(styles[prop])) {\n unit = 'px';\n }\n element.style[prop] = styles[prop] + unit;\n });\n }\n\n /**\n * Set the attributes to the given popper\n * @method\n * @memberof Popper.Utils\n * @argument {Element} element - Element to apply the attributes to\n * @argument {Object} styles\n * Object with a list of properties and values which will be applied to the element\n */\n function setAttributes(element, attributes) {\n Object.keys(attributes).forEach(function (prop) {\n var value = attributes[prop];\n if (value !== false) {\n element.setAttribute(prop, attributes[prop]);\n } else {\n element.removeAttribute(prop);\n }\n });\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Object} data.styles - List of style properties - values to apply to popper element\n * @argument {Object} data.attributes - List of attribute properties - values to apply to popper element\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The same data object\n */\n function applyStyle(data) {\n // any property present in `data.styles` will be applied to the popper,\n // in this way we can make the 3rd party modifiers add custom styles to it\n // Be aware, modifiers could override the properties defined in the previous\n // lines of this modifier!\n setStyles(data.instance.popper, data.styles);\n\n // any property present in `data.attributes` will be applied to the popper,\n // they will be set as HTML attributes of the element\n setAttributes(data.instance.popper, data.attributes);\n\n // if arrowElement is defined and arrowStyles has some properties\n if (data.arrowElement && Object.keys(data.arrowStyles).length) {\n setStyles(data.arrowElement, data.arrowStyles);\n }\n\n return data;\n }\n\n /**\n * Set the x-placement attribute before everything else because it could be used\n * to add margins to the popper margins needs to be calculated to get the\n * correct popper offsets.\n * @method\n * @memberof Popper.modifiers\n * @param {HTMLElement} reference - The reference element used to position the popper\n * @param {HTMLElement} popper - The HTML element used as popper\n * @param {Object} options - Popper.js options\n */\n function applyStyleOnLoad(reference, popper, options, modifierOptions, state) {\n // compute reference element offsets\n var referenceOffsets = getReferenceOffsets(state, popper, reference, options.positionFixed);\n\n // compute auto placement, store placement inside the data object,\n // modifiers will be able to edit `placement` if needed\n // and refer to originalPlacement to know the original value\n var placement = computeAutoPlacement(options.placement, referenceOffsets, popper, reference, options.modifiers.flip.boundariesElement, options.modifiers.flip.padding);\n\n popper.setAttribute('x-placement', placement);\n\n // Apply `position` to popper before anything else because\n // without the position applied we can't guarantee correct computations\n setStyles(popper, { position: options.positionFixed ? 'fixed' : 'absolute' });\n\n return options;\n }\n\n /**\n * @function\n * @memberof Popper.Utils\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Boolean} shouldRound - If the offsets should be rounded at all\n * @returns {Object} The popper's position offsets rounded\n *\n * The tale of pixel-perfect positioning. It's still not 100% perfect, but as\n * good as it can be within reason.\n * Discussion here: https://github.com/FezVrasta/popper.js/pull/715\n *\n * Low DPI screens cause a popper to be blurry if not using full pixels (Safari\n * as well on High DPI screens).\n *\n * Firefox prefers no rounding for positioning and does not have blurriness on\n * high DPI screens.\n *\n * Only horizontal placement and left/right values need to be considered.\n */\n function getRoundedOffsets(data, shouldRound) {\n var _data$offsets = data.offsets,\n popper = _data$offsets.popper,\n reference = _data$offsets.reference;\n var round = Math.round,\n floor = Math.floor;\n\n var noRound = function noRound(v) {\n return v;\n };\n\n var referenceWidth = round(reference.width);\n var popperWidth = round(popper.width);\n\n var isVertical = ['left', 'right'].indexOf(data.placement) !== -1;\n var isVariation = data.placement.indexOf('-') !== -1;\n var sameWidthParity = referenceWidth % 2 === popperWidth % 2;\n var bothOddWidth = referenceWidth % 2 === 1 && popperWidth % 2 === 1;\n\n var horizontalToInteger = !shouldRound ? noRound : isVertical || isVariation || sameWidthParity ? round : floor;\n var verticalToInteger = !shouldRound ? noRound : round;\n\n return {\n left: horizontalToInteger(bothOddWidth && !isVariation && shouldRound ? popper.left - 1 : popper.left),\n top: verticalToInteger(popper.top),\n bottom: verticalToInteger(popper.bottom),\n right: horizontalToInteger(popper.right)\n };\n }\n\n var isFirefox = isBrowser && /Firefox/i.test(navigator.userAgent);\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function computeStyle(data, options) {\n var x = options.x,\n y = options.y;\n var popper = data.offsets.popper;\n\n // Remove this legacy support in Popper.js v2\n\n var legacyGpuAccelerationOption = find(data.instance.modifiers, function (modifier) {\n return modifier.name === 'applyStyle';\n }).gpuAcceleration;\n if (legacyGpuAccelerationOption !== undefined) {\n console.warn('WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!');\n }\n var gpuAcceleration = legacyGpuAccelerationOption !== undefined ? legacyGpuAccelerationOption : options.gpuAcceleration;\n\n var offsetParent = getOffsetParent(data.instance.popper);\n var offsetParentRect = getBoundingClientRect(offsetParent);\n\n // Styles\n var styles = {\n position: popper.position\n };\n\n var offsets = getRoundedOffsets(data, window.devicePixelRatio < 2 || !isFirefox);\n\n var sideA = x === 'bottom' ? 'top' : 'bottom';\n var sideB = y === 'right' ? 'left' : 'right';\n\n // if gpuAcceleration is set to `true` and transform is supported,\n // we use `translate3d` to apply the position to the popper we\n // automatically use the supported prefixed version if needed\n var prefixedProperty = getSupportedPropertyName('transform');\n\n // now, let's make a step back and look at this code closely (wtf?)\n // If the content of the popper grows once it's been positioned, it\n // may happen that the popper gets misplaced because of the new content\n // overflowing its reference element\n // To avoid this problem, we provide two options (x and y), which allow\n // the consumer to define the offset origin.\n // If we position a popper on top of a reference element, we can set\n // `x` to `top` to make the popper grow towards its top instead of\n // its bottom.\n var left = void 0,\n top = void 0;\n if (sideA === 'bottom') {\n // when offsetParent is the positioning is relative to the bottom of the screen (excluding the scrollbar)\n // and not the bottom of the html element\n if (offsetParent.nodeName === 'HTML') {\n top = -offsetParent.clientHeight + offsets.bottom;\n } else {\n top = -offsetParentRect.height + offsets.bottom;\n }\n } else {\n top = offsets.top;\n }\n if (sideB === 'right') {\n if (offsetParent.nodeName === 'HTML') {\n left = -offsetParent.clientWidth + offsets.right;\n } else {\n left = -offsetParentRect.width + offsets.right;\n }\n } else {\n left = offsets.left;\n }\n if (gpuAcceleration && prefixedProperty) {\n styles[prefixedProperty] = 'translate3d(' + left + 'px, ' + top + 'px, 0)';\n styles[sideA] = 0;\n styles[sideB] = 0;\n styles.willChange = 'transform';\n } else {\n // othwerise, we use the standard `top`, `left`, `bottom` and `right` properties\n var invertTop = sideA === 'bottom' ? -1 : 1;\n var invertLeft = sideB === 'right' ? -1 : 1;\n styles[sideA] = top * invertTop;\n styles[sideB] = left * invertLeft;\n styles.willChange = sideA + ', ' + sideB;\n }\n\n // Attributes\n var attributes = {\n 'x-placement': data.placement\n };\n\n // Update `data` attributes, styles and arrowStyles\n data.attributes = _extends({}, attributes, data.attributes);\n data.styles = _extends({}, styles, data.styles);\n data.arrowStyles = _extends({}, data.offsets.arrow, data.arrowStyles);\n\n return data;\n }\n\n /**\n * Helper used to know if the given modifier depends from another one.
\n * It checks if the needed modifier is listed and enabled.\n * @method\n * @memberof Popper.Utils\n * @param {Array} modifiers - list of modifiers\n * @param {String} requestingName - name of requesting modifier\n * @param {String} requestedName - name of requested modifier\n * @returns {Boolean}\n */\n function isModifierRequired(modifiers, requestingName, requestedName) {\n var requesting = find(modifiers, function (_ref) {\n var name = _ref.name;\n return name === requestingName;\n });\n\n var isRequired = !!requesting && modifiers.some(function (modifier) {\n return modifier.name === requestedName && modifier.enabled && modifier.order < requesting.order;\n });\n\n if (!isRequired) {\n var _requesting = '`' + requestingName + '`';\n var requested = '`' + requestedName + '`';\n console.warn(requested + ' modifier is required by ' + _requesting + ' modifier in order to work, be sure to include it before ' + _requesting + '!');\n }\n return isRequired;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function arrow(data, options) {\n var _data$offsets$arrow;\n\n // arrow depends on keepTogether in order to work\n if (!isModifierRequired(data.instance.modifiers, 'arrow', 'keepTogether')) {\n return data;\n }\n\n var arrowElement = options.element;\n\n // if arrowElement is a string, suppose it's a CSS selector\n if (typeof arrowElement === 'string') {\n arrowElement = data.instance.popper.querySelector(arrowElement);\n\n // if arrowElement is not found, don't run the modifier\n if (!arrowElement) {\n return data;\n }\n } else {\n // if the arrowElement isn't a query selector we must check that the\n // provided DOM node is child of its popper node\n if (!data.instance.popper.contains(arrowElement)) {\n console.warn('WARNING: `arrow.element` must be child of its popper element!');\n return data;\n }\n }\n\n var placement = data.placement.split('-')[0];\n var _data$offsets = data.offsets,\n popper = _data$offsets.popper,\n reference = _data$offsets.reference;\n\n var isVertical = ['left', 'right'].indexOf(placement) !== -1;\n\n var len = isVertical ? 'height' : 'width';\n var sideCapitalized = isVertical ? 'Top' : 'Left';\n var side = sideCapitalized.toLowerCase();\n var altSide = isVertical ? 'left' : 'top';\n var opSide = isVertical ? 'bottom' : 'right';\n var arrowElementSize = getOuterSizes(arrowElement)[len];\n\n //\n // extends keepTogether behavior making sure the popper and its\n // reference have enough pixels in conjunction\n //\n\n // top/left side\n if (reference[opSide] - arrowElementSize < popper[side]) {\n data.offsets.popper[side] -= popper[side] - (reference[opSide] - arrowElementSize);\n }\n // bottom/right side\n if (reference[side] + arrowElementSize > popper[opSide]) {\n data.offsets.popper[side] += reference[side] + arrowElementSize - popper[opSide];\n }\n data.offsets.popper = getClientRect(data.offsets.popper);\n\n // compute center of the popper\n var center = reference[side] + reference[len] / 2 - arrowElementSize / 2;\n\n // Compute the sideValue using the updated popper offsets\n // take popper margin in account because we don't have this info available\n var css = getStyleComputedProperty(data.instance.popper);\n var popperMarginSide = parseFloat(css['margin' + sideCapitalized]);\n var popperBorderSide = parseFloat(css['border' + sideCapitalized + 'Width']);\n var sideValue = center - data.offsets.popper[side] - popperMarginSide - popperBorderSide;\n\n // prevent arrowElement from being placed not contiguously to its popper\n sideValue = Math.max(Math.min(popper[len] - arrowElementSize, sideValue), 0);\n\n data.arrowElement = arrowElement;\n data.offsets.arrow = (_data$offsets$arrow = {}, defineProperty(_data$offsets$arrow, side, Math.round(sideValue)), defineProperty(_data$offsets$arrow, altSide, ''), _data$offsets$arrow);\n\n return data;\n }\n\n /**\n * Get the opposite placement variation of the given one\n * @method\n * @memberof Popper.Utils\n * @argument {String} placement variation\n * @returns {String} flipped placement variation\n */\n function getOppositeVariation(variation) {\n if (variation === 'end') {\n return 'start';\n } else if (variation === 'start') {\n return 'end';\n }\n return variation;\n }\n\n /**\n * List of accepted placements to use as values of the `placement` option.
\n * Valid placements are:\n * - `auto`\n * - `top`\n * - `right`\n * - `bottom`\n * - `left`\n *\n * Each placement can have a variation from this list:\n * - `-start`\n * - `-end`\n *\n * Variations are interpreted easily if you think of them as the left to right\n * written languages. Horizontally (`top` and `bottom`), `start` is left and `end`\n * is right.
\n * Vertically (`left` and `right`), `start` is top and `end` is bottom.\n *\n * Some valid examples are:\n * - `top-end` (on top of reference, right aligned)\n * - `right-start` (on right of reference, top aligned)\n * - `bottom` (on bottom, centered)\n * - `auto-end` (on the side with more space available, alignment depends by placement)\n *\n * @static\n * @type {Array}\n * @enum {String}\n * @readonly\n * @method placements\n * @memberof Popper\n */\n var placements = ['auto-start', 'auto', 'auto-end', 'top-start', 'top', 'top-end', 'right-start', 'right', 'right-end', 'bottom-end', 'bottom', 'bottom-start', 'left-end', 'left', 'left-start'];\n\n // Get rid of `auto` `auto-start` and `auto-end`\n var validPlacements = placements.slice(3);\n\n /**\n * Given an initial placement, returns all the subsequent placements\n * clockwise (or counter-clockwise).\n *\n * @method\n * @memberof Popper.Utils\n * @argument {String} placement - A valid placement (it accepts variations)\n * @argument {Boolean} counter - Set to true to walk the placements counterclockwise\n * @returns {Array} placements including their variations\n */\n function clockwise(placement) {\n var counter = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n var index = validPlacements.indexOf(placement);\n var arr = validPlacements.slice(index + 1).concat(validPlacements.slice(0, index));\n return counter ? arr.reverse() : arr;\n }\n\n var BEHAVIORS = {\n FLIP: 'flip',\n CLOCKWISE: 'clockwise',\n COUNTERCLOCKWISE: 'counterclockwise'\n };\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function flip(data, options) {\n // if `inner` modifier is enabled, we can't use the `flip` modifier\n if (isModifierEnabled(data.instance.modifiers, 'inner')) {\n return data;\n }\n\n if (data.flipped && data.placement === data.originalPlacement) {\n // seems like flip is trying to loop, probably there's not enough space on any of the flippable sides\n return data;\n }\n\n var boundaries = getBoundaries(data.instance.popper, data.instance.reference, options.padding, options.boundariesElement, data.positionFixed);\n\n var placement = data.placement.split('-')[0];\n var placementOpposite = getOppositePlacement(placement);\n var variation = data.placement.split('-')[1] || '';\n\n var flipOrder = [];\n\n switch (options.behavior) {\n case BEHAVIORS.FLIP:\n flipOrder = [placement, placementOpposite];\n break;\n case BEHAVIORS.CLOCKWISE:\n flipOrder = clockwise(placement);\n break;\n case BEHAVIORS.COUNTERCLOCKWISE:\n flipOrder = clockwise(placement, true);\n break;\n default:\n flipOrder = options.behavior;\n }\n\n flipOrder.forEach(function (step, index) {\n if (placement !== step || flipOrder.length === index + 1) {\n return data;\n }\n\n placement = data.placement.split('-')[0];\n placementOpposite = getOppositePlacement(placement);\n\n var popperOffsets = data.offsets.popper;\n var refOffsets = data.offsets.reference;\n\n // using floor because the reference offsets may contain decimals we are not going to consider here\n var floor = Math.floor;\n var overlapsRef = placement === 'left' && floor(popperOffsets.right) > floor(refOffsets.left) || placement === 'right' && floor(popperOffsets.left) < floor(refOffsets.right) || placement === 'top' && floor(popperOffsets.bottom) > floor(refOffsets.top) || placement === 'bottom' && floor(popperOffsets.top) < floor(refOffsets.bottom);\n\n var overflowsLeft = floor(popperOffsets.left) < floor(boundaries.left);\n var overflowsRight = floor(popperOffsets.right) > floor(boundaries.right);\n var overflowsTop = floor(popperOffsets.top) < floor(boundaries.top);\n var overflowsBottom = floor(popperOffsets.bottom) > floor(boundaries.bottom);\n\n var overflowsBoundaries = placement === 'left' && overflowsLeft || placement === 'right' && overflowsRight || placement === 'top' && overflowsTop || placement === 'bottom' && overflowsBottom;\n\n // flip the variation if required\n var isVertical = ['top', 'bottom'].indexOf(placement) !== -1;\n\n // flips variation if reference element overflows boundaries\n var flippedVariationByRef = !!options.flipVariations && (isVertical && variation === 'start' && overflowsLeft || isVertical && variation === 'end' && overflowsRight || !isVertical && variation === 'start' && overflowsTop || !isVertical && variation === 'end' && overflowsBottom);\n\n // flips variation if popper content overflows boundaries\n var flippedVariationByContent = !!options.flipVariationsByContent && (isVertical && variation === 'start' && overflowsRight || isVertical && variation === 'end' && overflowsLeft || !isVertical && variation === 'start' && overflowsBottom || !isVertical && variation === 'end' && overflowsTop);\n\n var flippedVariation = flippedVariationByRef || flippedVariationByContent;\n\n if (overlapsRef || overflowsBoundaries || flippedVariation) {\n // this boolean to detect any flip loop\n data.flipped = true;\n\n if (overlapsRef || overflowsBoundaries) {\n placement = flipOrder[index + 1];\n }\n\n if (flippedVariation) {\n variation = getOppositeVariation(variation);\n }\n\n data.placement = placement + (variation ? '-' + variation : '');\n\n // this object contains `position`, we want to preserve it along with\n // any additional property we may add in the future\n data.offsets.popper = _extends({}, data.offsets.popper, getPopperOffsets(data.instance.popper, data.offsets.reference, data.placement));\n\n data = runModifiers(data.instance.modifiers, data, 'flip');\n }\n });\n return data;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function keepTogether(data) {\n var _data$offsets = data.offsets,\n popper = _data$offsets.popper,\n reference = _data$offsets.reference;\n\n var placement = data.placement.split('-')[0];\n var floor = Math.floor;\n var isVertical = ['top', 'bottom'].indexOf(placement) !== -1;\n var side = isVertical ? 'right' : 'bottom';\n var opSide = isVertical ? 'left' : 'top';\n var measurement = isVertical ? 'width' : 'height';\n\n if (popper[side] < floor(reference[opSide])) {\n data.offsets.popper[opSide] = floor(reference[opSide]) - popper[measurement];\n }\n if (popper[opSide] > floor(reference[side])) {\n data.offsets.popper[opSide] = floor(reference[side]);\n }\n\n return data;\n }\n\n /**\n * Converts a string containing value + unit into a px value number\n * @function\n * @memberof {modifiers~offset}\n * @private\n * @argument {String} str - Value + unit string\n * @argument {String} measurement - `height` or `width`\n * @argument {Object} popperOffsets\n * @argument {Object} referenceOffsets\n * @returns {Number|String}\n * Value in pixels, or original string if no values were extracted\n */\n function toValue(str, measurement, popperOffsets, referenceOffsets) {\n // separate value from unit\n var split = str.match(/((?:\\-|\\+)?\\d*\\.?\\d*)(.*)/);\n var value = +split[1];\n var unit = split[2];\n\n // If it's not a number it's an operator, I guess\n if (!value) {\n return str;\n }\n\n if (unit.indexOf('%') === 0) {\n var element = void 0;\n switch (unit) {\n case '%p':\n element = popperOffsets;\n break;\n case '%':\n case '%r':\n default:\n element = referenceOffsets;\n }\n\n var rect = getClientRect(element);\n return rect[measurement] / 100 * value;\n } else if (unit === 'vh' || unit === 'vw') {\n // if is a vh or vw, we calculate the size based on the viewport\n var size = void 0;\n if (unit === 'vh') {\n size = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);\n } else {\n size = Math.max(document.documentElement.clientWidth, window.innerWidth || 0);\n }\n return size / 100 * value;\n } else {\n // if is an explicit pixel unit, we get rid of the unit and keep the value\n // if is an implicit unit, it's px, and we return just the value\n return value;\n }\n }\n\n /**\n * Parse an `offset` string to extrapolate `x` and `y` numeric offsets.\n * @function\n * @memberof {modifiers~offset}\n * @private\n * @argument {String} offset\n * @argument {Object} popperOffsets\n * @argument {Object} referenceOffsets\n * @argument {String} basePlacement\n * @returns {Array} a two cells array with x and y offsets in numbers\n */\n function parseOffset(offset, popperOffsets, referenceOffsets, basePlacement) {\n var offsets = [0, 0];\n\n // Use height if placement is left or right and index is 0 otherwise use width\n // in this way the first offset will use an axis and the second one\n // will use the other one\n var useHeight = ['right', 'left'].indexOf(basePlacement) !== -1;\n\n // Split the offset string to obtain a list of values and operands\n // The regex addresses values with the plus or minus sign in front (+10, -20, etc)\n var fragments = offset.split(/(\\+|\\-)/).map(function (frag) {\n return frag.trim();\n });\n\n // Detect if the offset string contains a pair of values or a single one\n // they could be separated by comma or space\n var divider = fragments.indexOf(find(fragments, function (frag) {\n return frag.search(/,|\\s/) !== -1;\n }));\n\n if (fragments[divider] && fragments[divider].indexOf(',') === -1) {\n console.warn('Offsets separated by white space(s) are deprecated, use a comma (,) instead.');\n }\n\n // If divider is found, we divide the list of values and operands to divide\n // them by ofset X and Y.\n var splitRegex = /\\s*,\\s*|\\s+/;\n var ops = divider !== -1 ? [fragments.slice(0, divider).concat([fragments[divider].split(splitRegex)[0]]), [fragments[divider].split(splitRegex)[1]].concat(fragments.slice(divider + 1))] : [fragments];\n\n // Convert the values with units to absolute pixels to allow our computations\n ops = ops.map(function (op, index) {\n // Most of the units rely on the orientation of the popper\n var measurement = (index === 1 ? !useHeight : useHeight) ? 'height' : 'width';\n var mergeWithPrevious = false;\n return op\n // This aggregates any `+` or `-` sign that aren't considered operators\n // e.g.: 10 + +5 => [10, +, +5]\n .reduce(function (a, b) {\n if (a[a.length - 1] === '' && ['+', '-'].indexOf(b) !== -1) {\n a[a.length - 1] = b;\n mergeWithPrevious = true;\n return a;\n } else if (mergeWithPrevious) {\n a[a.length - 1] += b;\n mergeWithPrevious = false;\n return a;\n } else {\n return a.concat(b);\n }\n }, [])\n // Here we convert the string values into number values (in px)\n .map(function (str) {\n return toValue(str, measurement, popperOffsets, referenceOffsets);\n });\n });\n\n // Loop trough the offsets arrays and execute the operations\n ops.forEach(function (op, index) {\n op.forEach(function (frag, index2) {\n if (isNumeric(frag)) {\n offsets[index] += frag * (op[index2 - 1] === '-' ? -1 : 1);\n }\n });\n });\n return offsets;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @argument {Number|String} options.offset=0\n * The offset value as described in the modifier description\n * @returns {Object} The data object, properly modified\n */\n function offset(data, _ref) {\n var offset = _ref.offset;\n var placement = data.placement,\n _data$offsets = data.offsets,\n popper = _data$offsets.popper,\n reference = _data$offsets.reference;\n\n var basePlacement = placement.split('-')[0];\n\n var offsets = void 0;\n if (isNumeric(+offset)) {\n offsets = [+offset, 0];\n } else {\n offsets = parseOffset(offset, popper, reference, basePlacement);\n }\n\n if (basePlacement === 'left') {\n popper.top += offsets[0];\n popper.left -= offsets[1];\n } else if (basePlacement === 'right') {\n popper.top += offsets[0];\n popper.left += offsets[1];\n } else if (basePlacement === 'top') {\n popper.left += offsets[0];\n popper.top -= offsets[1];\n } else if (basePlacement === 'bottom') {\n popper.left += offsets[0];\n popper.top += offsets[1];\n }\n\n data.popper = popper;\n return data;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function preventOverflow(data, options) {\n var boundariesElement = options.boundariesElement || getOffsetParent(data.instance.popper);\n\n // If offsetParent is the reference element, we really want to\n // go one step up and use the next offsetParent as reference to\n // avoid to make this modifier completely useless and look like broken\n if (data.instance.reference === boundariesElement) {\n boundariesElement = getOffsetParent(boundariesElement);\n }\n\n // NOTE: DOM access here\n // resets the popper's position so that the document size can be calculated excluding\n // the size of the popper element itself\n var transformProp = getSupportedPropertyName('transform');\n var popperStyles = data.instance.popper.style; // assignment to help minification\n var top = popperStyles.top,\n left = popperStyles.left,\n transform = popperStyles[transformProp];\n\n popperStyles.top = '';\n popperStyles.left = '';\n popperStyles[transformProp] = '';\n\n var boundaries = getBoundaries(data.instance.popper, data.instance.reference, options.padding, boundariesElement, data.positionFixed);\n\n // NOTE: DOM access here\n // restores the original style properties after the offsets have been computed\n popperStyles.top = top;\n popperStyles.left = left;\n popperStyles[transformProp] = transform;\n\n options.boundaries = boundaries;\n\n var order = options.priority;\n var popper = data.offsets.popper;\n\n var check = {\n primary: function primary(placement) {\n var value = popper[placement];\n if (popper[placement] < boundaries[placement] && !options.escapeWithReference) {\n value = Math.max(popper[placement], boundaries[placement]);\n }\n return defineProperty({}, placement, value);\n },\n secondary: function secondary(placement) {\n var mainSide = placement === 'right' ? 'left' : 'top';\n var value = popper[mainSide];\n if (popper[placement] > boundaries[placement] && !options.escapeWithReference) {\n value = Math.min(popper[mainSide], boundaries[placement] - (placement === 'right' ? popper.width : popper.height));\n }\n return defineProperty({}, mainSide, value);\n }\n };\n\n order.forEach(function (placement) {\n var side = ['left', 'top'].indexOf(placement) !== -1 ? 'primary' : 'secondary';\n popper = _extends({}, popper, check[side](placement));\n });\n\n data.offsets.popper = popper;\n\n return data;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function shift(data) {\n var placement = data.placement;\n var basePlacement = placement.split('-')[0];\n var shiftvariation = placement.split('-')[1];\n\n // if shift shiftvariation is specified, run the modifier\n if (shiftvariation) {\n var _data$offsets = data.offsets,\n reference = _data$offsets.reference,\n popper = _data$offsets.popper;\n\n var isVertical = ['bottom', 'top'].indexOf(basePlacement) !== -1;\n var side = isVertical ? 'left' : 'top';\n var measurement = isVertical ? 'width' : 'height';\n\n var shiftOffsets = {\n start: defineProperty({}, side, reference[side]),\n end: defineProperty({}, side, reference[side] + reference[measurement] - popper[measurement])\n };\n\n data.offsets.popper = _extends({}, popper, shiftOffsets[shiftvariation]);\n }\n\n return data;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by update method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function hide(data) {\n if (!isModifierRequired(data.instance.modifiers, 'hide', 'preventOverflow')) {\n return data;\n }\n\n var refRect = data.offsets.reference;\n var bound = find(data.instance.modifiers, function (modifier) {\n return modifier.name === 'preventOverflow';\n }).boundaries;\n\n if (refRect.bottom < bound.top || refRect.left > bound.right || refRect.top > bound.bottom || refRect.right < bound.left) {\n // Avoid unnecessary DOM access if visibility hasn't changed\n if (data.hide === true) {\n return data;\n }\n\n data.hide = true;\n data.attributes['x-out-of-boundaries'] = '';\n } else {\n // Avoid unnecessary DOM access if visibility hasn't changed\n if (data.hide === false) {\n return data;\n }\n\n data.hide = false;\n data.attributes['x-out-of-boundaries'] = false;\n }\n\n return data;\n }\n\n /**\n * @function\n * @memberof Modifiers\n * @argument {Object} data - The data object generated by `update` method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {Object} The data object, properly modified\n */\n function inner(data) {\n var placement = data.placement;\n var basePlacement = placement.split('-')[0];\n var _data$offsets = data.offsets,\n popper = _data$offsets.popper,\n reference = _data$offsets.reference;\n\n var isHoriz = ['left', 'right'].indexOf(basePlacement) !== -1;\n\n var subtractLength = ['top', 'left'].indexOf(basePlacement) === -1;\n\n popper[isHoriz ? 'left' : 'top'] = reference[basePlacement] - (subtractLength ? popper[isHoriz ? 'width' : 'height'] : 0);\n\n data.placement = getOppositePlacement(placement);\n data.offsets.popper = getClientRect(popper);\n\n return data;\n }\n\n /**\n * Modifier function, each modifier can have a function of this type assigned\n * to its `fn` property.
\n * These functions will be called on each update, this means that you must\n * make sure they are performant enough to avoid performance bottlenecks.\n *\n * @function ModifierFn\n * @argument {dataObject} data - The data object generated by `update` method\n * @argument {Object} options - Modifiers configuration and options\n * @returns {dataObject} The data object, properly modified\n */\n\n /**\n * Modifiers are plugins used to alter the behavior of your poppers.
\n * Popper.js uses a set of 9 modifiers to provide all the basic functionalities\n * needed by the library.\n *\n * Usually you don't want to override the `order`, `fn` and `onLoad` props.\n * All the other properties are configurations that could be tweaked.\n * @namespace modifiers\n */\n var modifiers = {\n /**\n * Modifier used to shift the popper on the start or end of its reference\n * element.
\n * It will read the variation of the `placement` property.
\n * It can be one either `-end` or `-start`.\n * @memberof modifiers\n * @inner\n */\n shift: {\n /** @prop {number} order=100 - Index used to define the order of execution */\n order: 100,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: shift\n },\n\n /**\n * The `offset` modifier can shift your popper on both its axis.\n *\n * It accepts the following units:\n * - `px` or unit-less, interpreted as pixels\n * - `%` or `%r`, percentage relative to the length of the reference element\n * - `%p`, percentage relative to the length of the popper element\n * - `vw`, CSS viewport width unit\n * - `vh`, CSS viewport height unit\n *\n * For length is intended the main axis relative to the placement of the popper.
\n * This means that if the placement is `top` or `bottom`, the length will be the\n * `width`. In case of `left` or `right`, it will be the `height`.\n *\n * You can provide a single value (as `Number` or `String`), or a pair of values\n * as `String` divided by a comma or one (or more) white spaces.
\n * The latter is a deprecated method because it leads to confusion and will be\n * removed in v2.
\n * Additionally, it accepts additions and subtractions between different units.\n * Note that multiplications and divisions aren't supported.\n *\n * Valid examples are:\n * ```\n * 10\n * '10%'\n * '10, 10'\n * '10%, 10'\n * '10 + 10%'\n * '10 - 5vh + 3%'\n * '-10px + 5vh, 5px - 6%'\n * ```\n * > **NB**: If you desire to apply offsets to your poppers in a way that may make them overlap\n * > with their reference element, unfortunately, you will have to disable the `flip` modifier.\n * > You can read more on this at this [issue](https://github.com/FezVrasta/popper.js/issues/373).\n *\n * @memberof modifiers\n * @inner\n */\n offset: {\n /** @prop {number} order=200 - Index used to define the order of execution */\n order: 200,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: offset,\n /** @prop {Number|String} offset=0\n * The offset value as described in the modifier description\n */\n offset: 0\n },\n\n /**\n * Modifier used to prevent the popper from being positioned outside the boundary.\n *\n * A scenario exists where the reference itself is not within the boundaries.
\n * We can say it has \"escaped the boundaries\" — or just \"escaped\".
\n * In this case we need to decide whether the popper should either:\n *\n * - detach from the reference and remain \"trapped\" in the boundaries, or\n * - if it should ignore the boundary and \"escape with its reference\"\n *\n * When `escapeWithReference` is set to`true` and reference is completely\n * outside its boundaries, the popper will overflow (or completely leave)\n * the boundaries in order to remain attached to the edge of the reference.\n *\n * @memberof modifiers\n * @inner\n */\n preventOverflow: {\n /** @prop {number} order=300 - Index used to define the order of execution */\n order: 300,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: preventOverflow,\n /**\n * @prop {Array} [priority=['left','right','top','bottom']]\n * Popper will try to prevent overflow following these priorities by default,\n * then, it could overflow on the left and on top of the `boundariesElement`\n */\n priority: ['left', 'right', 'top', 'bottom'],\n /**\n * @prop {number} padding=5\n * Amount of pixel used to define a minimum distance between the boundaries\n * and the popper. This makes sure the popper always has a little padding\n * between the edges of its container\n */\n padding: 5,\n /**\n * @prop {String|HTMLElement} boundariesElement='scrollParent'\n * Boundaries used by the modifier. Can be `scrollParent`, `window`,\n * `viewport` or any DOM element.\n */\n boundariesElement: 'scrollParent'\n },\n\n /**\n * Modifier used to make sure the reference and its popper stay near each other\n * without leaving any gap between the two. Especially useful when the arrow is\n * enabled and you want to ensure that it points to its reference element.\n * It cares only about the first axis. You can still have poppers with margin\n * between the popper and its reference element.\n * @memberof modifiers\n * @inner\n */\n keepTogether: {\n /** @prop {number} order=400 - Index used to define the order of execution */\n order: 400,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: keepTogether\n },\n\n /**\n * This modifier is used to move the `arrowElement` of the popper to make\n * sure it is positioned between the reference element and its popper element.\n * It will read the outer size of the `arrowElement` node to detect how many\n * pixels of conjunction are needed.\n *\n * It has no effect if no `arrowElement` is provided.\n * @memberof modifiers\n * @inner\n */\n arrow: {\n /** @prop {number} order=500 - Index used to define the order of execution */\n order: 500,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: arrow,\n /** @prop {String|HTMLElement} element='[x-arrow]' - Selector or node used as arrow */\n element: '[x-arrow]'\n },\n\n /**\n * Modifier used to flip the popper's placement when it starts to overlap its\n * reference element.\n *\n * Requires the `preventOverflow` modifier before it in order to work.\n *\n * **NOTE:** this modifier will interrupt the current update cycle and will\n * restart it if it detects the need to flip the placement.\n * @memberof modifiers\n * @inner\n */\n flip: {\n /** @prop {number} order=600 - Index used to define the order of execution */\n order: 600,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: flip,\n /**\n * @prop {String|Array} behavior='flip'\n * The behavior used to change the popper's placement. It can be one of\n * `flip`, `clockwise`, `counterclockwise` or an array with a list of valid\n * placements (with optional variations)\n */\n behavior: 'flip',\n /**\n * @prop {number} padding=5\n * The popper will flip if it hits the edges of the `boundariesElement`\n */\n padding: 5,\n /**\n * @prop {String|HTMLElement} boundariesElement='viewport'\n * The element which will define the boundaries of the popper position.\n * The popper will never be placed outside of the defined boundaries\n * (except if `keepTogether` is enabled)\n */\n boundariesElement: 'viewport',\n /**\n * @prop {Boolean} flipVariations=false\n * The popper will switch placement variation between `-start` and `-end` when\n * the reference element overlaps its boundaries.\n *\n * The original placement should have a set variation.\n */\n flipVariations: false,\n /**\n * @prop {Boolean} flipVariationsByContent=false\n * The popper will switch placement variation between `-start` and `-end` when\n * the popper element overlaps its reference boundaries.\n *\n * The original placement should have a set variation.\n */\n flipVariationsByContent: false\n },\n\n /**\n * Modifier used to make the popper flow toward the inner of the reference element.\n * By default, when this modifier is disabled, the popper will be placed outside\n * the reference element.\n * @memberof modifiers\n * @inner\n */\n inner: {\n /** @prop {number} order=700 - Index used to define the order of execution */\n order: 700,\n /** @prop {Boolean} enabled=false - Whether the modifier is enabled or not */\n enabled: false,\n /** @prop {ModifierFn} */\n fn: inner\n },\n\n /**\n * Modifier used to hide the popper when its reference element is outside of the\n * popper boundaries. It will set a `x-out-of-boundaries` attribute which can\n * be used to hide with a CSS selector the popper when its reference is\n * out of boundaries.\n *\n * Requires the `preventOverflow` modifier before it in order to work.\n * @memberof modifiers\n * @inner\n */\n hide: {\n /** @prop {number} order=800 - Index used to define the order of execution */\n order: 800,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: hide\n },\n\n /**\n * Computes the style that will be applied to the popper element to gets\n * properly positioned.\n *\n * Note that this modifier will not touch the DOM, it just prepares the styles\n * so that `applyStyle` modifier can apply it. This separation is useful\n * in case you need to replace `applyStyle` with a custom implementation.\n *\n * This modifier has `850` as `order` value to maintain backward compatibility\n * with previous versions of Popper.js. Expect the modifiers ordering method\n * to change in future major versions of the library.\n *\n * @memberof modifiers\n * @inner\n */\n computeStyle: {\n /** @prop {number} order=850 - Index used to define the order of execution */\n order: 850,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: computeStyle,\n /**\n * @prop {Boolean} gpuAcceleration=true\n * If true, it uses the CSS 3D transformation to position the popper.\n * Otherwise, it will use the `top` and `left` properties\n */\n gpuAcceleration: true,\n /**\n * @prop {string} [x='bottom']\n * Where to anchor the X axis (`bottom` or `top`). AKA X offset origin.\n * Change this if your popper should grow in a direction different from `bottom`\n */\n x: 'bottom',\n /**\n * @prop {string} [x='left']\n * Where to anchor the Y axis (`left` or `right`). AKA Y offset origin.\n * Change this if your popper should grow in a direction different from `right`\n */\n y: 'right'\n },\n\n /**\n * Applies the computed styles to the popper element.\n *\n * All the DOM manipulations are limited to this modifier. This is useful in case\n * you want to integrate Popper.js inside a framework or view library and you\n * want to delegate all the DOM manipulations to it.\n *\n * Note that if you disable this modifier, you must make sure the popper element\n * has its position set to `absolute` before Popper.js can do its work!\n *\n * Just disable this modifier and define your own to achieve the desired effect.\n *\n * @memberof modifiers\n * @inner\n */\n applyStyle: {\n /** @prop {number} order=900 - Index used to define the order of execution */\n order: 900,\n /** @prop {Boolean} enabled=true - Whether the modifier is enabled or not */\n enabled: true,\n /** @prop {ModifierFn} */\n fn: applyStyle,\n /** @prop {Function} */\n onLoad: applyStyleOnLoad,\n /**\n * @deprecated since version 1.10.0, the property moved to `computeStyle` modifier\n * @prop {Boolean} gpuAcceleration=true\n * If true, it uses the CSS 3D transformation to position the popper.\n * Otherwise, it will use the `top` and `left` properties\n */\n gpuAcceleration: undefined\n }\n };\n\n /**\n * The `dataObject` is an object containing all the information used by Popper.js.\n * This object is passed to modifiers and to the `onCreate` and `onUpdate` callbacks.\n * @name dataObject\n * @property {Object} data.instance The Popper.js instance\n * @property {String} data.placement Placement applied to popper\n * @property {String} data.originalPlacement Placement originally defined on init\n * @property {Boolean} data.flipped True if popper has been flipped by flip modifier\n * @property {Boolean} data.hide True if the reference element is out of boundaries, useful to know when to hide the popper\n * @property {HTMLElement} data.arrowElement Node used as arrow by arrow modifier\n * @property {Object} data.styles Any CSS property defined here will be applied to the popper. It expects the JavaScript nomenclature (eg. `marginBottom`)\n * @property {Object} data.arrowStyles Any CSS property defined here will be applied to the popper arrow. It expects the JavaScript nomenclature (eg. `marginBottom`)\n * @property {Object} data.boundaries Offsets of the popper boundaries\n * @property {Object} data.offsets The measurements of popper, reference and arrow elements\n * @property {Object} data.offsets.popper `top`, `left`, `width`, `height` values\n * @property {Object} data.offsets.reference `top`, `left`, `width`, `height` values\n * @property {Object} data.offsets.arrow] `top` and `left` offsets, only one of them will be different from 0\n */\n\n /**\n * Default options provided to Popper.js constructor.
\n * These can be overridden using the `options` argument of Popper.js.
\n * To override an option, simply pass an object with the same\n * structure of the `options` object, as the 3rd argument. For example:\n * ```\n * new Popper(ref, pop, {\n * modifiers: {\n * preventOverflow: { enabled: false }\n * }\n * })\n * ```\n * @type {Object}\n * @static\n * @memberof Popper\n */\n var Defaults = {\n /**\n * Popper's placement.\n * @prop {Popper.placements} placement='bottom'\n */\n placement: 'bottom',\n\n /**\n * Set this to true if you want popper to position it self in 'fixed' mode\n * @prop {Boolean} positionFixed=false\n */\n positionFixed: false,\n\n /**\n * Whether events (resize, scroll) are initially enabled.\n * @prop {Boolean} eventsEnabled=true\n */\n eventsEnabled: true,\n\n /**\n * Set to true if you want to automatically remove the popper when\n * you call the `destroy` method.\n * @prop {Boolean} removeOnDestroy=false\n */\n removeOnDestroy: false,\n\n /**\n * Callback called when the popper is created.
\n * By default, it is set to no-op.
\n * Access Popper.js instance with `data.instance`.\n * @prop {onCreate}\n */\n onCreate: function onCreate() {},\n\n /**\n * Callback called when the popper is updated. This callback is not called\n * on the initialization/creation of the popper, but only on subsequent\n * updates.
\n * By default, it is set to no-op.
\n * Access Popper.js instance with `data.instance`.\n * @prop {onUpdate}\n */\n onUpdate: function onUpdate() {},\n\n /**\n * List of modifiers used to modify the offsets before they are applied to the popper.\n * They provide most of the functionalities of Popper.js.\n * @prop {modifiers}\n */\n modifiers: modifiers\n };\n\n /**\n * @callback onCreate\n * @param {dataObject} data\n */\n\n /**\n * @callback onUpdate\n * @param {dataObject} data\n */\n\n // Utils\n // Methods\n var Popper = function () {\n /**\n * Creates a new Popper.js instance.\n * @class Popper\n * @param {Element|referenceObject} reference - The reference element used to position the popper\n * @param {Element} popper - The HTML / XML element used as the popper\n * @param {Object} options - Your custom options to override the ones defined in [Defaults](#defaults)\n * @return {Object} instance - The generated Popper.js instance\n */\n function Popper(reference, popper) {\n var _this = this;\n\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n classCallCheck(this, Popper);\n\n this.scheduleUpdate = function () {\n return requestAnimationFrame(_this.update);\n };\n\n // make update() debounced, so that it only runs at most once-per-tick\n this.update = debounce(this.update.bind(this));\n\n // with {} we create a new object with the options inside it\n this.options = _extends({}, Popper.Defaults, options);\n\n // init state\n this.state = {\n isDestroyed: false,\n isCreated: false,\n scrollParents: []\n };\n\n // get reference and popper elements (allow jQuery wrappers)\n this.reference = reference && reference.jquery ? reference[0] : reference;\n this.popper = popper && popper.jquery ? popper[0] : popper;\n\n // Deep merge modifiers options\n this.options.modifiers = {};\n Object.keys(_extends({}, Popper.Defaults.modifiers, options.modifiers)).forEach(function (name) {\n _this.options.modifiers[name] = _extends({}, Popper.Defaults.modifiers[name] || {}, options.modifiers ? options.modifiers[name] : {});\n });\n\n // Refactoring modifiers' list (Object => Array)\n this.modifiers = Object.keys(this.options.modifiers).map(function (name) {\n return _extends({\n name: name\n }, _this.options.modifiers[name]);\n })\n // sort the modifiers by order\n .sort(function (a, b) {\n return a.order - b.order;\n });\n\n // modifiers have the ability to execute arbitrary code when Popper.js get inited\n // such code is executed in the same order of its modifier\n // they could add new properties to their options configuration\n // BE AWARE: don't add options to `options.modifiers.name` but to `modifierOptions`!\n this.modifiers.forEach(function (modifierOptions) {\n if (modifierOptions.enabled && isFunction(modifierOptions.onLoad)) {\n modifierOptions.onLoad(_this.reference, _this.popper, _this.options, modifierOptions, _this.state);\n }\n });\n\n // fire the first update to position the popper in the right place\n this.update();\n\n var eventsEnabled = this.options.eventsEnabled;\n if (eventsEnabled) {\n // setup event listeners, they will take care of update the position in specific situations\n this.enableEventListeners();\n }\n\n this.state.eventsEnabled = eventsEnabled;\n }\n\n // We can't use class properties because they don't get listed in the\n // class prototype and break stuff like Sinon stubs\n\n\n createClass(Popper, [{\n key: 'update',\n value: function update$$1() {\n return update.call(this);\n }\n }, {\n key: 'destroy',\n value: function destroy$$1() {\n return destroy.call(this);\n }\n }, {\n key: 'enableEventListeners',\n value: function enableEventListeners$$1() {\n return enableEventListeners.call(this);\n }\n }, {\n key: 'disableEventListeners',\n value: function disableEventListeners$$1() {\n return disableEventListeners.call(this);\n }\n\n /**\n * Schedules an update. It will run on the next UI update available.\n * @method scheduleUpdate\n * @memberof Popper\n */\n\n\n /**\n * Collection of utilities useful when writing custom modifiers.\n * Starting from version 1.7, this method is available only if you\n * include `popper-utils.js` before `popper.js`.\n *\n * **DEPRECATION**: This way to access PopperUtils is deprecated\n * and will be removed in v2! Use the PopperUtils module directly instead.\n * Due to the high instability of the methods contained in Utils, we can't\n * guarantee them to follow semver. Use them at your own risk!\n * @static\n * @private\n * @type {Object}\n * @deprecated since version 1.8\n * @member Utils\n * @memberof Popper\n */\n\n }]);\n return Popper;\n }();\n\n /**\n * The `referenceObject` is an object that provides an interface compatible with Popper.js\n * and lets you use it as replacement of a real DOM node.
\n * You can use this method to position a popper relatively to a set of coordinates\n * in case you don't have a DOM node to use as reference.\n *\n * ```\n * new Popper(referenceObject, popperNode);\n * ```\n *\n * NB: This feature isn't supported in Internet Explorer 10.\n * @name referenceObject\n * @property {Function} data.getBoundingClientRect\n * A function that returns a set of coordinates compatible with the native `getBoundingClientRect` method.\n * @property {number} data.clientWidth\n * An ES6 getter that will return the width of the virtual reference element.\n * @property {number} data.clientHeight\n * An ES6 getter that will return the height of the virtual reference element.\n */\n\n\n Popper.Utils = (typeof window !== 'undefined' ? window : global).PopperUtils;\n Popper.placements = placements;\n Popper.Defaults = Defaults;\n\n var PLACEMENT_TOP_START = 'top-start';\n var PLACEMENT_TOP_END = 'top-end';\n var PLACEMENT_BOTTOM_START = 'bottom-start';\n var PLACEMENT_BOTTOM_END = 'bottom-end';\n var PLACEMENT_RIGHT_START = 'right-start';\n var PLACEMENT_LEFT_START = 'left-start';\n\n var BvEvent = /*#__PURE__*/function () {\n function BvEvent(type) {\n var eventInit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n _classCallCheck(this, BvEvent);\n\n // Start by emulating native Event constructor\n if (!type) {\n /* istanbul ignore next */\n throw new TypeError(\"Failed to construct '\".concat(this.constructor.name, \"'. 1 argument required, \").concat(arguments.length, \" given.\"));\n } // Merge defaults first, the eventInit, and the type last\n // so it can't be overwritten\n\n\n assign(this, BvEvent.Defaults, this.constructor.Defaults, eventInit, {\n type: type\n }); // Freeze some props as readonly, but leave them enumerable\n\n defineProperties(this, {\n type: readonlyDescriptor(),\n cancelable: readonlyDescriptor(),\n nativeEvent: readonlyDescriptor(),\n target: readonlyDescriptor(),\n relatedTarget: readonlyDescriptor(),\n vueTarget: readonlyDescriptor(),\n componentId: readonlyDescriptor()\n }); // Create a private variable using closure scoping\n\n var defaultPrevented = false; // Recreate preventDefault method. One way setter\n\n this.preventDefault = function preventDefault() {\n if (this.cancelable) {\n defaultPrevented = true;\n }\n }; // Create `defaultPrevented` publicly accessible prop that\n // can only be altered by the preventDefault method\n\n\n defineProperty$1(this, 'defaultPrevented', {\n enumerable: true,\n get: function get() {\n return defaultPrevented;\n }\n });\n }\n\n _createClass(BvEvent, null, [{\n key: \"Defaults\",\n get: function get() {\n return {\n type: '',\n cancelable: true,\n nativeEvent: null,\n target: null,\n relatedTarget: null,\n vueTarget: null,\n componentId: null\n };\n }\n }]);\n\n return BvEvent;\n }();\n\n var clickOutMixin = extend({\n data: function data() {\n return {\n listenForClickOut: false\n };\n },\n watch: {\n listenForClickOut: function listenForClickOut(newValue, oldValue) {\n if (newValue !== oldValue) {\n eventOff(this.clickOutElement, this.clickOutEventName, this._clickOutHandler, EVENT_OPTIONS_NO_CAPTURE);\n\n if (newValue) {\n eventOn(this.clickOutElement, this.clickOutEventName, this._clickOutHandler, EVENT_OPTIONS_NO_CAPTURE);\n }\n }\n }\n },\n beforeCreate: function beforeCreate() {\n // Declare non-reactive properties\n this.clickOutElement = null;\n this.clickOutEventName = null;\n },\n mounted: function mounted() {\n if (!this.clickOutElement) {\n this.clickOutElement = document;\n }\n\n if (!this.clickOutEventName) {\n this.clickOutEventName = 'click';\n }\n\n if (this.listenForClickOut) {\n eventOn(this.clickOutElement, this.clickOutEventName, this._clickOutHandler, EVENT_OPTIONS_NO_CAPTURE);\n }\n },\n beforeDestroy: function beforeDestroy() {\n eventOff(this.clickOutElement, this.clickOutEventName, this._clickOutHandler, EVENT_OPTIONS_NO_CAPTURE);\n },\n methods: {\n isClickOut: function isClickOut(event) {\n return !contains(this.$el, event.target);\n },\n _clickOutHandler: function _clickOutHandler(event) {\n if (this.clickOutHandler && this.isClickOut(event)) {\n this.clickOutHandler(event);\n }\n }\n }\n });\n\n var focusInMixin = extend({\n data: function data() {\n return {\n listenForFocusIn: false\n };\n },\n watch: {\n listenForFocusIn: function listenForFocusIn(newValue, oldValue) {\n if (newValue !== oldValue) {\n eventOff(this.focusInElement, 'focusin', this._focusInHandler, EVENT_OPTIONS_NO_CAPTURE);\n\n if (newValue) {\n eventOn(this.focusInElement, 'focusin', this._focusInHandler, EVENT_OPTIONS_NO_CAPTURE);\n }\n }\n }\n },\n beforeCreate: function beforeCreate() {\n // Declare non-reactive properties\n this.focusInElement = null;\n },\n mounted: function mounted() {\n if (!this.focusInElement) {\n this.focusInElement = document;\n }\n\n if (this.listenForFocusIn) {\n eventOn(this.focusInElement, 'focusin', this._focusInHandler, EVENT_OPTIONS_NO_CAPTURE);\n }\n },\n beforeDestroy: function beforeDestroy() {\n eventOff(this.focusInElement, 'focusin', this._focusInHandler, EVENT_OPTIONS_NO_CAPTURE);\n },\n methods: {\n _focusInHandler: function _focusInHandler(event) {\n if (this.focusInHandler) {\n this.focusInHandler(event);\n }\n }\n }\n });\n\n var registry = null;\n\n if (isVue3) {\n registry = new WeakMap();\n }\n\n var registerElementToInstance = function registerElementToInstance(element, instance) {\n if (!isVue3) {\n return;\n }\n\n registry.set(element, instance);\n };\n var removeElementToInstance = function removeElementToInstance(element) {\n if (!isVue3) {\n return;\n }\n\n registry.delete(element);\n };\n var getInstanceFromElement = function getInstanceFromElement(element) {\n if (!isVue3) {\n return element.__vue__;\n }\n\n var currentElement = element;\n\n while (currentElement) {\n if (registry.has(currentElement)) {\n /* istanbul ignore next */\n return registry.get(currentElement);\n }\n\n currentElement = currentElement.parentNode;\n }\n\n return null;\n };\n\n var ROOT_EVENT_NAME_SHOWN = getRootEventName(NAME_DROPDOWN, EVENT_NAME_SHOWN);\n var ROOT_EVENT_NAME_HIDDEN = getRootEventName(NAME_DROPDOWN, EVENT_NAME_HIDDEN); // CSS selectors\n\n var SELECTOR_FORM_CHILD = '.dropdown form';\n var SELECTOR_ITEM = ['.dropdown-item', '.b-dropdown-form'].map(function (selector) {\n return \"\".concat(selector, \":not(.disabled):not([disabled])\");\n }).join(', '); // --- Helper methods ---\n // Return an array of visible items\n\n var filterVisibles = function filterVisibles(els) {\n return (els || []).filter(isVisible);\n }; // --- Props ---\n\n\n var props$1O = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, props$25), {}, {\n // String: `scrollParent`, `window` or `viewport`\n // HTMLElement: HTML Element reference\n boundary: makeProp([HTMLElement, PROP_TYPE_STRING], 'scrollParent'),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n // Place left if possible\n dropleft: makeProp(PROP_TYPE_BOOLEAN, false),\n // Place right if possible\n dropright: makeProp(PROP_TYPE_BOOLEAN, false),\n // Place on top if possible\n dropup: makeProp(PROP_TYPE_BOOLEAN, false),\n // Disable auto-flipping of menu from bottom <=> top\n noFlip: makeProp(PROP_TYPE_BOOLEAN, false),\n // Number of pixels or a CSS unit value to offset menu\n // (i.e. `1px`, `1rem`, etc.)\n offset: makeProp(PROP_TYPE_NUMBER_STRING, 0),\n popperOpts: makeProp(PROP_TYPE_OBJECT, {}),\n // Right align menu (default is left align)\n right: makeProp(PROP_TYPE_BOOLEAN, false)\n })), NAME_DROPDOWN); // --- Mixin ---\n // @vue/component\n\n var dropdownMixin = extend({\n mixins: [idMixin, listenOnRootMixin, clickOutMixin, focusInMixin],\n provide: function provide() {\n var _this = this;\n\n return {\n getBvDropdown: function getBvDropdown() {\n return _this;\n }\n };\n },\n inject: {\n getBvNavbar: {\n default: function _default() {\n return function () {\n return null;\n };\n }\n }\n },\n props: props$1O,\n data: function data() {\n return {\n visible: false,\n visibleChangePrevented: false\n };\n },\n computed: {\n bvNavbar: function bvNavbar() {\n return this.getBvNavbar();\n },\n inNavbar: function inNavbar() {\n return !isNull(this.bvNavbar);\n },\n toggler: function toggler() {\n var toggle = this.$refs.toggle;\n return toggle ? toggle.$el || toggle : null;\n },\n directionClass: function directionClass() {\n if (this.dropup) {\n return 'dropup';\n } else if (this.dropright) {\n return 'dropright';\n } else if (this.dropleft) {\n return 'dropleft';\n }\n\n return '';\n },\n boundaryClass: function boundaryClass() {\n // Position `static` is needed to allow menu to \"breakout\" of the `scrollParent`\n // boundaries when boundary is anything other than `scrollParent`\n // See: https://github.com/twbs/bootstrap/issues/24251#issuecomment-341413786\n return this.boundary !== 'scrollParent' && !this.inNavbar ? 'position-static' : '';\n },\n hideDelay: function hideDelay() {\n return this.inNavbar ? HAS_TOUCH_SUPPORT ? 300 : 50 : 0;\n }\n },\n watch: {\n visible: function visible(newValue, oldValue) {\n if (this.visibleChangePrevented) {\n this.visibleChangePrevented = false;\n return;\n }\n\n if (newValue !== oldValue) {\n var eventName = newValue ? EVENT_NAME_SHOW : EVENT_NAME_HIDE;\n var bvEvent = new BvEvent(eventName, {\n cancelable: true,\n vueTarget: this,\n target: this.$refs.menu,\n relatedTarget: null,\n componentId: this.safeId ? this.safeId() : this.id || null\n });\n this.emitEvent(bvEvent);\n\n if (bvEvent.defaultPrevented) {\n // Reset value and exit if canceled\n this.visibleChangePrevented = true;\n this.visible = oldValue; // Just in case a child element triggered `this.hide(true)`\n\n this.$off(EVENT_NAME_HIDDEN, this.focusToggler);\n return;\n }\n\n if (newValue) {\n this.showMenu();\n } else {\n this.hideMenu();\n }\n }\n },\n disabled: function disabled(newValue, oldValue) {\n if (newValue !== oldValue && newValue && this.visible) {\n // Hide dropdown if disabled changes to true\n this.visible = false;\n }\n }\n },\n created: function created() {\n // Create private non-reactive props\n this.$_popper = null;\n this.$_hideTimeout = null;\n },\n\n /* istanbul ignore next */\n deactivated: function deactivated() {\n // In case we are inside a ``\n this.visible = false;\n this.whileOpenListen(false);\n this.destroyPopper();\n },\n mounted: function mounted() {\n registerElementToInstance(this.$el, this);\n },\n beforeDestroy: function beforeDestroy() {\n this.visible = false;\n this.whileOpenListen(false);\n this.destroyPopper();\n this.clearHideTimeout();\n removeElementToInstance(this.$el);\n },\n methods: {\n // Event emitter\n emitEvent: function emitEvent(bvEvent) {\n var type = bvEvent.type;\n this.emitOnRoot(getRootEventName(NAME_DROPDOWN, type), bvEvent);\n this.$emit(type, bvEvent);\n },\n showMenu: function showMenu() {\n var _this2 = this;\n\n if (this.disabled) {\n /* istanbul ignore next */\n return;\n } // Only instantiate Popper.js when dropdown is not in ``\n\n\n if (!this.inNavbar) {\n if (typeof Popper === 'undefined') {\n /* istanbul ignore next */\n warn('Popper.js not found. Falling back to CSS positioning', NAME_DROPDOWN);\n } else {\n // For dropup with alignment we use the parent element as popper container\n var el = this.dropup && this.right || this.split ? this.$el : this.$refs.toggle; // Make sure we have a reference to an element, not a component!\n\n el = el.$el || el; // Instantiate Popper.js\n\n this.createPopper(el);\n }\n } // Ensure other menus are closed\n\n\n this.emitOnRoot(ROOT_EVENT_NAME_SHOWN, this); // Enable listeners\n\n this.whileOpenListen(true); // Wrap in `$nextTick()` to ensure menu is fully rendered/shown\n\n this.$nextTick(function () {\n // Focus on the menu container on show\n _this2.focusMenu(); // Emit the shown event\n\n\n _this2.$emit(EVENT_NAME_SHOWN);\n });\n },\n hideMenu: function hideMenu() {\n this.whileOpenListen(false);\n this.emitOnRoot(ROOT_EVENT_NAME_HIDDEN, this);\n this.$emit(EVENT_NAME_HIDDEN);\n this.destroyPopper();\n },\n createPopper: function createPopper(element) {\n this.destroyPopper();\n this.$_popper = new Popper(element, this.$refs.menu, this.getPopperConfig());\n },\n // Ensure popper event listeners are removed cleanly\n destroyPopper: function destroyPopper() {\n this.$_popper && this.$_popper.destroy();\n this.$_popper = null;\n },\n // Instructs popper to re-computes the dropdown position\n // useful if the content changes size\n updatePopper: function updatePopper() {\n try {\n this.$_popper.scheduleUpdate();\n } catch (_unused) {}\n },\n clearHideTimeout: function clearHideTimeout() {\n clearTimeout(this.$_hideTimeout);\n this.$_hideTimeout = null;\n },\n getPopperConfig: function getPopperConfig() {\n var placement = PLACEMENT_BOTTOM_START;\n\n if (this.dropup) {\n placement = this.right ? PLACEMENT_TOP_END : PLACEMENT_TOP_START;\n } else if (this.dropright) {\n placement = PLACEMENT_RIGHT_START;\n } else if (this.dropleft) {\n placement = PLACEMENT_LEFT_START;\n } else if (this.right) {\n placement = PLACEMENT_BOTTOM_END;\n }\n\n var popperConfig = {\n placement: placement,\n modifiers: {\n offset: {\n offset: this.offset || 0\n },\n flip: {\n enabled: !this.noFlip\n }\n }\n };\n var boundariesElement = this.boundary;\n\n if (boundariesElement) {\n popperConfig.modifiers.preventOverflow = {\n boundariesElement: boundariesElement\n };\n }\n\n return mergeDeep(popperConfig, this.popperOpts || {});\n },\n // Turn listeners on/off while open\n whileOpenListen: function whileOpenListen(isOpen) {\n // Hide the dropdown when clicked outside\n this.listenForClickOut = isOpen; // Hide the dropdown when it loses focus\n\n this.listenForFocusIn = isOpen; // Hide the dropdown when another dropdown is opened\n\n var method = isOpen ? 'listenOnRoot' : 'listenOffRoot';\n this[method](ROOT_EVENT_NAME_SHOWN, this.rootCloseListener);\n },\n rootCloseListener: function rootCloseListener(vm) {\n if (vm !== this) {\n this.visible = false;\n }\n },\n // Public method to show dropdown\n show: function show() {\n var _this3 = this;\n\n if (this.disabled) {\n return;\n } // Wrap in a `requestAF()` to allow any previous\n // click handling to occur first\n\n\n requestAF(function () {\n _this3.visible = true;\n });\n },\n // Public method to hide dropdown\n hide: function hide() {\n var refocus = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n\n /* istanbul ignore next */\n if (this.disabled) {\n return;\n }\n\n this.visible = false;\n\n if (refocus) {\n // Child element is closing the dropdown on click\n this.$once(EVENT_NAME_HIDDEN, this.focusToggler);\n }\n },\n // Called only by a button that toggles the menu\n toggle: function toggle(event) {\n event = event || {}; // Early exit when not a click event or ENTER, SPACE or DOWN were pressed\n\n var _event = event,\n type = _event.type,\n keyCode = _event.keyCode;\n\n if (type !== 'click' && !(type === 'keydown' && [CODE_ENTER, CODE_SPACE, CODE_DOWN].indexOf(keyCode) !== -1)) {\n /* istanbul ignore next */\n return;\n }\n /* istanbul ignore next */\n\n\n if (this.disabled) {\n this.visible = false;\n return;\n }\n\n this.$emit(EVENT_NAME_TOGGLE, event);\n stopEvent(event); // Toggle visibility\n\n if (this.visible) {\n this.hide(true);\n } else {\n this.show();\n }\n },\n // Mousedown handler for the toggle\n\n /* istanbul ignore next */\n onMousedown: function onMousedown(event) {\n // We prevent the 'mousedown' event for the toggle to stop the\n // 'focusin' event from being fired\n // The event would otherwise be picked up by the global 'focusin'\n // listener and there is no cross-browser solution to detect it\n // relates to the toggle click\n // The 'click' event will still be fired and we handle closing\n // other dropdowns there too\n // See https://github.com/bootstrap-vue/bootstrap-vue/issues/4328\n stopEvent(event, {\n propagation: false\n });\n },\n // Called from dropdown menu context\n onKeydown: function onKeydown(event) {\n var keyCode = event.keyCode;\n\n if (keyCode === CODE_ESC) {\n // Close on ESC\n this.onEsc(event);\n } else if (keyCode === CODE_DOWN) {\n // Down Arrow\n this.focusNext(event, false);\n } else if (keyCode === CODE_UP) {\n // Up Arrow\n this.focusNext(event, true);\n }\n },\n // If user presses ESC, close the menu\n onEsc: function onEsc(event) {\n if (this.visible) {\n this.visible = false;\n stopEvent(event); // Return focus to original trigger button\n\n this.$once(EVENT_NAME_HIDDEN, this.focusToggler);\n }\n },\n // Called only in split button mode, for the split button\n onSplitClick: function onSplitClick(event) {\n /* istanbul ignore next */\n if (this.disabled) {\n this.visible = false;\n return;\n }\n\n this.$emit(EVENT_NAME_CLICK, event);\n },\n // Shared hide handler between click-out and focus-in events\n hideHandler: function hideHandler(event) {\n var _this4 = this;\n\n var target = event.target;\n\n if (this.visible && !contains(this.$refs.menu, target) && !contains(this.toggler, target)) {\n this.clearHideTimeout();\n this.$_hideTimeout = setTimeout(function () {\n return _this4.hide();\n }, this.hideDelay);\n }\n },\n // Document click-out listener\n clickOutHandler: function clickOutHandler(event) {\n this.hideHandler(event);\n },\n // Document focus-in listener\n focusInHandler: function focusInHandler(event) {\n this.hideHandler(event);\n },\n // Keyboard nav\n focusNext: function focusNext(event, up) {\n var _this5 = this;\n\n // Ignore key up/down on form elements\n var target = event.target;\n\n if (!this.visible || event && closest(SELECTOR_FORM_CHILD, target)) {\n /* istanbul ignore next: should never happen */\n return;\n }\n\n stopEvent(event);\n this.$nextTick(function () {\n var items = _this5.getItems();\n\n if (items.length < 1) {\n /* istanbul ignore next: should never happen */\n return;\n }\n\n var index = items.indexOf(target);\n\n if (up && index > 0) {\n index--;\n } else if (!up && index < items.length - 1) {\n index++;\n }\n\n if (index < 0) {\n /* istanbul ignore next: should never happen */\n index = 0;\n }\n\n _this5.focusItem(index, items);\n });\n },\n focusItem: function focusItem(index, items) {\n var el = items.find(function (el, i) {\n return i === index;\n });\n attemptFocus(el);\n },\n getItems: function getItems() {\n // Get all items\n return filterVisibles(selectAll(SELECTOR_ITEM, this.$refs.menu));\n },\n focusMenu: function focusMenu() {\n attemptFocus(this.$refs.menu);\n },\n focusToggler: function focusToggler() {\n var _this6 = this;\n\n this.$nextTick(function () {\n attemptFocus(_this6.toggler);\n });\n }\n }\n });\n\n var props$1N = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3(_objectSpread2$3({}, props$25), props$1O), {}, {\n block: makeProp(PROP_TYPE_BOOLEAN, false),\n html: makeProp(PROP_TYPE_STRING),\n // If `true`, only render menu contents when open\n lazy: makeProp(PROP_TYPE_BOOLEAN, false),\n menuClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n noCaret: makeProp(PROP_TYPE_BOOLEAN, false),\n role: makeProp(PROP_TYPE_STRING, 'menu'),\n size: makeProp(PROP_TYPE_STRING),\n split: makeProp(PROP_TYPE_BOOLEAN, false),\n splitButtonType: makeProp(PROP_TYPE_STRING, 'button', function (value) {\n return arrayIncludes(['button', 'submit', 'reset'], value);\n }),\n splitClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n splitHref: makeProp(PROP_TYPE_STRING),\n splitTo: makeProp(PROP_TYPE_OBJECT_STRING),\n splitVariant: makeProp(PROP_TYPE_STRING),\n text: makeProp(PROP_TYPE_STRING),\n toggleAttrs: makeProp(PROP_TYPE_OBJECT, {}),\n toggleClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n toggleTag: makeProp(PROP_TYPE_STRING, 'button'),\n // TODO: This really should be `toggleLabel`\n toggleText: makeProp(PROP_TYPE_STRING, 'Toggle dropdown'),\n variant: makeProp(PROP_TYPE_STRING, 'secondary')\n })), NAME_DROPDOWN); // --- Main component ---\n // @vue/component\n\n var BDropdown = /*#__PURE__*/extend({\n name: NAME_DROPDOWN,\n mixins: [idMixin, dropdownMixin, normalizeSlotMixin],\n props: props$1N,\n computed: {\n dropdownClasses: function dropdownClasses() {\n var block = this.block,\n split = this.split;\n return [this.directionClass, this.boundaryClass, {\n show: this.visible,\n // The 'btn-group' class is required in `split` mode for button alignment\n // It needs also to be applied when `block` is disabled to allow multiple\n // dropdowns to be aligned one line\n 'btn-group': split || !block,\n // When `block` is enabled and we are in `split` mode the 'd-flex' class\n // needs to be applied to allow the buttons to stretch to full width\n 'd-flex': block && split\n }];\n },\n menuClasses: function menuClasses() {\n return [this.menuClass, {\n 'dropdown-menu-right': this.right,\n show: this.visible\n }];\n },\n toggleClasses: function toggleClasses() {\n var split = this.split;\n return [this.toggleClass, {\n 'dropdown-toggle-split': split,\n 'dropdown-toggle-no-caret': this.noCaret && !split\n }];\n }\n },\n render: function render(h) {\n var visible = this.visible,\n variant = this.variant,\n size = this.size,\n block = this.block,\n disabled = this.disabled,\n split = this.split,\n role = this.role,\n hide = this.hide,\n toggle = this.toggle;\n var commonProps = {\n variant: variant,\n size: size,\n block: block,\n disabled: disabled\n };\n var $buttonChildren = this.normalizeSlot(SLOT_NAME_BUTTON_CONTENT);\n var buttonContentDomProps = this.hasNormalizedSlot(SLOT_NAME_BUTTON_CONTENT) ? {} : htmlOrText(this.html, this.text);\n var $split = h();\n\n if (split) {\n var splitTo = this.splitTo,\n splitHref = this.splitHref,\n splitButtonType = this.splitButtonType;\n\n var btnProps = _objectSpread2$3(_objectSpread2$3({}, commonProps), {}, {\n variant: this.splitVariant || variant\n }); // We add these as needed due to issues with\n // defined property with `undefined`/`null` values\n\n\n if (splitTo) {\n btnProps.to = splitTo;\n } else if (splitHref) {\n btnProps.href = splitHref;\n } else if (splitButtonType) {\n btnProps.type = splitButtonType;\n }\n\n $split = h(BButton, {\n class: this.splitClass,\n attrs: {\n id: this.safeId('_BV_button_')\n },\n props: btnProps,\n domProps: buttonContentDomProps,\n on: {\n click: this.onSplitClick\n },\n ref: 'button'\n }, $buttonChildren); // Overwrite button content for the toggle when in `split` mode\n\n $buttonChildren = [h('span', {\n class: ['sr-only']\n }, [this.toggleText])];\n buttonContentDomProps = {};\n }\n\n var ariaHasPopupRoles = ['menu', 'listbox', 'tree', 'grid', 'dialog'];\n var $toggle = h(BButton, {\n staticClass: 'dropdown-toggle',\n class: this.toggleClasses,\n attrs: _objectSpread2$3(_objectSpread2$3({}, this.toggleAttrs), {}, {\n // Must have attributes\n id: this.safeId('_BV_toggle_'),\n 'aria-haspopup': ariaHasPopupRoles.includes(role) ? role : 'false',\n 'aria-expanded': toString(visible)\n }),\n props: _objectSpread2$3(_objectSpread2$3({}, commonProps), {}, {\n tag: this.toggleTag,\n block: block && !split\n }),\n domProps: buttonContentDomProps,\n on: {\n mousedown: this.onMousedown,\n click: toggle,\n keydown: toggle // Handle ENTER, SPACE and DOWN\n\n },\n ref: 'toggle'\n }, $buttonChildren);\n var $menu = h('ul', {\n staticClass: 'dropdown-menu',\n class: this.menuClasses,\n attrs: {\n role: role,\n tabindex: '-1',\n 'aria-labelledby': this.safeId(split ? '_BV_button_' : '_BV_toggle_')\n },\n on: {\n keydown: this.onKeydown // Handle UP, DOWN and ESC\n\n },\n ref: 'menu'\n }, [!this.lazy || visible ? this.normalizeSlot(SLOT_NAME_DEFAULT, {\n hide: hide\n }) : h()]);\n return h('div', {\n staticClass: 'dropdown b-dropdown',\n class: this.dropdownClasses,\n attrs: {\n id: this.safeId()\n }\n }, [$split, $toggle, $menu]);\n }\n });\n\n var linkProps$4 = omit(props$2f, ['event', 'routerTag']);\n var props$1M = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, linkProps$4), {}, {\n linkClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n variant: makeProp(PROP_TYPE_STRING)\n })), NAME_DROPDOWN_ITEM); // --- Main component ---\n // @vue/component\n\n var BDropdownItem = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_ITEM,\n mixins: [attrsMixin, normalizeSlotMixin],\n inject: {\n getBvDropdown: {\n default: function _default() {\n return function () {\n return null;\n };\n }\n }\n },\n inheritAttrs: false,\n props: props$1M,\n computed: {\n bvDropdown: function bvDropdown() {\n return this.getBvDropdown();\n },\n computedAttrs: function computedAttrs() {\n return _objectSpread2$3(_objectSpread2$3({}, this.bvAttrs), {}, {\n role: 'menuitem'\n });\n }\n },\n methods: {\n closeDropdown: function closeDropdown() {\n var _this = this;\n\n // Close on next animation frame to allow time to process\n requestAF(function () {\n if (_this.bvDropdown) {\n _this.bvDropdown.hide(true);\n }\n });\n },\n onClick: function onClick(event) {\n this.$emit(EVENT_NAME_CLICK, event);\n this.closeDropdown();\n }\n },\n render: function render(h) {\n var linkClass = this.linkClass,\n variant = this.variant,\n active = this.active,\n disabled = this.disabled,\n onClick = this.onClick,\n bvAttrs = this.bvAttrs;\n return h('li', {\n class: bvAttrs.class,\n style: bvAttrs.style,\n attrs: {\n role: 'presentation'\n }\n }, [h(BLink, {\n staticClass: 'dropdown-item',\n class: [linkClass, _defineProperty({}, \"text-\".concat(variant), variant && !(active || disabled))],\n props: pluckProps(linkProps$4, this.$props),\n attrs: this.computedAttrs,\n on: {\n click: onClick\n },\n ref: 'item'\n }, this.normalizeSlot())]);\n }\n });\n\n var props$1L = makePropsConfigurable({\n active: makeProp(PROP_TYPE_BOOLEAN, false),\n activeClass: makeProp(PROP_TYPE_STRING, 'active'),\n buttonClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n variant: makeProp(PROP_TYPE_STRING)\n }, NAME_DROPDOWN_ITEM_BUTTON); // --- Main component ---\n // @vue/component\n\n var BDropdownItemButton = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_ITEM_BUTTON,\n mixins: [attrsMixin, normalizeSlotMixin],\n inject: {\n getBvDropdown: {\n default: function _default() {\n return function () {\n return null;\n };\n }\n }\n },\n inheritAttrs: false,\n props: props$1L,\n computed: {\n bvDropdown: function bvDropdown() {\n return this.getBvDropdown();\n },\n computedAttrs: function computedAttrs() {\n return _objectSpread2$3(_objectSpread2$3({}, this.bvAttrs), {}, {\n role: 'menuitem',\n type: 'button',\n disabled: this.disabled\n });\n }\n },\n methods: {\n closeDropdown: function closeDropdown() {\n if (this.bvDropdown) {\n this.bvDropdown.hide(true);\n }\n },\n onClick: function onClick(event) {\n this.$emit(EVENT_NAME_CLICK, event);\n this.closeDropdown();\n }\n },\n render: function render(h) {\n var _ref;\n\n var active = this.active,\n variant = this.variant,\n bvAttrs = this.bvAttrs;\n return h('li', {\n class: bvAttrs.class,\n style: bvAttrs.style,\n attrs: {\n role: 'presentation'\n }\n }, [h('button', {\n staticClass: 'dropdown-item',\n class: [this.buttonClass, (_ref = {}, _defineProperty(_ref, this.activeClass, active), _defineProperty(_ref, \"text-\".concat(variant), variant && !(active || this.disabled)), _ref)],\n attrs: this.computedAttrs,\n on: {\n click: this.onClick\n },\n ref: 'button'\n }, this.normalizeSlot())]);\n }\n });\n\n var props$1K = makePropsConfigurable({\n id: makeProp(PROP_TYPE_STRING),\n tag: makeProp(PROP_TYPE_STRING, 'header'),\n variant: makeProp(PROP_TYPE_STRING)\n }, NAME_DROPDOWN_HEADER); // --- Main component ---\n // @vue/component\n\n var BDropdownHeader = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_HEADER,\n functional: true,\n props: props$1K,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var tag = props.tag,\n variant = props.variant;\n return h('li', a(omit(data, ['attrs']), {\n attrs: {\n role: 'presentation'\n }\n }), [h(tag, {\n staticClass: 'dropdown-header',\n class: _defineProperty({}, \"text-\".concat(variant), variant),\n attrs: _objectSpread2$3(_objectSpread2$3({}, data.attrs || {}), {}, {\n id: props.id || null,\n role: isTag(tag, 'header') ? null : 'heading'\n }),\n ref: 'header'\n }, children)]);\n }\n });\n\n var props$1J = makePropsConfigurable({\n tag: makeProp(PROP_TYPE_STRING, 'hr')\n }, NAME_DROPDOWN_DIVIDER); // --- Main component ---\n // @vue/component\n\n var BDropdownDivider = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_DIVIDER,\n functional: true,\n props: props$1J,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data;\n return h('li', a(omit(data, ['attrs']), {\n attrs: {\n role: 'presentation'\n }\n }), [h(props.tag, {\n staticClass: 'dropdown-divider',\n attrs: _objectSpread2$3(_objectSpread2$3({}, data.attrs || {}), {}, {\n role: 'separator',\n 'aria-orientation': 'horizontal'\n }),\n ref: 'divider'\n })]);\n }\n });\n\n var props$1I = makePropsConfigurable({\n id: makeProp(PROP_TYPE_STRING),\n inline: makeProp(PROP_TYPE_BOOLEAN, false),\n novalidate: makeProp(PROP_TYPE_BOOLEAN, false),\n validated: makeProp(PROP_TYPE_BOOLEAN, false)\n }, NAME_FORM); // --- Main component ---\n // @vue/component\n\n var BForm = /*#__PURE__*/extend({\n name: NAME_FORM,\n functional: true,\n props: props$1I,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n return h('form', a(data, {\n class: {\n 'form-inline': props.inline,\n 'was-validated': props.validated\n },\n attrs: {\n id: props.id,\n novalidate: props.novalidate\n }\n }), children);\n }\n });\n\n var props$1H = makePropsConfigurable(sortKeys(_objectSpread2$3(_objectSpread2$3({}, props$1I), {}, {\n disabled: makeProp(PROP_TYPE_BOOLEAN, false),\n formClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING)\n })), NAME_DROPDOWN_FORM); // --- Main component ---\n // @vue/component\n\n var BDropdownForm = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_FORM,\n functional: true,\n props: props$1H,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n listeners = _ref.listeners,\n children = _ref.children;\n return h('li', a(omit(data, ['attrs', 'on']), {\n attrs: {\n role: 'presentation'\n }\n }), [h(BForm, {\n staticClass: 'b-dropdown-form',\n class: [props.formClass, {\n disabled: props.disabled\n }],\n props: props,\n attrs: _objectSpread2$3(_objectSpread2$3({}, data.attrs || {}), {}, {\n disabled: props.disabled,\n // Tab index of -1 for keyboard navigation\n tabindex: props.disabled ? null : '-1'\n }),\n on: listeners,\n ref: 'form'\n }, children)]);\n }\n });\n\n var props$1G = makePropsConfigurable({\n tag: makeProp(PROP_TYPE_STRING, 'p'),\n textClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n variant: makeProp(PROP_TYPE_STRING)\n }, NAME_DROPDOWN_TEXT); // --- Main component ---\n // @vue/component\n\n var BDropdownText = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_TEXT,\n functional: true,\n props: props$1G,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var tag = props.tag,\n textClass = props.textClass,\n variant = props.variant;\n return h('li', a(omit(data, ['attrs']), {\n attrs: {\n role: 'presentation'\n }\n }), [h(tag, {\n staticClass: 'b-dropdown-text',\n class: [textClass, _defineProperty({}, \"text-\".concat(variant), variant)],\n props: props,\n attrs: data.attrs || {},\n ref: 'text'\n }, children)]);\n }\n });\n\n var props$1F = makePropsConfigurable({\n ariaDescribedby: makeProp(PROP_TYPE_STRING),\n header: makeProp(PROP_TYPE_STRING),\n headerClasses: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),\n headerTag: makeProp(PROP_TYPE_STRING, 'header'),\n headerVariant: makeProp(PROP_TYPE_STRING),\n id: makeProp(PROP_TYPE_STRING)\n }, NAME_DROPDOWN_GROUP); // --- Main component ---\n // @vue/component\n\n var BDropdownGroup = /*#__PURE__*/extend({\n name: NAME_DROPDOWN_GROUP,\n functional: true,\n props: props$1F,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n slots = _ref.slots,\n scopedSlots = _ref.scopedSlots;\n var id = props.id,\n variant = props.variant,\n header = props.header,\n headerTag = props.headerTag;\n var $slots = slots();\n var $scopedSlots = scopedSlots || {};\n var slotScope = {};\n var headerId = id ? \"_bv_\".concat(id, \"_group_dd_header\") : null;\n var $header = h();\n\n if (hasNormalizedSlot(SLOT_NAME_HEADER, $scopedSlots, $slots) || header) {\n $header = h(headerTag, {\n staticClass: 'dropdown-header',\n class: [props.headerClasses, _defineProperty({}, \"text-\".concat(variant), variant)],\n attrs: {\n id: headerId,\n role: isTag(headerTag, 'header') ? null : 'heading'\n }\n }, normalizeSlot(SLOT_NAME_HEADER, slotScope, $scopedSlots, $slots) || header);\n }\n\n return h('li', a(omit(data, ['attrs']), {\n attrs: {\n role: 'presentation'\n }\n }), [$header, h('ul', {\n staticClass: 'list-unstyled',\n attrs: _objectSpread2$3(_objectSpread2$3({}, data.attrs || {}), {}, {\n id: id,\n role: 'group',\n 'aria-describedby': [headerId, props.ariaDescribedBy].filter(identity).join(' ').trim() || null\n })\n }, normalizeSlot(SLOT_NAME_DEFAULT, slotScope, $scopedSlots, $slots))]);\n }\n });\n\n var DropdownPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BDropdown: BDropdown,\n BDd: BDropdown,\n BDropdownItem: BDropdownItem,\n BDdItem: BDropdownItem,\n BDropdownItemButton: BDropdownItemButton,\n BDropdownItemBtn: BDropdownItemButton,\n BDdItemButton: BDropdownItemButton,\n BDdItemBtn: BDropdownItemButton,\n BDropdownHeader: BDropdownHeader,\n BDdHeader: BDropdownHeader,\n BDropdownDivider: BDropdownDivider,\n BDdDivider: BDropdownDivider,\n BDropdownForm: BDropdownForm,\n BDdForm: BDropdownForm,\n BDropdownText: BDropdownText,\n BDdText: BDropdownText,\n BDropdownGroup: BDropdownGroup,\n BDdGroup: BDropdownGroup\n }\n });\n\n var TYPES$2 = ['iframe', 'embed', 'video', 'object', 'img', 'b-img', 'b-img-lazy']; // --- Props ---\n\n var props$1E = makePropsConfigurable({\n aspect: makeProp(PROP_TYPE_STRING, '16by9'),\n tag: makeProp(PROP_TYPE_STRING, 'div'),\n type: makeProp(PROP_TYPE_STRING, 'iframe', function (value) {\n return arrayIncludes(TYPES$2, value);\n })\n }, NAME_EMBED); // --- Main component ---\n // @vue/component\n\n var BEmbed = /*#__PURE__*/extend({\n name: NAME_EMBED,\n functional: true,\n props: props$1E,\n render: function render(h, _ref) {\n var props = _ref.props,\n data = _ref.data,\n children = _ref.children;\n var aspect = props.aspect;\n return h(props.tag, {\n staticClass: 'embed-responsive',\n class: _defineProperty({}, \"embed-responsive-\".concat(aspect), aspect),\n ref: data.ref\n }, [h(props.type, a(omit(data, ['ref']), {\n staticClass: 'embed-responsive-item'\n }), children)]);\n }\n });\n\n var EmbedPlugin = /*#__PURE__*/pluginFactory({\n components: {\n BEmbed: BEmbed\n }\n });\n\n var OPTIONS_OBJECT_DEPRECATED_MSG = 'Setting prop \"options\" to an object is deprecated. Use the array format instead.'; // --- Props ---\n\n var props$1D = makePropsConfigurable({\n disabledField: makeProp(PROP_TYPE_STRING, 'disabled'),\n htmlField: makeProp(PROP_TYPE_STRING, 'html'),\n options: makeProp(PROP_TYPE_ARRAY_OBJECT, []),\n textField: makeProp(PROP_TYPE_STRING, 'text'),\n valueField: makeProp(PROP_TYPE_STRING, 'value')\n }, 'formOptionControls'); // --- Mixin ---\n // @vue/component\n\n var formOptionsMixin = extend({\n props: props$1D,\n computed: {\n formOptions: function formOptions() {\n return this.normalizeOptions(this.options);\n }\n },\n methods: {\n normalizeOption: function normalizeOption(option) {\n var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n\n // When the option is an object, normalize it\n if (isPlainObject(option)) {\n var value = get(option, this.valueField);\n var text = get(option, this.textField);\n return {\n value: isUndefined(value) ? key || text : value,\n text: stripTags(String(isUndefined(text) ? key : text)),\n html: get(option, this.htmlField),\n disabled: Boolean(get(option, this.disabledField))\n };\n } // Otherwise create an `