Merge pull request #33 from apuc/add-ts-rebuild-core

rebuild core to TS
This commit is contained in:
MaxOvs19 2023-01-18 19:42:48 +03:00 committed by GitHub
commit 15f6c19650
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
17 changed files with 1877 additions and 807 deletions

View File

@ -20,3 +20,8 @@
- Исправленны выявленные баги. - Исправленны выявленные баги.
- Исправленно отображение страницы с примером на мобильных устройствах. - Исправленно отображение страницы с примером на мобильных устройствах.
- Обновленна документация! - Обновленна документация!
### 00.00.2023 - обновление 0.2.1
- Весь селект переписан на ts.
- Исправленны баги и недочеты.

View File

@ -1,6 +1,6 @@
# CG-SELECT # CG-SELECT
## version ~ 0.1.171 ## version ~ 0.2.1
Этот компонент позволяет создать кастомный селект. Он предлагает более гибкую настройку и использование селекта. Этот компонент позволяет создать кастомный селект. Он предлагает более гибкую настройку и использование селекта.
Доступна кастомизация, мультивыбор и живой поиск по елементам. Доступна кастомизация, мультивыбор и живой поиск по елементам.
@ -45,10 +45,9 @@ npm i cg-select
### Пример создния обычного селекта ### Пример создния обычного селекта
```javascript ```javascript
import { DropDown } from 'cg-select/src/cg-select'; import { CGSelect } from 'cg-select';
import 'cg-select/src/main.scss';
const dropdown = new DropDown({ const dropdown = new CGSelect({
selector: '.cg-dropdown_selector', selector: '.cg-dropdown_selector',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
items: [ items: [

View File

@ -46,7 +46,7 @@
<button type="button" class="check-code" id="first">Посмотреть код</button> <button type="button" class="check-code" id="first">Посмотреть код</button>
<code id="codeFirst"> <code id="codeFirst">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_one',</span> selector: <span class="code__string">'.cg-dropdown_one',</span>
placeholder: <span class="code__string">'Выберите авто',</span> placeholder: <span class="code__string">'Выберите авто',</span>
lable: <span class="code__string">'EXAMPLE',</span> lable: <span class="code__string">'EXAMPLE',</span>
@ -89,7 +89,7 @@
<button type="button" class="check-code" id="Native">Посмотреть код</button> <button type="button" class="check-code" id="Native">Посмотреть код</button>
<code id="codeNative"> <code id="codeNative">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_one',</span> selector: <span class="code__string">'.cg-dropdown_one',</span>
placeholder: <span class="code__string">'Выберите авто',</span> placeholder: <span class="code__string">'Выберите авто',</span>
nativeSelectMode: <span class="code__keyword">true,</span> nativeSelectMode: <span class="code__keyword">true,</span>
@ -133,7 +133,7 @@
<code id="codeSix"> <code id="codeSix">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_listDisplayMode',</span> selector: <span class="code__string">'.cg-dropdown_listDisplayMode',</span>
placeholder: <span class="code__string">'Выберите авто',</span> placeholder: <span class="code__string">'Выберите авто',</span>
listDisplayMode: <span class="code__keyword">true,</span> listDisplayMode: <span class="code__keyword">true,</span>
@ -171,7 +171,7 @@
<code id="codeSecond"> <code id="codeSecond">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_three',</span> selector: <span class="code__string">'.cg-dropdown_three',</span>
placeholder: <span class="code__string">'URL',</span> placeholder: <span class="code__string">'URL',</span>
url: <span class="code__string">'https://jsonplaceholder.typicode.com/users',</span> url: <span class="code__string">'https://jsonplaceholder.typicode.com/users',</span>
@ -201,7 +201,7 @@
<code id="codeThird"> <code id="codeThird">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_categories',</span> selector: <span class="code__string">'.cg-dropdown_categories',</span>
placeholder: <span class="code__string">'Выберите регион',</span> placeholder: <span class="code__string">'Выберите регион',</span>
searchMode: <span class="code__keyword">true,</span> searchMode: <span class="code__keyword">true,</span>
@ -267,7 +267,7 @@
<code id="codeFourth"> <code id="codeFourth">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_usedBtn',</span> selector: <span class="code__string">'.cg-dropdown_usedBtn',</span>
placeholder: <span class="code__string">'Выберите авто',</span> placeholder: <span class="code__string">'Выберите авто',</span>
searchMode: <span class="code__keyword">true,</span> searchMode: <span class="code__keyword">true,</span>
@ -323,7 +323,7 @@
<button type="button" class="check-code" id="fifth">Посмотреть код</button> <button type="button" class="check-code" id="fifth">Посмотреть код</button>
<code id="codeFifth"> <code id="codeFifth">
<pre> <pre>
<span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">DropDown</span>({ <span class="code__keyword">const</span> <span class="code__var">dropdown</span> = <span class="code__keyword">new</span> <span class="code__class">CGSelect</span>({
selector: <span class="code__string">'.cg-dropdown_checkboxDisable',</span> selector: <span class="code__string">'.cg-dropdown_checkboxDisable',</span>
placeholder: <span class="code__string">'Выберите авто',</span> placeholder: <span class="code__string">'Выберите авто',</span>
searchMode: <span class="code__keyword">true,</span> searchMode: <span class="code__keyword">true,</span>

View File

@ -1,8 +1,8 @@
import DropDown from '../index'; import { CGSelect } from '../src/cg-select';
import './example'; import './example';
// ------------------------------Обычный селект-------------------- // ------------------------------Обычный селект--------------------
const dropdown = new DropDown({ const dropdown = new CGSelect({
selector: '.cg-dropdown_one', selector: '.cg-dropdown_one',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
lable: 'EXAMPLE', lable: 'EXAMPLE',
@ -28,7 +28,7 @@ const dropdown = new DropDown({
}); });
// ------------------------------NativeSelect----------------------- // ------------------------------NativeSelect-----------------------
const dropdownNativeSelect = new DropDown({ const dropdownNativeSelect = new CGSelect({
selector: '.cg-dropdown_selectNative', selector: '.cg-dropdown_selectNative',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
nativeSelectMode: true, nativeSelectMode: true,
@ -43,7 +43,7 @@ const dropdownNativeSelect = new DropDown({
'MAN', 'MAN',
'Ferari', 'Ferari',
'Kamaz', 'Kamaz',
'Ural' 'Ural',
], ],
styles: { styles: {
head: { head: {
@ -56,7 +56,7 @@ const dropdownNativeSelect = new DropDown({
}); });
// ------------------------------listDisplayMode-------------------- // ------------------------------listDisplayMode--------------------
const dropdownlistDisplayMode = new DropDown({ const dropdownlistDisplayMode = new CGSelect({
selector: '.cg-dropdown_listDisplayMode', selector: '.cg-dropdown_listDisplayMode',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
listDisplayMode: true, listDisplayMode: true,
@ -81,26 +81,8 @@ const dropdownlistDisplayMode = new DropDown({
}, },
}); });
// ------------------------------URL--------------------
const dropdown3 = new DropDown({
selector: '.cg-dropdown_three',
placeholder: 'URL',
url: 'https://jsonplaceholder.typicode.com/users',
searchMode: true,
darkTheme: false,
language: 'ru',
styles: {
head: {
width: '830px',
},
list: {
width: '824px',
},
},
});
// --------------------------------Категории-------------------------- // --------------------------------Категории--------------------------
const dropdown4 = new DropDown({ const dropdown4 = new CGSelect({
selector: '.cg-dropdown_categories', selector: '.cg-dropdown_categories',
placeholder: 'Выберите регион', placeholder: 'Выберите регион',
searchMode: true, searchMode: true,
@ -145,7 +127,7 @@ const dropdown4 = new DropDown({
}); });
//----------------управление с помощью кнопок---------------------------------- //----------------управление с помощью кнопок----------------------------------
const dropdownBtn = new DropDown({ const dropdownBtn = new CGSelect({
selector: '.cg-dropdown_usedBtn', selector: '.cg-dropdown_usedBtn',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
searchMode: true, searchMode: true,
@ -192,7 +174,7 @@ dropdownBtn.buttonControl(buttonOpen, 'open');
dropdownBtn.buttonControl(buttonClose, 'close'); dropdownBtn.buttonControl(buttonClose, 'close');
//-------------------------Функция Disabled---------------------------------- //-------------------------Функция Disabled----------------------------------
const dropdownDisabled = new DropDown({ const dropdownDisabled = new CGSelect({
selector: '.cg-dropdown_checkboxDisable', selector: '.cg-dropdown_checkboxDisable',
placeholder: 'Выберите авто', placeholder: 'Выберите авто',
searchMode: true, searchMode: true,
@ -230,3 +212,22 @@ chbox.addEventListener('click', () => {
dropdownDisabled.disabled(true); dropdownDisabled.disabled(true);
} }
}); });
// ------------------------------URL--------------------
const dropdown3 = new CGSelect({
selector: '.cg-dropdown_three',
placeholder: 'URL',
url: 'https://jsonplaceholder.typicode.com/todos',
searchMode: true,
darkTheme: false,
language: 'ru',
styles: {
head: {
width: '830px',
},
list: {
width: '824px',
},
},
multiselect: true,
});

View File

@ -1,3 +1,3 @@
import { DropDown } from './src/cg-select'; import { CGSelect } from './src/cg-select';
export default DropDown; export default CGSelect;

710
package-lock.json generated
View File

@ -1,16 +1,19 @@
{ {
"name": "cg-select", "name": "cg-select",
"version": "0.1.171", "version": "0.2.1",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "cg-select", "name": "cg-select",
"version": "0.1.171", "version": "0.2.1",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"@parcel/optimizer-css": "^2.8.0", "@parcel/optimizer-css": "^2.8.0",
"gh-pages": "^4.0.0" "@types/prettier": "^2.7.2",
"gh-pages": "^4.0.0",
"typedoc": "^0.23.24",
"typescript": "^4.9.4"
}, },
"devDependencies": { "devDependencies": {
"@parcel/transformer-sass": "^2.7.0", "@parcel/transformer-sass": "^2.7.0",
@ -799,6 +802,304 @@
"url": "https://opencollective.com/parcel" "url": "https://opencollective.com/parcel"
} }
}, },
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/core/-/core-2.8.2.tgz",
"integrity": "sha512-ZGuq6p+Lzx6fgufaVsuOBwgpU3hgskTvIDIMdIDi9gOZyhGPK7U2srXdX+VYUL5ZSGbX04/P6QlB9FMAXK+nEg==",
"peer": true,
"dependencies": {
"@mischnic/json-sourcemap": "^0.1.0",
"@parcel/cache": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/events": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/graph": "2.8.2",
"@parcel/hash": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/package-manager": "2.8.2",
"@parcel/plugin": "2.8.2",
"@parcel/source-map": "^2.1.1",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/workers": "2.8.2",
"abortcontroller-polyfill": "^1.1.9",
"base-x": "^3.0.8",
"browserslist": "^4.6.6",
"clone": "^2.1.1",
"dotenv": "^7.0.0",
"dotenv-expand": "^5.1.0",
"json5": "^2.2.0",
"msgpackr": "^1.5.4",
"nullthrows": "^1.1.1",
"semver": "^5.7.1"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/cache": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/cache/-/cache-2.8.2.tgz",
"integrity": "sha512-kiyoOgh1RXp5qp+wlb8Pi/Z7o9D82Oj5RlHnKSAauyR7jgnI8Vq8JTeBmlLqrf+kHxcDcp2p86hidSeANhlQNg==",
"peer": true,
"dependencies": {
"@parcel/fs": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/utils": "2.8.2",
"lmdb": "2.5.2"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
},
"peerDependencies": {
"@parcel/core": "^2.8.2"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/codeframe": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/codeframe/-/codeframe-2.8.2.tgz",
"integrity": "sha512-U2GT9gq1Zs3Gr83j8JIs10bLbGOHFl57Y8D57nrdR05F4iilV/UR6K7jkhdoiFc9WiHh3ewvrko5+pSdAVFPgQ==",
"peer": true,
"dependencies": {
"chalk": "^4.1.0"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/diagnostic": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.2.tgz",
"integrity": "sha512-tGSMwM2rSYLjJW0fCd9gb3tNjfCX/83PZ10/5u2E33UZVkk8OIHsQmsrtq2H2g4oQL3rFxkfEx6nGPDGHwlx7A==",
"peer": true,
"dependencies": {
"@mischnic/json-sourcemap": "^0.1.0",
"nullthrows": "^1.1.1"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/events": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/events/-/events-2.8.2.tgz",
"integrity": "sha512-o5etrsKm16y8iRPnjtEBNy4lD0WAigD66yt/RZl9Rx0vPVDly/63Rr9+BrXWVW7bJ7x0S0VVpWW4j3f/qZOsXg==",
"peer": true,
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/fs": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/fs/-/fs-2.8.2.tgz",
"integrity": "sha512-aN8znbMndSqn1xwZEmMblzqmJsxcExv2jKLl/a9RUHAP7LaPYcPZIykDL3YwGCiKTCzjmRpXnNoyosjFFeBaHA==",
"peer": true,
"dependencies": {
"@parcel/fs-search": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/watcher": "^2.0.7",
"@parcel/workers": "2.8.2"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
},
"peerDependencies": {
"@parcel/core": "^2.8.2"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/fs-search": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/fs-search/-/fs-search-2.8.2.tgz",
"integrity": "sha512-ovQnupRm/MoE/tbgH0Ivknk0QYenXAewjcog+T5umDmUlTmnIRZjURrgDf5Xtw8T/CD5Xv+HmIXpJ9Ez/LzJpw==",
"peer": true,
"dependencies": {
"detect-libc": "^1.0.3"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/hash": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.2.tgz",
"integrity": "sha512-NBnP8Hu0xvAqAfZXRaMM66i8nJyxpKS86BbhwkbgTGbwO1OY87GERliHeREJfcER0E0ZzwNow7MNR8ZDm6IvJQ==",
"peer": true,
"dependencies": {
"detect-libc": "^1.0.3",
"xxhash-wasm": "^0.4.2"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/logger": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/logger/-/logger-2.8.2.tgz",
"integrity": "sha512-zlhK6QHxfFJMlVJxxcCw0xxBDrYPFPOhMxSD6p6b0z9Yct1l3NdpmfabgjKX8wnZmHokFsil6daleM+M80n2Ew==",
"peer": true,
"dependencies": {
"@parcel/diagnostic": "2.8.2",
"@parcel/events": "2.8.2"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/markdown-ansi": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/markdown-ansi/-/markdown-ansi-2.8.2.tgz",
"integrity": "sha512-5y29TXgRgG0ybuXaDsDk4Aofg/nDUeAAyVl9/toYCDDhxpQV4yZt8WNPu4PaNYKGLuNgXwsmz+ryZQHGmfbAIQ==",
"peer": true,
"dependencies": {
"chalk": "^4.1.0"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/package-manager": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/package-manager/-/package-manager-2.8.2.tgz",
"integrity": "sha512-hx4Imi0yhsSS0aNZkEANPYNNKqBuR63EUNWSxMyHh4ZOvbHoOXnMn1ySGdx6v0oi9HvKymNsLMQ1T5CuI4l4Bw==",
"peer": true,
"dependencies": {
"@parcel/diagnostic": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/workers": "2.8.2",
"semver": "^5.7.1"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
},
"peerDependencies": {
"@parcel/core": "^2.8.2"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/plugin": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/plugin/-/plugin-2.8.2.tgz",
"integrity": "sha512-YG7TWfKsoNm72jbz3b3TLec0qJHVkuAWSzGzowdIhX37cP1kRfp6BU2VcH+qYPP/KYJLzhcZa9n3by147mGcxw==",
"peer": true,
"dependencies": {
"@parcel/types": "2.8.2"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/types": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/types/-/types-2.8.2.tgz",
"integrity": "sha512-HAYhokWxM10raIhqaYj9VR9eAvJ+xP2sNfQ1IcQybHpq3qblcBe/4jDeuUpwIyKeQ4gorp7xY+q8KDoR20j43w==",
"peer": true,
"dependencies": {
"@parcel/cache": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/package-manager": "2.8.2",
"@parcel/source-map": "^2.1.1",
"@parcel/workers": "2.8.2",
"utility-types": "^3.10.0"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/utils": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/utils/-/utils-2.8.2.tgz",
"integrity": "sha512-Ufax7wZxC9FNsUpR0EU7Z22LEY/q9jjsDTwswctCdfpWb7TE/NudOfM9myycfRvwBVEYN50lPbkt1QltEVnXQQ==",
"peer": true,
"dependencies": {
"@parcel/codeframe": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/hash": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/markdown-ansi": "2.8.2",
"@parcel/source-map": "^2.1.1",
"chalk": "^4.1.0"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/core/node_modules/@parcel/workers": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/workers/-/workers-2.8.2.tgz",
"integrity": "sha512-Eg6CofIrJSNBa2fjXwvnzVLPKwR/6fkfQTFAm3Jl+4JYLVknBtTSFzQNp/Fa+HUEG889H9ucTk2CBi/fVPBAFw==",
"peer": true,
"dependencies": {
"@parcel/diagnostic": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"chrome-trace-event": "^1.0.2",
"nullthrows": "^1.1.1"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
},
"peerDependencies": {
"@parcel/core": "^2.8.2"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/diagnostic": { "node_modules/@parcel/optimizer-css/node_modules/@parcel/diagnostic": {
"version": "2.8.0", "version": "2.8.0",
"resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.0.tgz", "resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.0.tgz",
@ -864,6 +1165,22 @@
"url": "https://opencollective.com/parcel" "url": "https://opencollective.com/parcel"
} }
}, },
"node_modules/@parcel/optimizer-css/node_modules/@parcel/graph": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/graph/-/graph-2.8.2.tgz",
"integrity": "sha512-SLEvBQBgfkXgU4EBu30+CNanpuKjcNuEv/x8SwobCF0i3Rk+QKbe7T36bNR7727mao++2Ha69q93Dd9dTPw0kQ==",
"peer": true,
"dependencies": {
"nullthrows": "^1.1.1"
},
"engines": {
"node": ">= 12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/parcel"
}
},
"node_modules/@parcel/optimizer-css/node_modules/@parcel/hash": { "node_modules/@parcel/optimizer-css/node_modules/@parcel/hash": {
"version": "2.8.0", "version": "2.8.0",
"resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.0.tgz", "resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.0.tgz",
@ -1766,11 +2083,15 @@
"integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==",
"dev": true "dev": true
}, },
"node_modules/@types/prettier": {
"version": "2.7.2",
"resolved": "https://registry.npmjs.org/@types/prettier/-/prettier-2.7.2.tgz",
"integrity": "sha512-KufADq8uQqo1pYKVIYzfKbJfBAc0sOeXqGbFaSpv8MRmC/zXgowNZmFcbngndGk922QDmOASEXUZCaY48gs4cg=="
},
"node_modules/abortcontroller-polyfill": { "node_modules/abortcontroller-polyfill": {
"version": "1.7.3", "version": "1.7.3",
"resolved": "https://registry.npmjs.org/abortcontroller-polyfill/-/abortcontroller-polyfill-1.7.3.tgz", "resolved": "https://registry.npmjs.org/abortcontroller-polyfill/-/abortcontroller-polyfill-1.7.3.tgz",
"integrity": "sha512-zetDJxd89y3X99Kvo4qFx8GKlt6GsvN3UcRZHwU6iFA/0KiOmhkTVhe8oRoTBiTVPZu09x3vCra47+w8Yz1+2Q==", "integrity": "sha512-zetDJxd89y3X99Kvo4qFx8GKlt6GsvN3UcRZHwU6iFA/0KiOmhkTVhe8oRoTBiTVPZu09x3vCra47+w8Yz1+2Q=="
"dev": true
}, },
"node_modules/acorn": { "node_modules/acorn": {
"version": "8.8.0", "version": "8.8.0",
@ -1853,7 +2174,6 @@
"version": "3.0.9", "version": "3.0.9",
"resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz", "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz",
"integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==", "integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==",
"dev": true,
"dependencies": { "dependencies": {
"safe-buffer": "^5.0.1" "safe-buffer": "^5.0.1"
} }
@ -2023,7 +2343,6 @@
"version": "2.1.2", "version": "2.1.2",
"resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz",
"integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==",
"dev": true,
"engines": { "engines": {
"node": ">=0.8" "node": ">=0.8"
} }
@ -2211,7 +2530,6 @@
"version": "7.0.0", "version": "7.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-7.0.0.tgz", "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-7.0.0.tgz",
"integrity": "sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g==", "integrity": "sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g==",
"dev": true,
"engines": { "engines": {
"node": ">=6" "node": ">=6"
} }
@ -2219,8 +2537,7 @@
"node_modules/dotenv-expand": { "node_modules/dotenv-expand": {
"version": "5.1.0", "version": "5.1.0",
"resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-5.1.0.tgz", "resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-5.1.0.tgz",
"integrity": "sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA==", "integrity": "sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA=="
"dev": true
}, },
"node_modules/electron-to-chromium": { "node_modules/electron-to-chromium": {
"version": "1.4.251", "version": "1.4.251",
@ -2700,6 +3017,11 @@
"node": ">=6" "node": ">=6"
} }
}, },
"node_modules/jsonc-parser": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.0.tgz",
"integrity": "sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w=="
},
"node_modules/jsonfile": { "node_modules/jsonfile": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz",
@ -2951,6 +3273,11 @@
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="
}, },
"node_modules/lunr": {
"version": "2.3.9",
"resolved": "https://registry.npmjs.org/lunr/-/lunr-2.3.9.tgz",
"integrity": "sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow=="
},
"node_modules/make-dir": { "node_modules/make-dir": {
"version": "3.1.0", "version": "3.1.0",
"resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz",
@ -3012,7 +3339,6 @@
"version": "4.2.5", "version": "4.2.5",
"resolved": "https://registry.npmjs.org/marked/-/marked-4.2.5.tgz", "resolved": "https://registry.npmjs.org/marked/-/marked-4.2.5.tgz",
"integrity": "sha512-jPueVhumq7idETHkb203WDD4fMA3yV9emQ5vLwop58lu8bTclMghBWcYAavlDqIEMaisADinV1TooIFCfqOsYQ==", "integrity": "sha512-jPueVhumq7idETHkb203WDD4fMA3yV9emQ5vLwop58lu8bTclMghBWcYAavlDqIEMaisADinV1TooIFCfqOsYQ==",
"dev": true,
"bin": { "bin": {
"marked": "bin/marked.js" "marked": "bin/marked.js"
}, },
@ -3461,7 +3787,6 @@
"version": "5.2.1", "version": "5.2.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
"integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==",
"dev": true,
"funding": [ "funding": [
{ {
"type": "github", "type": "github",
@ -3502,6 +3827,16 @@
"semver": "bin/semver" "semver": "bin/semver"
} }
}, },
"node_modules/shiki": {
"version": "0.12.1",
"resolved": "https://registry.npmjs.org/shiki/-/shiki-0.12.1.tgz",
"integrity": "sha512-aieaV1m349rZINEBkjxh2QbBvFFQOlgqYTNtCal82hHj4dDZ76oMlQIX+C7ryerBTDiga3e5NfH6smjdJ02BbQ==",
"dependencies": {
"jsonc-parser": "^3.2.0",
"vscode-oniguruma": "^1.7.0",
"vscode-textmate": "^8.0.0"
}
},
"node_modules/source-map": { "node_modules/source-map": {
"version": "0.6.1", "version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
@ -3675,6 +4010,57 @@
"url": "https://github.com/sponsors/sindresorhus" "url": "https://github.com/sponsors/sindresorhus"
} }
}, },
"node_modules/typedoc": {
"version": "0.23.24",
"resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.23.24.tgz",
"integrity": "sha512-bfmy8lNQh+WrPYcJbtjQ6JEEsVl/ce1ZIXyXhyW+a1vFrjO39t6J8sL/d6FfAGrJTc7McCXgk9AanYBSNvLdIA==",
"dependencies": {
"lunr": "^2.3.9",
"marked": "^4.2.5",
"minimatch": "^5.1.2",
"shiki": "^0.12.1"
},
"bin": {
"typedoc": "bin/typedoc"
},
"engines": {
"node": ">= 14.14"
},
"peerDependencies": {
"typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x"
}
},
"node_modules/typedoc/node_modules/brace-expansion": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz",
"integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==",
"dependencies": {
"balanced-match": "^1.0.0"
}
},
"node_modules/typedoc/node_modules/minimatch": {
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.2.tgz",
"integrity": "sha512-bNH9mmM9qsJ2X4r2Nat1B//1dJVcn3+iBLa3IgqJ7EbGaDNepL9QSHOxN4ng33s52VMMhhIfgCYDk3C4ZmlDAg==",
"dependencies": {
"brace-expansion": "^2.0.1"
},
"engines": {
"node": ">=10"
}
},
"node_modules/typescript": {
"version": "4.9.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.4.tgz",
"integrity": "sha512-Uz+dTXYzxXXbsFpM86Wh3dKCxrQqUcVMxwU54orwlJjOpO3ao8L7j5lH+dWfTwgCwIuM9GQ2kvVotzYJMXTBZg==",
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
},
"engines": {
"node": ">=4.2.0"
}
},
"node_modules/uc.micro": { "node_modules/uc.micro": {
"version": "1.0.6", "version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz", "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
@ -3734,6 +4120,16 @@
"integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==", "integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==",
"dev": true "dev": true
}, },
"node_modules/vscode-oniguruma": {
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/vscode-oniguruma/-/vscode-oniguruma-1.7.0.tgz",
"integrity": "sha512-L9WMGRfrjOhgHSdOYgCt/yRMsXzLDJSL7BPrOZt73gU0iWO4mpqzqQzOz5srxqTvMBaR0XZTSrVWo4j55Rc6cA=="
},
"node_modules/vscode-textmate": {
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/vscode-textmate/-/vscode-textmate-8.0.0.tgz",
"integrity": "sha512-AFbieoL7a5LMqcnOF04ji+rpXadgOXnZsxQr//r83kLPr7biP7am3g9zbaZIaBGwBRWeSvoMD4mgPdX3e4NWBg=="
},
"node_modules/weak-lru-cache": { "node_modules/weak-lru-cache": {
"version": "1.2.2", "version": "1.2.2",
"resolved": "https://registry.npmjs.org/weak-lru-cache/-/weak-lru-cache-1.2.2.tgz", "resolved": "https://registry.npmjs.org/weak-lru-cache/-/weak-lru-cache-1.2.2.tgz",
@ -4275,6 +4671,196 @@
"chalk": "^4.1.0" "chalk": "^4.1.0"
} }
}, },
"@parcel/core": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/core/-/core-2.8.2.tgz",
"integrity": "sha512-ZGuq6p+Lzx6fgufaVsuOBwgpU3hgskTvIDIMdIDi9gOZyhGPK7U2srXdX+VYUL5ZSGbX04/P6QlB9FMAXK+nEg==",
"peer": true,
"requires": {
"@mischnic/json-sourcemap": "^0.1.0",
"@parcel/cache": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/events": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/graph": "2.8.2",
"@parcel/hash": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/package-manager": "2.8.2",
"@parcel/plugin": "2.8.2",
"@parcel/source-map": "^2.1.1",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/workers": "2.8.2",
"abortcontroller-polyfill": "^1.1.9",
"base-x": "^3.0.8",
"browserslist": "^4.6.6",
"clone": "^2.1.1",
"dotenv": "^7.0.0",
"dotenv-expand": "^5.1.0",
"json5": "^2.2.0",
"msgpackr": "^1.5.4",
"nullthrows": "^1.1.1",
"semver": "^5.7.1"
},
"dependencies": {
"@parcel/cache": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/cache/-/cache-2.8.2.tgz",
"integrity": "sha512-kiyoOgh1RXp5qp+wlb8Pi/Z7o9D82Oj5RlHnKSAauyR7jgnI8Vq8JTeBmlLqrf+kHxcDcp2p86hidSeANhlQNg==",
"peer": true,
"requires": {
"@parcel/fs": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/utils": "2.8.2",
"lmdb": "2.5.2"
}
},
"@parcel/codeframe": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/codeframe/-/codeframe-2.8.2.tgz",
"integrity": "sha512-U2GT9gq1Zs3Gr83j8JIs10bLbGOHFl57Y8D57nrdR05F4iilV/UR6K7jkhdoiFc9WiHh3ewvrko5+pSdAVFPgQ==",
"peer": true,
"requires": {
"chalk": "^4.1.0"
}
},
"@parcel/diagnostic": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.2.tgz",
"integrity": "sha512-tGSMwM2rSYLjJW0fCd9gb3tNjfCX/83PZ10/5u2E33UZVkk8OIHsQmsrtq2H2g4oQL3rFxkfEx6nGPDGHwlx7A==",
"peer": true,
"requires": {
"@mischnic/json-sourcemap": "^0.1.0",
"nullthrows": "^1.1.1"
}
},
"@parcel/events": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/events/-/events-2.8.2.tgz",
"integrity": "sha512-o5etrsKm16y8iRPnjtEBNy4lD0WAigD66yt/RZl9Rx0vPVDly/63Rr9+BrXWVW7bJ7x0S0VVpWW4j3f/qZOsXg==",
"peer": true
},
"@parcel/fs": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/fs/-/fs-2.8.2.tgz",
"integrity": "sha512-aN8znbMndSqn1xwZEmMblzqmJsxcExv2jKLl/a9RUHAP7LaPYcPZIykDL3YwGCiKTCzjmRpXnNoyosjFFeBaHA==",
"peer": true,
"requires": {
"@parcel/fs-search": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/watcher": "^2.0.7",
"@parcel/workers": "2.8.2"
}
},
"@parcel/fs-search": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/fs-search/-/fs-search-2.8.2.tgz",
"integrity": "sha512-ovQnupRm/MoE/tbgH0Ivknk0QYenXAewjcog+T5umDmUlTmnIRZjURrgDf5Xtw8T/CD5Xv+HmIXpJ9Ez/LzJpw==",
"peer": true,
"requires": {
"detect-libc": "^1.0.3"
}
},
"@parcel/hash": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.2.tgz",
"integrity": "sha512-NBnP8Hu0xvAqAfZXRaMM66i8nJyxpKS86BbhwkbgTGbwO1OY87GERliHeREJfcER0E0ZzwNow7MNR8ZDm6IvJQ==",
"peer": true,
"requires": {
"detect-libc": "^1.0.3",
"xxhash-wasm": "^0.4.2"
}
},
"@parcel/logger": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/logger/-/logger-2.8.2.tgz",
"integrity": "sha512-zlhK6QHxfFJMlVJxxcCw0xxBDrYPFPOhMxSD6p6b0z9Yct1l3NdpmfabgjKX8wnZmHokFsil6daleM+M80n2Ew==",
"peer": true,
"requires": {
"@parcel/diagnostic": "2.8.2",
"@parcel/events": "2.8.2"
}
},
"@parcel/markdown-ansi": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/markdown-ansi/-/markdown-ansi-2.8.2.tgz",
"integrity": "sha512-5y29TXgRgG0ybuXaDsDk4Aofg/nDUeAAyVl9/toYCDDhxpQV4yZt8WNPu4PaNYKGLuNgXwsmz+ryZQHGmfbAIQ==",
"peer": true,
"requires": {
"chalk": "^4.1.0"
}
},
"@parcel/package-manager": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/package-manager/-/package-manager-2.8.2.tgz",
"integrity": "sha512-hx4Imi0yhsSS0aNZkEANPYNNKqBuR63EUNWSxMyHh4ZOvbHoOXnMn1ySGdx6v0oi9HvKymNsLMQ1T5CuI4l4Bw==",
"peer": true,
"requires": {
"@parcel/diagnostic": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"@parcel/workers": "2.8.2",
"semver": "^5.7.1"
}
},
"@parcel/plugin": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/plugin/-/plugin-2.8.2.tgz",
"integrity": "sha512-YG7TWfKsoNm72jbz3b3TLec0qJHVkuAWSzGzowdIhX37cP1kRfp6BU2VcH+qYPP/KYJLzhcZa9n3by147mGcxw==",
"peer": true,
"requires": {
"@parcel/types": "2.8.2"
}
},
"@parcel/types": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/types/-/types-2.8.2.tgz",
"integrity": "sha512-HAYhokWxM10raIhqaYj9VR9eAvJ+xP2sNfQ1IcQybHpq3qblcBe/4jDeuUpwIyKeQ4gorp7xY+q8KDoR20j43w==",
"peer": true,
"requires": {
"@parcel/cache": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/fs": "2.8.2",
"@parcel/package-manager": "2.8.2",
"@parcel/source-map": "^2.1.1",
"@parcel/workers": "2.8.2",
"utility-types": "^3.10.0"
}
},
"@parcel/utils": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/utils/-/utils-2.8.2.tgz",
"integrity": "sha512-Ufax7wZxC9FNsUpR0EU7Z22LEY/q9jjsDTwswctCdfpWb7TE/NudOfM9myycfRvwBVEYN50lPbkt1QltEVnXQQ==",
"peer": true,
"requires": {
"@parcel/codeframe": "2.8.2",
"@parcel/diagnostic": "2.8.2",
"@parcel/hash": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/markdown-ansi": "2.8.2",
"@parcel/source-map": "^2.1.1",
"chalk": "^4.1.0"
}
},
"@parcel/workers": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/workers/-/workers-2.8.2.tgz",
"integrity": "sha512-Eg6CofIrJSNBa2fjXwvnzVLPKwR/6fkfQTFAm3Jl+4JYLVknBtTSFzQNp/Fa+HUEG889H9ucTk2CBi/fVPBAFw==",
"peer": true,
"requires": {
"@parcel/diagnostic": "2.8.2",
"@parcel/logger": "2.8.2",
"@parcel/types": "2.8.2",
"@parcel/utils": "2.8.2",
"chrome-trace-event": "^1.0.2",
"nullthrows": "^1.1.1"
}
}
}
},
"@parcel/diagnostic": { "@parcel/diagnostic": {
"version": "2.8.0", "version": "2.8.0",
"resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.0.tgz", "resolved": "https://registry.npmjs.org/@parcel/diagnostic/-/diagnostic-2.8.0.tgz",
@ -4309,6 +4895,15 @@
"detect-libc": "^1.0.3" "detect-libc": "^1.0.3"
} }
}, },
"@parcel/graph": {
"version": "2.8.2",
"resolved": "https://registry.npmjs.org/@parcel/graph/-/graph-2.8.2.tgz",
"integrity": "sha512-SLEvBQBgfkXgU4EBu30+CNanpuKjcNuEv/x8SwobCF0i3Rk+QKbe7T36bNR7727mao++2Ha69q93Dd9dTPw0kQ==",
"peer": true,
"requires": {
"nullthrows": "^1.1.1"
}
},
"@parcel/hash": { "@parcel/hash": {
"version": "2.8.0", "version": "2.8.0",
"resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.0.tgz", "resolved": "https://registry.npmjs.org/@parcel/hash/-/hash-2.8.0.tgz",
@ -4884,11 +5479,15 @@
"integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==",
"dev": true "dev": true
}, },
"@types/prettier": {
"version": "2.7.2",
"resolved": "https://registry.npmjs.org/@types/prettier/-/prettier-2.7.2.tgz",
"integrity": "sha512-KufADq8uQqo1pYKVIYzfKbJfBAc0sOeXqGbFaSpv8MRmC/zXgowNZmFcbngndGk922QDmOASEXUZCaY48gs4cg=="
},
"abortcontroller-polyfill": { "abortcontroller-polyfill": {
"version": "1.7.3", "version": "1.7.3",
"resolved": "https://registry.npmjs.org/abortcontroller-polyfill/-/abortcontroller-polyfill-1.7.3.tgz", "resolved": "https://registry.npmjs.org/abortcontroller-polyfill/-/abortcontroller-polyfill-1.7.3.tgz",
"integrity": "sha512-zetDJxd89y3X99Kvo4qFx8GKlt6GsvN3UcRZHwU6iFA/0KiOmhkTVhe8oRoTBiTVPZu09x3vCra47+w8Yz1+2Q==", "integrity": "sha512-zetDJxd89y3X99Kvo4qFx8GKlt6GsvN3UcRZHwU6iFA/0KiOmhkTVhe8oRoTBiTVPZu09x3vCra47+w8Yz1+2Q=="
"dev": true
}, },
"acorn": { "acorn": {
"version": "8.8.0", "version": "8.8.0",
@ -4950,7 +5549,6 @@
"version": "3.0.9", "version": "3.0.9",
"resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz", "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz",
"integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==", "integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==",
"dev": true,
"requires": { "requires": {
"safe-buffer": "^5.0.1" "safe-buffer": "^5.0.1"
} }
@ -5061,8 +5659,7 @@
"clone": { "clone": {
"version": "2.1.2", "version": "2.1.2",
"resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz",
"integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w=="
"dev": true
}, },
"color-convert": { "color-convert": {
"version": "2.0.1", "version": "2.0.1",
@ -5197,14 +5794,12 @@
"dotenv": { "dotenv": {
"version": "7.0.0", "version": "7.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-7.0.0.tgz", "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-7.0.0.tgz",
"integrity": "sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g==", "integrity": "sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g=="
"dev": true
}, },
"dotenv-expand": { "dotenv-expand": {
"version": "5.1.0", "version": "5.1.0",
"resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-5.1.0.tgz", "resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-5.1.0.tgz",
"integrity": "sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA==", "integrity": "sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA=="
"dev": true
}, },
"electron-to-chromium": { "electron-to-chromium": {
"version": "1.4.251", "version": "1.4.251",
@ -5538,6 +6133,11 @@
"resolved": "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz", "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz",
"integrity": "sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA==" "integrity": "sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA=="
}, },
"jsonc-parser": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.0.tgz",
"integrity": "sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w=="
},
"jsonfile": { "jsonfile": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz",
@ -5672,6 +6272,11 @@
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="
}, },
"lunr": {
"version": "2.3.9",
"resolved": "https://registry.npmjs.org/lunr/-/lunr-2.3.9.tgz",
"integrity": "sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow=="
},
"make-dir": { "make-dir": {
"version": "3.1.0", "version": "3.1.0",
"resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz",
@ -5712,13 +6317,13 @@
"version": "8.6.6", "version": "8.6.6",
"resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz", "resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz",
"integrity": "sha512-jRW30YGywD2ESXDc+l17AiritL0uVaSnWsb26f+68qaW9zgbIIr1f4v2Nsvc0+s0Z2N3uX6t/yAw7BwCQ1wMsA==", "integrity": "sha512-jRW30YGywD2ESXDc+l17AiritL0uVaSnWsb26f+68qaW9zgbIIr1f4v2Nsvc0+s0Z2N3uX6t/yAw7BwCQ1wMsA==",
"dev": true "dev": true,
"requires": {}
}, },
"marked": { "marked": {
"version": "4.2.5", "version": "4.2.5",
"resolved": "https://registry.npmjs.org/marked/-/marked-4.2.5.tgz", "resolved": "https://registry.npmjs.org/marked/-/marked-4.2.5.tgz",
"integrity": "sha512-jPueVhumq7idETHkb203WDD4fMA3yV9emQ5vLwop58lu8bTclMghBWcYAavlDqIEMaisADinV1TooIFCfqOsYQ==", "integrity": "sha512-jPueVhumq7idETHkb203WDD4fMA3yV9emQ5vLwop58lu8bTclMghBWcYAavlDqIEMaisADinV1TooIFCfqOsYQ=="
"dev": true
}, },
"mdn-data": { "mdn-data": {
"version": "2.0.14", "version": "2.0.14",
@ -6040,8 +6645,7 @@
"safe-buffer": { "safe-buffer": {
"version": "5.2.1", "version": "5.2.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
"integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="
"dev": true
}, },
"sass": { "sass": {
"version": "1.54.9", "version": "1.54.9",
@ -6059,6 +6663,16 @@
"resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
"integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ=="
}, },
"shiki": {
"version": "0.12.1",
"resolved": "https://registry.npmjs.org/shiki/-/shiki-0.12.1.tgz",
"integrity": "sha512-aieaV1m349rZINEBkjxh2QbBvFFQOlgqYTNtCal82hHj4dDZ76oMlQIX+C7ryerBTDiga3e5NfH6smjdJ02BbQ==",
"requires": {
"jsonc-parser": "^3.2.0",
"vscode-oniguruma": "^1.7.0",
"vscode-textmate": "^8.0.0"
}
},
"source-map": { "source-map": {
"version": "0.6.1", "version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
@ -6185,6 +6799,40 @@
"integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==",
"dev": true "dev": true
}, },
"typedoc": {
"version": "0.23.24",
"resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.23.24.tgz",
"integrity": "sha512-bfmy8lNQh+WrPYcJbtjQ6JEEsVl/ce1ZIXyXhyW+a1vFrjO39t6J8sL/d6FfAGrJTc7McCXgk9AanYBSNvLdIA==",
"requires": {
"lunr": "^2.3.9",
"marked": "^4.2.5",
"minimatch": "^5.1.2",
"shiki": "^0.12.1"
},
"dependencies": {
"brace-expansion": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz",
"integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==",
"requires": {
"balanced-match": "^1.0.0"
}
},
"minimatch": {
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.2.tgz",
"integrity": "sha512-bNH9mmM9qsJ2X4r2Nat1B//1dJVcn3+iBLa3IgqJ7EbGaDNepL9QSHOxN4ng33s52VMMhhIfgCYDk3C4ZmlDAg==",
"requires": {
"brace-expansion": "^2.0.1"
}
}
}
},
"typescript": {
"version": "4.9.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.4.tgz",
"integrity": "sha512-Uz+dTXYzxXXbsFpM86Wh3dKCxrQqUcVMxwU54orwlJjOpO3ao8L7j5lH+dWfTwgCwIuM9GQ2kvVotzYJMXTBZg=="
},
"uc.micro": { "uc.micro": {
"version": "1.0.6", "version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz", "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
@ -6222,6 +6870,16 @@
"integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==", "integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==",
"dev": true "dev": true
}, },
"vscode-oniguruma": {
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/vscode-oniguruma/-/vscode-oniguruma-1.7.0.tgz",
"integrity": "sha512-L9WMGRfrjOhgHSdOYgCt/yRMsXzLDJSL7BPrOZt73gU0iWO4mpqzqQzOz5srxqTvMBaR0XZTSrVWo4j55Rc6cA=="
},
"vscode-textmate": {
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/vscode-textmate/-/vscode-textmate-8.0.0.tgz",
"integrity": "sha512-AFbieoL7a5LMqcnOF04ji+rpXadgOXnZsxQr//r83kLPr7biP7am3g9zbaZIaBGwBRWeSvoMD4mgPdX3e4NWBg=="
},
"weak-lru-cache": { "weak-lru-cache": {
"version": "1.2.2", "version": "1.2.2",
"resolved": "https://registry.npmjs.org/weak-lru-cache/-/weak-lru-cache-1.2.2.tgz", "resolved": "https://registry.npmjs.org/weak-lru-cache/-/weak-lru-cache-1.2.2.tgz",

View File

@ -1,6 +1,6 @@
{ {
"name": "cg-select", "name": "cg-select",
"version": "0.1.171", "version": "0.2.1",
"description": "Feature rich Select control for React/JS with multiselect, autocomplete and styling", "description": "Feature rich Select control for React/JS with multiselect, autocomplete and styling",
"author": { "author": {
"name": "CraftGroup", "name": "CraftGroup",
@ -9,7 +9,7 @@
"homepage": "https://cg-select.itguild.info", "homepage": "https://cg-select.itguild.info",
"scripts": { "scripts": {
"start": "parcel example/index.html -p 4500 --open ", "start": "parcel example/index.html -p 4500 --open ",
"build": "parcel build index.js", "build": "parcel build example/index.js --no-cache",
"deploy": "gh-pages -d dist", "deploy": "gh-pages -d dist",
"predeploy": "npm run build" "predeploy": "npm run build"
}, },
@ -29,7 +29,10 @@
}, },
"dependencies": { "dependencies": {
"@parcel/optimizer-css": "^2.8.0", "@parcel/optimizer-css": "^2.8.0",
"gh-pages": "^4.0.0" "@types/prettier": "^2.7.2",
"gh-pages": "^4.0.0",
"typedoc": "^0.23.24",
"typescript": "^4.9.4"
}, },
"keywords": [ "keywords": [
"select", "select",

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,27 @@
import { ICgSelect } from 'interfaces/cg-select.interface';
/**
* @description Настройки для создания чипсов.
*/
export interface ICreateBreadCrumb {
/**
* Определенный экземпляр класса.
* @type {Element | null}
*/
element: Element | null;
/**
* Настройки селекта.
* @type {ICgSelect}
*/
option: ICgSelect;
/**
* Массив индексов выбранных элементов.
* @type {number[]}
*/
indexes: number[];
/**
* Массив с выбранными элементами.
* @type {string[]}
*/
selectedItems: string[];
}

View File

@ -1,22 +1,48 @@
import { customStylesFormat, nativeOptionMultiple } from './utils'; import { customStylesFormat, nativeOptionMultiple } from '../utils/utils';
import { ICreateBreadCrumb } from './create-element.interface';
/** /**
* @module createBreadcrumb * Метод который создает нативный селект
* @returns {HTMLSelectElement} Возвращает созданный нативный селект
*/ */
export function createNativeSelect(): HTMLSelectElement {
const nativeSelect = document.createElement('select');
nativeSelect.setAttribute('name', 'dataSelect');
nativeSelect.classList.add('nativeSelect');
return nativeSelect;
}
/**
* Метод который создает Options для нативного селекта
* @returns {HTMLOptionElement} Возвращает созданные Options нативного селекта
*/
export function createNativeSelectOption(): HTMLOptionElement {
const nativeOption = document.createElement('option');
nativeOption.classList.add('nativeSelect__nativeOption');
return nativeOption;
}
/** /**
* Метод который создает и отвечает за поведение chips * Метод который создает и отвечает за поведение chips
* @param {object} data объект в котором содержатся настройки и элементы селекта * @param {ICreateBreadCrumb} data объект в котором содержатся настройки и элементы селекта
* @param {string} title имя выбранного элемента для отрисовки chips * @param {string} title имя выбранного элемента для отрисовки chips
* @param {number} index индекс выбранного элемента для отрисовки chips * @param {number} index индекс выбранного элемента для отрисовки chips
* @param {string} id уникальное id выбранного элемента * @param {string} id уникальное id выбранного элемента
* @returns {HTMLElement} возвращает сформированный HTMLElement chips item * @returns {HTMLElement} возвращает сформированный HTMLElement chips item
*/ */
export function createBreadcrumb(data, title, index, id) { export function createBreadCrumb(
data: ICreateBreadCrumb,
title: string,
index: number,
id: string,
): HTMLLIElement {
const { element, option, indexes, selectedItems } = data; const { element, option, indexes, selectedItems } = data;
const { placeholder, styles } = option; const { placeholder, styles } = option;
const selected = element.querySelector('.selected'); const selected: HTMLElement | null | undefined = element?.querySelector('.selected');
const nativeOption = element.querySelectorAll('.nativeSelect__nativeOption'); const nativeOption = element!.querySelectorAll('.nativeSelect__nativeOption');
const liChip = document.createElement('li'); const liChip = document.createElement('li');
const textNode = document.createTextNode(title); const textNode = document.createTextNode(title);
@ -38,7 +64,7 @@ export function createBreadcrumb(data, title, index, id) {
if (styles) { if (styles) {
const { chips } = styles; const { chips } = styles;
customStylesFormat(chips, liChip); customStylesFormat(chips!, liChip);
} }
svgIcon.addEventListener('click', (event) => { svgIcon.addEventListener('click', (event) => {
@ -47,7 +73,7 @@ export function createBreadcrumb(data, title, index, id) {
nativeOptionMultiple(nativeOption, title, false); nativeOptionMultiple(nativeOption, title, false);
const deleteIcon = indexes.indexOf(index); const deleteIcon = indexes.indexOf(index);
let checkBox = ''; let checkBox: any;
indexes.splice(deleteIcon, 1); indexes.splice(deleteIcon, 1);
selectedItems.splice(deleteIcon, 1); selectedItems.splice(deleteIcon, 1);
@ -62,45 +88,22 @@ export function createBreadcrumb(data, title, index, id) {
checkBox.parentElement.classList.remove('active'); checkBox.parentElement.classList.remove('active');
if (!selectedItems.length) { if (!selectedItems.length) {
selected.innerText = placeholder; selected!.innerText = placeholder!;
} }
liChip.parentElement.removeChild(liChip); liChip.parentElement!.removeChild(liChip);
}); });
return liChip; return liChip;
} }
/**
* Метод который создает нативный селект
* @returns {HTMLSelectElement} Возвращает созданный нативный селект
*/
export function createNativeSelect() {
const nativeSelect = document.createElement('select');
nativeSelect.setAttribute('name', 'dataSelect');
nativeSelect.classList.add('nativeSelect');
return nativeSelect;
}
/**
* Метод который создает Options для нативного селекта
* @returns {HTMLOptionElement} Возвращает созданные Options нативного селекта
*/
export function createNativeSelectOption() {
const nativeOption = document.createElement('option');
nativeOption.classList.add('nativeSelect__nativeOption');
return nativeOption;
}
/** /**
* Метод который создает поиск элементов в селекте * Метод который создает поиск элементов в селекте
* @param {string} random уникальное значение для input элемента. * @param {string} random уникальное значение для input элемента.
* @param {string} lenguage текст на определенном языке переданный из файла language.js * @param {string} lenguage текст на определенном языке переданный из файла language.js
* @returns {HTMLInputElement} Возвращает сформированный input елемент. * @returns {HTMLInputElement} Возвращает сформированный input елемент.
*/ */
export function createInputSearch(random, lenguage) { export function createInputSearch(random: string, lenguage: string): HTMLInputElement {
const inputSearch = document.createElement('input'); const inputSearch = document.createElement('input');
inputSearch.type = 'text'; inputSearch.type = 'text';

View File

@ -0,0 +1,59 @@
import { IItems } from 'interfaces/items.interface';
/**
* @description Настройки получаемых элементов.
*/
export interface IDataItem {
/**
* Необязательный параметр. Категория группы элементов.
* @type {string}
*/
category?: string;
/**
* Необязательный параметр. Массив с элементами.
* @type {IItems[] | string[] | any}
*/
categoryItems?: IItems[] | string[];
/**
* Значение переданного элемента.
* @type {string | IItems | number}
*/
ItemValue: string | IItems | number;
}
/**
* @description Настройки для текста селекта и тд.
*/
export interface ISelectedItems {
/**
* Placeholder необязательный параметр, в который передается текст плейсхолдера селекта.
* @type {string}
*/
placeholder?: string;
/**
* Необязательный параметр, в который передается элемент который будет выбран изначально в селекте.
* @type {string}
*/
selected?: string;
/**
* Массив выбранных элементов из списка
* @type {string[]}
*/
selectedItems?: string[];
/**
* Массив индексов выбранных элементов
* @type {number[]}
*/
indexes?: number[];
/**
* Необязательный параметр, который отвечает за поведения селекта,
* для него, ***работает только в месте с подключением multiselect.
* @type {boolean}
*/
multiselectTag?: boolean;
/**
* Необязательный параметр, который отвечает за включение светлой/темной темы по умолчанию, стоит темная тема.
* @type {boolean}
*/
darkTheme?: boolean;
}

View File

@ -2,72 +2,54 @@
* Utils module * Utils module
* @module Utils * @module Utils
*/ */
import { IStyle } from 'interfaces/cg-select.interface';
import { IItems } from 'interfaces/items.interface';
import { ISelectedItems } from './urils.interface';
/** /**
* Создание кнопки выбора элементов * Преобразование каждого елемента полученного из поля Items;
* @param {HTMLElement} element созданный экземпляр класса DropDown * @param {any} dataItem полученный елемент переданный при создании селекта может быть как object / string
* @param {string} content placeholer передаваемый из настроек селекта * @param {number} index индекс этого элемента
* @param {object} styles не обязательный параметр. Объект в котором находяться настройки кастомизации частей селекта * @returns {IItems} возвращает сформированный объект
*/ */
export function createSelected(element, content, styles) { export function getFormatItem(dataItem: any, index: number): IItems {
if (content) { const random = Math.random().toString(36).substring(2, 10);
element.innerHTML = ` let item: IItems;
<div class="cg-select">
<p class="selected">${content}</p>
<div class="caret"></div>
</div>
`;
}
if (styles) { if (checkItemStruct(dataItem)) {
customStyles(element, styles); return dataItem;
} else {
item = {
id: random,
title: dataItem,
value: index,
};
element.innerHTML = ` return item;
<div class="cg-select" style = "${styles}">
<p class="selected" style = "${styles}">${content}</p>
<div class="caret" style = "${styles}"></div>
</div>
`;
} }
} }
/** /**
* Поиск и стилизация елементов полученных из styles экземпляра DropDown * Вставка изначального текста селекта(до выбора)
* @param {HTMLElement} element созданный экземпляр класса DropDown * @param {ITextSelect} data объект в котором находяться title селекта
* @param {object} styles объект в котором находяться настройки кастомизации частей селекта * @param {HTMLElement | null | undefined} select елемент селекта, куда будет вставляться title
* @returns {HTMLElement} возвращает сформированный елемент селекта
*/ */
export function customStyles(element, styles) { export function getSelectText(
if (!styles) { data: ISelectedItems,
return; select: HTMLElement | null | undefined,
): HTMLElement {
const { placeholder, selected } = data;
if (placeholder) {
select!.innerText = placeholder;
} else if (selected) {
select!.innerText = selected;
} else {
select!.innerText = 'Select...';
} }
const { head, caret, placeholder, lable } = styles; return select!;
const cgSelect = element.querySelector('.cg-select');
const caretSelect = element.querySelector('.caret');
const placeholderSelect = element.querySelector('.selected');
const lableItem = element.parentElement.querySelector('h1.label');
customStylesFormat(head, cgSelect);
customStylesFormat(caret, caretSelect);
customStylesFormat(lable, lableItem);
if (placeholderSelect) {
customStylesFormat(placeholder, placeholderSelect);
}
}
/**
* Универсальный метод для стилизации селекта
* @param {object} elemOption объект полученное из объекта styles у которого мы получаем ключ-значение стилей
* @param {HTMLElement} selector HTMLElement подвергающиеся кастомизации
*/
export function customStylesFormat(elemOption, selector) {
if (elemOption) {
Object.entries(elemOption).forEach(([key, value]) => {
selector.style[key] = value;
});
}
} }
/** /**
@ -75,7 +57,7 @@ export function customStylesFormat(elemOption, selector) {
* @param {object} item проверяемый на определенную структуру элемент * @param {object} item проверяемый на определенную структуру элемент
* @returns {boolean} возвращает true/false если item содержит указанные свойства * @returns {boolean} возвращает true/false если item содержит указанные свойства
*/ */
export function checkItemStruct(item) { export function checkItemStruct(item: object): boolean {
if (item && typeof item !== 'object') { if (item && typeof item !== 'object') {
return false; return false;
} }
@ -84,98 +66,47 @@ export function checkItemStruct(item) {
} }
/** /**
* Вставка изначального текста селекта(до выбора) * Создание кнопки выбора элементов
* @param {object} data объект в котором находяться title селекта * @param {HTMLElement} element созданный экземпляр класса DropDown
* @param {HTMLElement} select елемент селекта, куда будет вставляться title * @param {string} content placeholer передаваемый из настроек селекта
* @returns {HTMLElement} возвращает сформированный елемент селекта * @param {object} styles не обязательный параметр. Объект в котором находяться настройки кастомизации частей селекта
*/ */
export function getSelectText(data, select) { export function createSelected(element: Element, content?: string, styles?: IStyle) {
const { placeholder, selected } = data; const select = document.createElement('div');
const selected = document.createElement('p');
const caret = document.createElement('div');
if (placeholder) { select.classList.add('cg-select');
select.innerText = placeholder; selected.classList.add('selected');
} else if (selected) { caret.classList.add('caret');
select.innerText = selected;
} else {
select.innerText = 'Select...';
}
return select;
}
/** select.appendChild(selected);
* Преобразование каждого елемента полученного из поля Items; select.appendChild(caret);
* @param {object | string} dataItem полученный елемент переданный при создании селекта может быть как object/string
* @param {number} index индекс этого элемента
* @returns {object} возвращает сформированный объект
*/
export function getFormatItem(dataItem, index) {
const random = Math.random().toString(36).substring(2, 10);
let item = {};
if (checkItemStruct(dataItem)) { if (content) {
item = { const text = document.createTextNode(content);
id: dataItem.id, selected.appendChild(text);
title: dataItem.title, element.innerHTML = '';
value: index, element?.insertAdjacentElement('afterbegin', select);
}; } else if (styles) {
} else { customStyles(element!, styles);
item = { select.setAttribute('style', `${styles}`);
id: random, selected.setAttribute('style', `${styles}`);
title: dataItem, caret.setAttribute('style', `${styles}`);
value: index,
};
} }
return item;
}
/**
* Поведение нативного(одинарного) селекта при выборе кастомного
* @param {NodeList} element NodeList нативного селекта
* @param {object} item выбранный элемент в кастомном селекте
*/
export function nativeOptionOrdinary(element, item) {
element.forEach((option) => {
option.removeAttribute('selected');
if (option.textContent === item) {
option.setAttribute('selected', 'selected');
}
});
}
/**
* Поведение нативного(Multiple) селекта при выборе в кастомном
* @param {NodeList} element NodeList нативного селекта
* @param {object} item выбранный элемент в кастомном селекте
* @param {boolean} condition специальный флаг при котором добавляются/убераются атрибуты у нативного селекта
*/
export function nativeOptionMultiple(element, item, condition) {
element.forEach((option) => {
if (condition == true) {
if (option.textContent === item) {
option.setAttribute('selected', 'selected');
}
} else if (condition == false) {
if (option.textContent === item) {
option.removeAttribute('selected');
}
} else {
return;
}
});
} }
/** /**
* Создание кнопки отчиски селекта, при единичном выборе. * Создание кнопки отчиски селекта, при единичном выборе.
* @param {HTMLElement} select место в селекте которое будет переназначено на ''. * @param {HTMLElement} select место в селекте которое будет переназначено на ''.
* @param {HTMLElement} element экземпляр класса DropDown. * @param {Element} element экземпляр класса DropDown.
* @param {object} dataSelectText текст который отрисовывается в селекте. * @param {ISelectedItems} dataSelectText текст который отрисовывается в селекте.
*/ */
export function clearSelect(select, element, dataSelectText) { export function clearSelect(select: HTMLElement, element: Element, dataSelectText: ISelectedItems) {
const { selectedItems, indexes, darkTheme, multiselectTag } = dataSelectText; const { selectedItems, indexes, darkTheme, multiselectTag } = dataSelectText;
const options = element.querySelectorAll('.list__item'); const options = element.querySelectorAll('.list__item');
const ulMultiSelect = element.querySelector('.multiselect-tag'); const nativeOption = element!.querySelectorAll('.nativeSelect__nativeOption');
const svgIcon = document.createElementNS('http://www.w3.org/2000/svg', 'svg'); const svgIcon = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
const path1 = document.createElementNS('http://www.w3.org/2000/svg', 'path'); const path1 = document.createElementNS('http://www.w3.org/2000/svg', 'path');
const path2 = document.createElementNS('http://www.w3.org/2000/svg', 'path'); const path2 = document.createElementNS('http://www.w3.org/2000/svg', 'path');
@ -204,18 +135,24 @@ export function clearSelect(select, element, dataSelectText) {
svgIcon.classList.add('svg-icon'); svgIcon.classList.add('svg-icon');
svgIcon.classList.add('svg-clear'); svgIcon.classList.add('svg-clear');
select.appendChild(svgIcon); select!.appendChild(svgIcon);
svgIcon.addEventListener('click', () => { svgIcon.addEventListener('click', () => {
select.innerText = ''; select!.innerText = '';
nativeOption.forEach((option) => {
option.removeAttribute('selected');
});
if (Array.isArray(selectedItems)) { if (Array.isArray(selectedItems)) {
selectedItems.splice(0); selectedItems!.splice(0);
indexes.splice(0); indexes!.splice(0);
} }
checkBox.forEach((item) => { checkBox.forEach((item) => {
if (item instanceof HTMLInputElement) {
item.checked = false; item.checked = false;
}
}); });
getSelectText(dataSelectText, select); getSelectText(dataSelectText, select);
@ -225,3 +162,76 @@ export function clearSelect(select, element, dataSelectText) {
}); });
}); });
} }
/**
* Поведение нативного(одинарного) селекта при выборе кастомного
* @param {NodeList} element NodeList нативного селекта
* @param {any} item выбранный элемент в кастомном селекте
*/
export function nativeOptionOrdinary(element: NodeListOf<Element> | undefined, item: string) {
element!.forEach((option) => {
option.removeAttribute('selected');
if (option.textContent === item) {
option.setAttribute('selected', 'selected');
}
});
}
/**
* Поведение нативного(Multiple) селекта при выборе в кастомном
* @param {NodeListOf<Element> | undefined} element NodeList нативного селекта
* @param {string} item выбранный элемент в кастомном селекте
* @param {boolean} condition специальный флаг при котором добавляются/убераются атрибуты у нативного селекта
*/
export function nativeOptionMultiple(
element: NodeListOf<Element> | undefined,
item: string,
condition: boolean,
) {
element!.forEach((option) => {
if (condition == true) {
if (option.textContent === item) {
option.setAttribute('selected', 'selected');
}
} else if (condition == false) {
if (option.textContent === item) {
option.removeAttribute('selected');
}
} else {
return;
}
});
}
/**
* Поиск и стилизация елементов полученных из styles экземпляра DropDown
* @param {Element} element созданный экземпляр класса DropDown
* @param {object} styles объект в котором находяться настройки кастомизации частей селекта
*/
export function customStyles(element: Element, styles: IStyle) {
const cgSelect = element.querySelector('.cg-select');
const caretSelect = element.querySelector('.caret');
const placeholderSelect = element.querySelector('.selected');
const lableItem = element.parentElement!.querySelector('h1.label');
customStylesFormat(styles.head!, cgSelect!);
customStylesFormat(styles.caret!, caretSelect!);
customStylesFormat(styles.lable!, lableItem!);
if (placeholderSelect) {
customStylesFormat(styles.placeholder!, placeholderSelect);
}
}
/**
* Универсальный метод для стилизации селекта
* @param {object} elemOption объект полученное из объекта styles у которого мы получаем ключ-значение стилей
* @param {HTMLElement} selector HTMLElement подвергающиеся кастомизации
*/
export function customStylesFormat(elemOption: object, selector: any) {
if (elemOption) {
Object.entries(elemOption).forEach(([key, value]) => {
selector.style[key] = value;
});
}
}

View File

@ -0,0 +1,136 @@
import { IItems } from './items.interface';
/**
* @description Настройки селекта.
*/
export interface ICgSelect {
/**
* Уникальный селектор - *обязательный параметр(индефикатор), который задаеться при создании селекта.
* @type {string}
*/
selector?: string;
/**
* Необязательный параметр, в который передается элемент который будет выбран изначально в селекте.
* @type {string}
*/
selected?: string;
/**
* Placeholder необязательный параметр, в который передается текст плейсхолдера селекта.
* @type {string}
*/
placeholder?: string;
/**
* *Обязательный параметр(эсли не указан другой способ получения данных (url)), это массив элементов,
* которые будут отображаться в селекте при выборе.
* @type {IItems[] | string[] | any}
*/
items?: IItems[] | string[] | any;
/**
* Необязательный параметр, который отвечает за включение светлой/темной темы по умолчанию, стоит темная тема(darkTheme == true)
* @type {boolean}
*/
darkTheme?: boolean;
/**
* Необязательный параметр, который добавляет живой поиск по элеметам селекта.
* @type {boolean}
*/
searchMode?: boolean;
/**
* Необязательный параметр, который отвечает за поведения селекта при открытии, если closeOnSelect: false,
* тогда при выборе елемента в селекте закрытия не происходит,
* и можно выбрать другой элемент по умолчанию, closeOnSelect:true.
* @type {boolean}
*/
closeOnSelect?: boolean;
/**
* Необязательный параметр, который отвечает за поведения селекта при открытии на мобильных усторйствах.
* @type {boolean}
*/
nativeSelectMode?: boolean;
/**
* Необязательный параметр, который отвечает за поведения селекта при открытии.
* @type {boolean}
*/
listDisplayMode?: boolean;
/**
* Необязательный параметр, отвечающий за локализацию некоторых текстовых элементов.
* @type {string}
*/
language?: string;
/**
* Необязательный параметр,который добавляет lable перед селектом.
* @type {string}
*/
lable?: string;
/**
* Необязательный параметр, который отвечает за кастомизацию элементов селекта,
* в него передаются обьекты с CSS свойствами для кастомизируемых элементов.
* @type {IStyle}
*/
styles?: IStyle;
/**
* Необязательный параметр, который отвечает за поведения селекта, передавая в этот параметр, евент по типу 'mouseenter',
* селект будет открываться при наведении.
* @type {string}
*/
event?: string;
/**
* Обязательный параметр(эсли не указан другой способ получения данных (items)),
* данные которые приходят с бекэнда в формате {id:"", title: "", value: ""}.
* @type {string}
*/
url?: string;
/**
* Необязательный параметр, который отвечает за поведения селекта, добавляет возможность выбирать несколько элементов.
* Выбранные элементы отрисовываются как обычный текст, через запятую.
* @type {boolean}
*/
multiselect?: boolean;
/**
* Необязательный параметр, который отвечает за поведения селекта,
* для него, ***работает только в месте с подключением multiselect.
* @type {boolean}
*/
multiselectTag?: boolean;
}
/**
* @description Настройки стилей.
*/
export interface IStyle {
/**
* Кастомизация кнопки селекта.
* @type {object}
*/
head?: object;
/**
* Кастомизация каретки.
* @type {object}
*/
caret?: object;
/**
* Кастомизация placeholder.
* @type {object}
*/
placeholder?: object;
/**
* Кастомизация lable селекта.
* @type {object}
*/
lable?: object;
/**
* Кастомизация листа с выбором элементов.
* @type {object}
*/
list?: object;
/**
* Кастомизация поиска.
* @type {object}
*/
search?: object;
/**
* Кастомизация чипсов с выбранными элементами
* @type {object}
*/
chips?: object;
}

View File

@ -0,0 +1,20 @@
/**
* @description Строение элемента.
*/
export interface IItems {
/**
* Уникальное ID элемента
* @type {string}
*/
id: string;
/**
* Текстовое значение элемента
* @type {string}
*/
title: string;
/**
* Порядковый номер, или другая информация
* @type {number | string}
*/
value: number | string;
}

View File

@ -0,0 +1,20 @@
/**
* @description Настройки для добавления языков.
*/
export interface ILanguage {
/**
* Текст в поиске.
* @type {string}
*/
placeholder: string;
/**
* Дефолтный Текст Селекта если не указан placeholder или выбранный элемент
* @type {string}
*/
selectPlaceholder: string;
/**
* Текст если совпадений нет.
* @type {string}
*/
textInListSearch: string;
}

View File

@ -1,10 +1,12 @@
export const ru = { import { ILanguage } from 'interfaces/language.interface';
export const ru: ILanguage = {
selectPlaceholder: 'Выберите элемент...', selectPlaceholder: 'Выберите элемент...',
placeholder: 'Поиск...', placeholder: 'Поиск...',
textInListSearch: 'Совпадений нет...', textInListSearch: 'Совпадений нет...',
}; };
export const en = { export const en: ILanguage = {
selectPlaceholder: 'Select element...', selectPlaceholder: 'Select element...',
placeholder: 'Search...', placeholder: 'Search...',
textInListSearch: 'No matches...', textInListSearch: 'No matches...',

83
tsconfig.json Normal file
View File

@ -0,0 +1,83 @@
{
// "include": ["src/**/*", "index.ts"],
"compilerOptions": {
/* Projects */
// "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */
// "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */
// "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */
// "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */
// "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
// "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
/* Language and Environment */
"target": "es2017" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
// "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
// "jsx": "preserve", /* Specify what JSX code is generated. */
// "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */
// "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */
// "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */
// "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */
// "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */
// "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */
// "noLib": true, /* Disable including any library files, including the default lib.d.ts. */
// "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
// "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */
/* Modules */
"module": "commonjs" /* Specify what module code is generated. */,
"rootDir": "./" /* Specify the root folder within your source files. */,
// "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
"baseUrl": "./src" /* Specify the base directory to resolve non-relative module names. */,
// "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
// "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
// "typeRoots": [], /* Specify multiple folders that act like './node_modules/@types'. */
// "types": [], /* Specify type package names to be included without being referenced in a source file. */
// "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
// "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */
// "resolveJsonModule": true, /* Enable importing .json files. */
// "noResolve": true, /* Disallow 'import's, 'require's or '<reference>'s from expanding the number of files TypeScript should add to a project. */
/* JavaScript Support */
// "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */
// "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */
// "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */
/* Emit */
// "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */
// "declarationMap": true, /* Create sourcemaps for d.ts files. */
// "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */
// "sourceMap": true, /* Create source map files for emitted JavaScript files. */
// "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */
"outDir": "./dist" /* Specify an output folder for all emitted files. */,
// "removeComments": true, /* Disable emitting comments. */
// "noEmit": true, /* Disable emitting files from a compilation. */
// "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */
// "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types. */
// "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */
// "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
// "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */
// "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */
// "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */
// "newLine": "crlf", /* Set the newline character for emitting files. */
// "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */
// "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */
// "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */
// "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */
// "declarationDir": "./", /* Specify the output directory for generated declaration files. */
// "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */
/* Interop Constraints */
// "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */
"allowSyntheticDefaultImports": true /* Allow 'import x from y' when a module doesn't have a default export. */,
"esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */,
// "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */
"forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */,
"strict": true,
/* Completeness */
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
"skipLibCheck": true /* Skip type checking all .d.ts files. */
}
}