"use strict";
// The require scope
var __webpack_require__ = {};
/************************************************************************/ // webpack/runtime/define_property_getters
(()=>{
    __webpack_require__.d = function(exports1, definition) {
        for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
            enumerable: true,
            get: definition[key]
        });
    };
})();
// webpack/runtime/has_own_property
(()=>{
    __webpack_require__.o = function(obj, prop) {
        return Object.prototype.hasOwnProperty.call(obj, prop);
    };
})();
// webpack/runtime/make_namespace_object
(()=>{
    // define __esModule on exports
    __webpack_require__.r = function(exports1) {
        if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
            value: 'Module'
        });
        Object.defineProperty(exports1, '__esModule', {
            value: true
        });
    };
})();
/************************************************************************/ var __webpack_exports__ = {};
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);
// EXPORTS
__webpack_require__.d(__webpack_exports__, {
    filterOptions: ()=>/* binding */ filterOptions,
    promiseOptions: ()=>/* binding */ promiseOptions,
    filterColors: ()=>/* binding */ filterColors,
    customOptions: ()=>/* binding */ customOptions,
    EMOJIS: ()=>/* binding */ EMOJIS,
    getLength: ()=>/* binding */ getLength
});
const external_selectData_js_namespaceObject = require("./selectData.js");
const filterOptions = (candidate, input)=>{
    if (input) return candidate.value === customOptions[0].value;
    return true;
};
const customOptions = [
    {
        value: 'custom',
        label: 'Using a custom filter to always display this option on search'
    },
    ...external_selectData_js_namespaceObject.colourOptions
];
const EMOJIS = [
    '👍',
    '🤙',
    '👏',
    '👌',
    '🙌',
    '✌️',
    '🖖',
    '👐'
];
const filterColors = (inputValue)=>external_selectData_js_namespaceObject.colourOptions.filter((i)=>i.label.toLowerCase().includes(inputValue.toLowerCase()));
const promiseOptions = (inputValue)=>new Promise((resolve)=>{
        setTimeout(()=>{
            resolve(filterColors(inputValue));
        }, 1000);
    });
function getLength(options) {
    return options.reduce((acc, curr)=>{
        if ('options' in curr) return acc + getLength(curr.options);
        return acc + 1;
    }, 0);
}
var __webpack_export_target__ = exports;
for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
    value: true
});
