diff --git a/CHANGELOG.md b/CHANGELOG.md index 69f4be1a..501767e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,12 +10,20 @@ - The link modal UI now reflects Craft’s native Link fields. ([#375](https://github.com/craftcms/ckeditor/pull/375)) - It’s now possible to choose which entry types should get a dedicated toolbar button versus be listed within the “Add nested content” menu. ([#423](https://github.com/craftcms/ckeditor/pull/423)) - Added support for drag-n-drop image uploading. ([#486](https://github.com/craftcms/ckeditor/pull/486)) +- Added support for inserting new images as nested entries. ([#509](https://github.com/craftcms/ckeditor/pull/509)) - Added the “Advanced Link Fields” setting to CKEditor configs. ([#375](https://github.com/craftcms/ckeditor/pull/375)) - Custom editor styles now get registered with a higher specificity than the default editor styles. ([#433](https://github.com/craftcms/ckeditor/pull/433)) - Added `craft\ckeditor\helpers\CkeditorConfig`. ([#363](https://github.com/craftcms/ckeditor/pull/363)) - Added `craft\ckeditor\web\assets\BaseCkeditorPackageAsset::$namespace`. ([#363](https://github.com/craftcms/ckeditor/pull/363)) - Added `craft\ckeditor\CkeConfig::$advancedLinkFields`. - Added `craft\ckeditor\CkeConfig::advanceLinkOptions()`. +- Added `craft\ckeditor\Field::$imageEntryTypeUid`. +- Added `craft\ckeditor\Field::$imageFieldUid`. +- Added `craft\ckeditor\Field::$imageMode`. +- Added `craft\ckeditor\Field::IMAGE_MODE_ENTRIES`. +- Added `craft\ckeditor\Field::IMAGE_MODE_IMG`. +- Added `craft\ckeditor\Field::getImageEntryType()`. +- Added `craft\ckeditor\Field::getImageField()`. - Updated to CKEditor 5 47.5.0. ([#502](https://github.com/craftcms/ckeditor/pull/502)) - Fixed a JavaScript error that could occur when editing an element in a slideout. ([#429](https://github.com/craftcms/ckeditor/pull/429)) diff --git a/package-lock.json b/package-lock.json index c41e6f9f..c7dd5f0e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,8 @@ "lint-staged": "^15.2.10", "npm-run-all": "^4.1.5", "prettier": "^3.4.2", - "vite": "^6.0.7" + "vite": "^6.0.7", + "vite-plugin-static-copy": "^3.2.0" }, "peerDependencies": { "glob": ">= 11.0", @@ -1937,6 +1938,19 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, "node_modules/array-buffer-byte-length": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.2.tgz", @@ -2017,6 +2031,18 @@ "node": "20 || >=22" } }, + "node_modules/binary-extensions": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", + "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/blurhash": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/blurhash/-/blurhash-2.0.5.tgz", @@ -2150,6 +2176,30 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/chokidar": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", + "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", + "dev": true, + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, "node_modules/ckeditor5": { "version": "47.5.0", "resolved": "https://registry.npmjs.org/ckeditor5/-/ckeditor5-47.5.0.tgz", @@ -2928,6 +2978,18 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, "node_modules/globalthis": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", @@ -3402,6 +3464,18 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/is-boolean-object": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.2.2.tgz", @@ -3478,6 +3552,15 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/is-finalizationregistry": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.1.1.tgz", @@ -3524,6 +3607,18 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/is-map": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.3.tgz", @@ -4863,6 +4958,15 @@ "validate-npm-package-license": "^3.0.1" } }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/npm-run-all": { "version": "4.1.5", "resolved": "https://registry.npmjs.org/npm-run-all/-/npm-run-all-4.1.5.tgz", @@ -5166,6 +5270,18 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/p-map": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-7.0.4.tgz", + "integrity": "sha512-tkAQEw8ysMzmkhgw8k+1U/iPhWNhykKnSk4Rd5zLoPJCuJaGRPo6YposrZgaxHKzDHdDWWZvE/Sk7hsL2X/CpQ==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/parse-json": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", @@ -5352,6 +5468,18 @@ "node": ">=4" } }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, "node_modules/reflect.getprototypeof": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", @@ -6597,6 +6725,28 @@ } } }, + "node_modules/vite-plugin-static-copy": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/vite-plugin-static-copy/-/vite-plugin-static-copy-3.2.0.tgz", + "integrity": "sha512-g2k9z8B/1Bx7D4wnFjPLx9dyYGrqWMLTpwTtPHhcU+ElNZP2O4+4OsyaficiDClus0dzVhdGvoGFYMJxoXZ12Q==", + "dev": true, + "dependencies": { + "chokidar": "^3.6.0", + "p-map": "^7.0.4", + "picocolors": "^1.1.1", + "tinyglobby": "^0.2.15" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/sapphi-red" + }, + "peerDependencies": { + "vite": "^5.0.0 || ^6.0.0 || ^7.0.0" + } + }, "node_modules/vite/node_modules/fdir": { "version": "6.5.0", "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz", diff --git a/package.json b/package.json index 778337a7..8a7d9e80 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,8 @@ "lint-staged": "^15.2.10", "npm-run-all": "^4.1.5", "prettier": "^3.4.2", - "vite": "^6.0.7" + "vite": "^6.0.7", + "vite-plugin-static-copy": "^3.2.0" }, "peerDependencies": { "glob": ">= 11.0", diff --git a/src/Field.php b/src/Field.php index c2f25326..4015d630 100644 --- a/src/Field.php +++ b/src/Field.php @@ -43,6 +43,8 @@ use craft\errors\InvalidHtmlTagException; use craft\events\CancelableEvent; use craft\events\DuplicateNestedElementsEvent; +use craft\fieldlayoutelements\CustomField; +use craft\fields\Assets; use craft\helpers\ArrayHelper; use craft\helpers\Assets as AssetsHelper; use craft\helpers\Cp; @@ -67,6 +69,7 @@ use HTMLPurifier_Config; use HTMLPurifier_Exception; use HTMLPurifier_HTMLDefinition; +use Illuminate\Support\Arr; use Illuminate\Support\Collection; use Throwable; use yii\base\InvalidArgumentException; @@ -118,6 +121,11 @@ class Field extends HtmlField implements ElementContainerFieldInterface, Mergeab */ public const EVENT_MODIFY_CONFIG = 'modifyConfig'; + /** @since 5.0.0 */ + public const IMAGE_MODE_IMG = 'img'; + /** @since 5.0.0 */ + public const IMAGE_MODE_ENTRIES = 'entries'; + /** * @var NestedElementManager[] */ @@ -484,6 +492,12 @@ public static function entryType(EntryType|CkeEntryType|string|array $entryType) */ public bool $parseEmbeds = false; + /** + * @var string How new images should be added to the field contents + * @since 5.0.0 + */ + public string $imageMode = self::IMAGE_MODE_IMG; + /** * @var string|array|null The volumes that should be available for image selection. * @since 1.2.0 @@ -513,6 +527,20 @@ public static function entryType(EntryType|CkeEntryType|string|array $entryType) */ public ?string $defaultTransform = null; + /** + * @var string|null The entry type UUID used to store images. + * @see getImageEntryType() + * @since 5.0.0 + */ + public ?string $imageEntryTypeUid = null; + + /** + * @var string|null The Assets field’s layout element UUID used to store images. + * @see getImageField() + * @since 5.0.0 + */ + public ?string $imageFieldUid = null; + /** * @var string|string[]|null User groups whose members should be able to see the “Source” button * @since 4.5.0 @@ -597,6 +625,11 @@ public function __construct($config = []) $config['entryTypes'] = []; } + if (isset($config['imageFieldPath'])) { + [$config['imageEntryTypeUid'], $config['imageFieldUid']] = explode('.', $config['imageFieldPath'], 2); + unset($config['imageFieldPath']); + } + if (isset($config['enableSourceEditingForNonAdmins'])) { $config['sourceEditingGroups'] = $config['enableSourceEditingForNonAdmins'] ? '*' : ['__ADMINS__']; unset($config['enableSourceEditingForNonAdmins']); @@ -695,6 +728,40 @@ public function setEntryTypes(array $entryTypes): void $this->_entryTypes = array_map(fn($config) => static::entryType($config), $entryTypes); } + /** + * Returns the entry type used to store images. + * + * @since 5.0.0 + */ + public function getImageEntryType(): ?CkeEntryType + { + if (!$this->imageEntryTypeUid) { + return null; + } + + return Arr::first( + $this->getEntryTypes(), + fn(CkeEntryType $entryType) => $entryType->uid === $this->imageEntryTypeUid, + ); + } + + /** + * Returns the Assets field used to store images. + * + * @since 5.0.0 + */ + public function getImageField(): ?Assets + { + if (!$this->imageFieldUid) { + return null; + } + + /** @var CustomField|null $layoutElement */ + $layoutElement = $this->getImageEntryType()?->getFieldLayout()->getElementByUid($this->imageFieldUid); + $field = $layoutElement?->getField(); + return $field instanceof Assets ? $field : null; + } + /** * @inheritdoc */ @@ -873,7 +940,7 @@ public function getReadOnlySettingsHtml(): ?string private function settingsHtml(bool $readOnly): string { $view = Craft::$app->getView(); - $view->registerAssetBundle(FieldSettingsAsset::class); + $bundle = $view->registerAssetBundle(FieldSettingsAsset::class); $userGroupOptions = [ [ @@ -924,6 +991,7 @@ private function settingsHtml(bool $readOnly): string 'entryTypes' => $this->getEntryTypes(), 'userGroupOptions' => $userGroupOptions, 'purifierConfigOptions' => $this->configOptions('htmlpurifier'), + 'baseIconsUrl' => "$bundle->baseUrl/images", 'volumeOptions' => $volumeOptions, 'transformOptions' => $transformOptions, 'defaultTransformOptions' => array_merge([ @@ -1253,7 +1321,11 @@ private function _inputHtml(mixed $value, ?ElementInterface $element, bool $stat 'imageEditor', ], ], - 'assetSources' => $this->_assetSources(), + 'imageMode' => $this->imageMode, + 'imageSources' => $this->_imageSources(), + 'imageModalSettings' => $this->_imageModalSettings(), + 'imageEntryTypeId' => $this->getImageEntryType()?->id, + 'imageFieldHandle' => $this->getImageField()?->handle, 'assetSelectionCriteria' => $this->_assetSelectionCriteria(), 'defaultUploadFolderId' => $this->_defaultUploadFolderId(), 'linkOptions' => $this->_linkOptions($element), @@ -1347,7 +1419,7 @@ private function _inputHtml(mixed $value, ?ElementInterface $element, bool $stat $uiLanguage = BaseCkeditorPackageAsset::uiLanguage(); $uiTranslationImport = "import coreTranslations from 'ckeditor5/translations/$uiLanguage.js';"; - $view->registerScriptWithVars(fn($baseConfigJs, $toolbarJs, $languageJs, $showWordCountJs, $wordLimitJs, $characterLimitJs) => <<registerScriptWithVars(fn($baseConfigJs, $toolbarJs, $languageJs, $showWordCountJs, $wordLimitJs, $characterLimitJs, $imageMode) => <<showWordCount, $this->wordLimit ?: 0, $this->characterLimit ?: 0, + $this->imageMode, ], View::POS_END, ['type' => 'module'] @@ -1916,6 +1989,31 @@ private function _categorySources(?ElementInterface $element): array return $sources; } + private function _imageSources(): array + { + return $this->imageMode === self::IMAGE_MODE_IMG + ? $this->_assetSources() + : $this->getImageField()?->getInputSources() ?? []; + } + + private function _imageModalSettings(): array + { + $settings = []; + + if ($this->imageMode === self::IMAGE_MODE_ENTRIES) { + $field = $this->getImageField(); + if ($field) { + $settings += [ + 'indexSettings' => [ + 'showFolders' => !$field->restrictLocation || $field->allowSubfolders, + ], + ]; + } + } + + return $settings; + } + /** * Returns the available asset sources. * @@ -1980,17 +2078,31 @@ private function _assetSelectionCriteria(): array */ private function _defaultUploadFolderId(): ?int { - if (!$this->defaultUploadLocationVolume) { - return null; + if ($this->imageMode === self::IMAGE_MODE_ENTRIES) { + $imageField = $this->getImageField(); + if ( + !$imageField?->defaultUploadLocationSource || + !preg_match('/^volume:(.+)$/', $imageField->defaultUploadLocationSource, $matches) + ) { + return null; + } + + $volume = Craft::$app->getVolumes()->getVolumeByUid($matches[1]); + $subpath = $imageField->defaultUploadLocationSubpath; + } else { + if (!$this->defaultUploadLocationVolume) { + return null; + } + + $volume = Craft::$app->getVolumes()->getVolumeByUid($this->defaultUploadLocationVolume); + $subpath = $this->defaultUploadLocationSubpath; } - $volume = Craft::$app->getVolumes()->getVolumeByUid($this->defaultUploadLocationVolume); if (!$volume) { return null; } - $subpath = trim($this->defaultUploadLocationSubpath ?? '', '/'); - [$subpath, $folder] = AssetsHelper::resolveSubpath($volume, $subpath); + [$subpath, $folder] = AssetsHelper::resolveSubpath($volume, trim($subpath ?? '', '/')); // Ensure that the folder exists if (!$folder) { @@ -2026,7 +2138,7 @@ private function _getCustomSources(string $elementType): array */ private function _transforms(): array { - if (!$this->availableTransforms) { + if ($this->imageMode !== self::IMAGE_MODE_IMG || !$this->availableTransforms) { return []; } @@ -2115,7 +2227,7 @@ private function _adjustPurifierConfig(HTMLPurifier_Config $purifierConfig): HTM $def?->addAttribute('ul', 'style', 'Text'); } - if (in_array('createEntry', $this->toolbar)) { + if ($this->imageMode === self::IMAGE_MODE_ENTRIES || in_array('createEntry', $this->toolbar)) { $def?->addElement('craft-entry', 'Inline', 'Inline', '', [ 'data-entry-id' => 'Number', 'data-site-id' => 'Number', diff --git a/src/controllers/CkeditorController.php b/src/controllers/CkeditorController.php index 202a1d85..3e996908 100644 --- a/src/controllers/CkeditorController.php +++ b/src/controllers/CkeditorController.php @@ -8,9 +8,11 @@ namespace craft\ckeditor\controllers; use Craft; +use craft\base\Element; use craft\base\ElementInterface; use craft\ckeditor\Field; use craft\elements\Asset; +use craft\elements\Entry; use craft\fieldlayoutelements\CustomField; use craft\helpers\ElementHelper; use craft\web\Controller; @@ -18,6 +20,7 @@ use yii\base\Exception; use yii\base\InvalidConfigException; use yii\web\BadRequestHttpException; +use yii\web\ForbiddenHttpException; use yii\web\NotFoundHttpException; use yii\web\Response; use yii\web\ServerErrorHttpException; @@ -249,4 +252,59 @@ public function actionRenderElementWithSupportedSites(): Response 'siteIds' => $siteIds, ]); } + + public function actionCreateImageEntry(): Response + { + $fieldId = $this->request->getRequiredBodyParam('fieldId'); + $ownerId = $this->request->getRequiredBodyParam('ownerId'); + $siteId = $this->request->getRequiredBodyParam('siteId'); + $assetIds = $this->request->getRequiredBodyParam('assetIds'); + + $owner = Craft::$app->getElements()->getElementById($ownerId, siteId: $siteId); + if (!$owner) { + throw new BadRequestHttpException("Invalid owner ID: $ownerId"); + } + + $elementsService = Craft::$app->getElements(); + if (!$elementsService->canSave($owner)) { + throw new ForbiddenHttpException('User not authorized to create this element.'); + } + + $field = Craft::$app->getFields()->getFieldById($fieldId); + if (!$field instanceof Field) { + throw new BadRequestHttpException("Invalid CKEditor field: $fieldId"); + } + + $imageEntryType = $field->getImageEntryType(); + $imageField = $field->getImageField(); + + if ( + $field->imageMode !== Field::IMAGE_MODE_ENTRIES || + !$imageEntryType || + !$imageField + ) { + throw new BadRequestHttpException("Invalid CKEditor field: $fieldId"); + } + + $entry = Craft::$app->getElements()->createElement([ + 'type' => Entry::class, + 'siteId' => $siteId, + 'fieldId' => $field->id, + 'ownerId' => $ownerId, + 'slug' => ElementHelper::tempSlug(), + ]); + $entry->setFieldValue($imageField->handle, $assetIds); + + $entry->setScenario(Element::SCENARIO_ESSENTIALS); + if (!$elementsService->saveElement($entry)) { + throw new ServerErrorHttpException( + sprintf('Could not save the nested entry: %s', implode(', ', $entry->getFirstErrors())) + ); + } + + return $this->asJson([ + 'entryId' => $entry->id, + 'siteId' => $siteId, + ]); + } } diff --git a/src/controllers/FieldSettingsController.php b/src/controllers/FieldSettingsController.php index 1cd4c982..4fe59c3a 100644 --- a/src/controllers/FieldSettingsController.php +++ b/src/controllers/FieldSettingsController.php @@ -23,6 +23,16 @@ */ class FieldSettingsController extends Controller { + public function beforeAction($action): bool + { + if (!parent::beforeAction($action)) { + return false; + } + + $this->requireAdmin(false); + return true; + } + /** * Applies an entry type indicators depending on config. * @@ -31,8 +41,6 @@ class FieldSettingsController extends Controller */ public function actionApplyEntryTypeIndicators(): Response { - $this->requireAdmin(false); - $config = Component::cleanseConfig($this->request->getRequiredBodyParam('config')); // get entry type by id @@ -53,4 +61,30 @@ public function actionApplyEntryTypeIndicators(): Response 'chip' => $chip, ]); } + + /** + * Renders the “Image Field” setting based on the updated entry type selections. + */ + public function actionRenderImageField(): Response + { + $namespace = $this->request->getRequiredBodyParam('namespace'); + $entryTypes = $this->request->getRequiredBodyParam('entryTypes'); + $currentValue = $this->request->getBodyParam('value'); + + $field = new Field(); + + if ($currentValue) { + [$field->imageEntryTypeUid, $field->imageFieldUid] = explode('.', $currentValue, 2); + } + + $field->setEntryTypes($entryTypes ?: []); + + $html = $this->getView()->namespaceInputs(fn() => $this->getView()->renderTemplate('ckeditor/_image-field-select.twig', [ + 'field' => $field, + ]), $namespace); + + return $this->asJson([ + 'html' => $html, + ]); + } } diff --git a/src/helpers/CkeditorConfig.php b/src/helpers/CkeditorConfig.php index d1b481ef..d439fac3 100644 --- a/src/helpers/CkeditorConfig.php +++ b/src/helpers/CkeditorConfig.php @@ -161,7 +161,6 @@ final class CkeditorConfig ['plugins' => ['TextPartLanguage'], 'buttons' => ['textPartLanguage']], ['plugins' => ['TodoList'], 'buttons' => ['todoList']], ['plugins' => ['Underline'], 'buttons' => ['underline']], - ['plugins' => ['CraftEntries'], 'buttons' => ['createEntry']], ]; public static array $toolbarItems = [ diff --git a/src/templates/_field-settings.twig b/src/templates/_field-settings.twig index c0e616c0..67db9856 100644 --- a/src/templates/_field-settings.twig +++ b/src/templates/_field-settings.twig @@ -147,64 +147,6 @@ disabled: readOnly, }) }} - {% embed '_includes/forms/field.twig' with { - id: 'default-upload-location', - label: 'Default Upload Location'|t('app'), - instructions: 'Where images should be stored when they are uploaded directly to the field via drag & drop.'|t('ckeditor'), - } %} - {% block input %} - {% import '_includes/forms.twig' as forms %} -
-
- {{ forms.select({ - id: "default-upload-location-volume", - name: "defaultUploadLocationVolume", - options: [ - { - label: 'None'|t('app'), - value: '', - }, - ...volumeOptions, - ], - value: field.defaultUploadLocationVolume, - disabled: readOnly, - }) }} -
-
- {{ forms.text({ - class: 'ltr', - id: "default-upload-location-subpath", - name: "defaultUploadLocationSubpath", - value: field.defaultUploadLocationSubpath, - placeholder: "path/to/subfolder"|t('app'), - disabled: readOnly, - }) }} -
-
- {% endblock %} - {% endembed %} - - {{ forms.checkboxSelectField({ - id: 'availableTransforms', - name: 'availableTransforms', - label: 'Available Transforms'|t('ckeditor'), - instructions: 'The transforms that should be available when inserting images.'|t('ckeditor'), - options: transformOptions, - values: field.availableTransforms, - showAllOption: transformOptions|length ? true : false, - disabled: readOnly, - }) }} - - {{ forms.selectField({ - id: 'defaultTransform', - name: 'defaultTransform', - label: 'Default Transform'|t('ckeditor'), - instructions: 'The default transform that should be applied when inserting an image.'|t('ckeditor'), - options: defaultTransformOptions, - value: field.defaultTransform, - disabled: readOnly, - }) }} - {{ forms.lightswitchField({ label: 'Show unpermitted volumes'|t('ckeditor'), instructions: 'Whether to show volumes that the user doesn’t have permission to view.'|t('ckeditor'), @@ -222,6 +164,106 @@ on: field.showUnpermittedFiles, disabled: readOnly, }) }} + + {% embed '_includes/forms/field.twig' with { + label: 'Image Mode'|t('ckeditor'), + instructions: 'How should new images be added to the field contents?'|t('ckeditor'), + } %} + {% block input %} +
+ + +
+ {% endblock %} + {% endembed %} + + {% tag 'div' with { + id: 'image-mode--img', + class: field.imageMode != 'img' ? 'hidden' : null, + } %} + {% embed '_includes/forms/field.twig' with { + id: 'default-upload-location', + label: 'Default Upload Location'|t('app'), + instructions: 'Where images should be stored when they are uploaded directly to the field via drag & drop.'|t('ckeditor'), + } %} + {% block input %} + {% import '_includes/forms.twig' as forms %} +
+
+ {{ forms.select({ + id: "default-upload-location-volume", + name: "defaultUploadLocationVolume", + options: [ + { + label: 'None'|t('app'), + value: '', + }, + ...volumeOptions, + ], + value: field.defaultUploadLocationVolume, + disabled: readOnly, + }) }} +
+
+ {{ forms.text({ + class: 'ltr', + id: "default-upload-location-subpath", + name: "defaultUploadLocationSubpath", + value: field.defaultUploadLocationSubpath, + placeholder: "path/to/subfolder"|t('app'), + disabled: readOnly, + }) }} +
+
+ {% endblock %} + {% endembed %} + + {{ forms.checkboxSelectField({ + id: 'availableTransforms', + name: 'availableTransforms', + label: 'Available Transforms'|t('ckeditor'), + instructions: 'The transforms that should be available when inserting images.'|t('ckeditor'), + options: transformOptions, + values: field.availableTransforms, + showAllOption: transformOptions|length ? true : false, + disabled: readOnly, + }) }} + + {{ forms.selectField({ + id: 'defaultTransform', + name: 'defaultTransform', + label: 'Default Transform'|t('ckeditor'), + instructions: 'The default transform that should be applied when inserting an image.'|t('ckeditor'), + options: defaultTransformOptions, + value: field.defaultTransform, + disabled: readOnly, + }) }} + {% endtag %} + + {% tag 'div' with { + id: 'image-mode--entries', + class: field.imageMode != 'entries' ? 'hidden' : null, + } %} + {% include 'ckeditor/_image-field-select.twig' %} + {% endtag %}
@@ -463,4 +505,25 @@ }); })(); {% endjs %} + + {# use script[type=module] so it executes after the entry type select initialization #} + {% script with {type: 'module'} %} +const entryTypeSelect = $("#{{ 'entry-types'|namespaceInputId }}").data('componentSelect'); + +const updateImageField = () => { + const entryTypes = Object.values(Garnish.getPostData(entryTypeSelect.$container)); + Craft.sendActionRequest('POST', 'ckeditor/field-settings/render-image-field', { + data: { + namespace: {{ view.getNamespace()|json_encode|raw }}, + entryTypes, + value: $("#{{ 'image-field'|namespaceInputId }}").val(), + }, + }).then(({data}) => { + $("#{{ 'image-field-field'|namespaceInputId }}").replaceWith(data.html); + }); +}; + +entryTypeSelect.on('change', () => updateImageField()); +entryTypeSelect.on('applySettings', () => updateImageField()); + {% endscript %} {% endif %} diff --git a/src/templates/_image-field-select.twig b/src/templates/_image-field-select.twig new file mode 100644 index 00000000..742e1c4c --- /dev/null +++ b/src/templates/_image-field-select.twig @@ -0,0 +1,32 @@ +{% set readOnly = readOnly ?? false %} + +{% embed '_includes/forms/field' with { + id: 'image-field', + label: 'Image Field'|t('ckeditor'), + instructions: 'Choose which Assets field should be used to store images, from the selected entry types.'|t('ckeditor'), +} %} + {% block input %} + {% import "_includes/forms" as forms %} +
+ {% set options = field.getEntryTypes()|map( + et => et.getFieldLayout().getCustomFields()|filter( + f => f is instance of('craft\\fields\\Assets') + )|map(f => { + label: "#{et.getUiLabel()} → #{f.getUiLabel()}", + value: "#{et.uid}.#{f.layoutElement.uid}", + }) + )|flatten(1) %} + {% if options|length %} + {{ forms.select({ + id: 'image-field', + name: 'imageFieldPath', + options: options|sort((a, b) => a.label <=> b.label), + value: field.imageFieldUid ? "#{field.imageEntryTypeUid}.#{field.imageFieldUid}", + disabled: readOnly, + }) }} + {% else %} +

{{ 'No entry types with an Assets field have been selected yet.'|t('ckeditor') }}

+ {% endif %} +
+ {% endblock %} +{% endembed %} diff --git a/src/translations/en/ckeditor.php b/src/translations/en/ckeditor.php index 5d004a6a..36d5eb6c 100644 --- a/src/translations/en/ckeditor.php +++ b/src/translations/en/ckeditor.php @@ -6,6 +6,7 @@ 'Advanced' => 'Advanced', 'Available Transforms' => 'Available Transforms', 'Changing this may result in data loss.' => 'Changing this may result in data loss.', + 'Choose which Assets field should be used to store images, from the selected entry types.' => 'Choose which Assets field should be used to store images, from the selected entry types.', 'Choose which heading levels should be available to this field.' => 'Choose which heading levels should be available to this field.', 'Column Type' => 'Column Type', 'Config Options' => 'Config Options', @@ -21,12 +22,18 @@ 'HTML Purifier Config' => 'HTML Purifier Config', 'Heading Levels' => 'Heading Levels', 'Heading {level}' => 'Heading {level}', + 'How should new images be added to the field contents?' => 'How should new images be added to the field contents?', + 'Image Field' => 'Image Field', + 'Image Mode' => 'Image Mode', + 'Image tags' => 'Image tags', 'Insert link' => 'Insert link', 'Link to a category' => 'Link to a category', 'Link to an asset' => 'Link to an asset', 'Link to an entry' => 'Link to an entry', 'Link to the current site' => 'Link to the current site', 'Links' => 'Links', + 'Nested entries' => 'Nested entries', + 'No entry types with an Assets field have been selected yet.' => 'No entry types with an Assets field have been selected yet.', 'No transform' => 'No transform', 'Purify HTML' => 'Purify HTML', 'Raw content only' => 'Raw content only', diff --git a/src/web/assets/ckeditor/dist/ckeditor5-craftcms.js b/src/web/assets/ckeditor/dist/ckeditor5-craftcms.js index 01140b92..ff872399 100644 --- a/src/web/assets/ckeditor/dist/ckeditor5-craftcms.js +++ b/src/web/assets/ckeditor/dist/ckeditor5-craftcms.js @@ -1,4 +1,4 @@ -import { ImageInsertUI as au, ButtonView as gi, IconImage as su, Command as El, Plugin as Hn, ImageUtils as Rc, Collection as na, ViewModel as bi, createDropdown as ra, DropdownButtonView as lu, IconObjectSizeMedium as cu, addListToDropdown as os, Widget as uu, viewToModelPositionOutsideModelElement as du, toWidget as pu, DomEventObserver as fu, View as Tr, IconPlus as Mc, WidgetToolbarRepository as Pc, isWidget as hu, findAttributeRange as mu, LinkUI as Dc, ContextualBalloon as gu, ModelRange as bu, SwitchButtonView as yu, LabeledFieldView as vu, createLabeledInputText as ku, ClassicEditor as wu, SourceEditing as zc, Heading as _u } from "ckeditor5"; +import { ImageInsertUI as au, ButtonView as gi, IconImage as su, Command as El, Plugin as Hn, ImageUtils as Rc, Collection as na, ViewModel as yi, createDropdown as ra, DropdownButtonView as lu, IconObjectSizeMedium as cu, addListToDropdown as os, Widget as uu, viewToModelPositionOutsideModelElement as du, toWidget as pu, DomEventObserver as fu, View as Tr, IconPlus as Mc, WidgetToolbarRepository as Pc, isWidget as hu, findAttributeRange as mu, LinkUI as Dc, ContextualBalloon as gu, ModelRange as yu, SwitchButtonView as bu, LabeledFieldView as vu, createLabeledInputText as ku, ClassicEditor as wu, SourceEditing as zc, Heading as _u } from "ckeditor5"; /** * @link https://craftcms.com/ * @copyright Copyright (c) Pixel & Tonic, Inc. @@ -12,38 +12,67 @@ class Xu extends au { super(...arguments), this.$container = null, this.progressBar = null, this.$fileInput = null, this.uploader = null; } init() { - if (!this._assetSources) { + if (!this._imageSources) { console.warn( 'Omitting the "image" CKEditor toolbar button, because there aren’t any permitted volumes.' ); return; } + if (this._imageMode === "entries" && (!this._imageEntryTypeId || !this._imageFieldHandle)) { + console.warn( + 'Omitting the "image" CKEditor toolbar button, because no image field was selected.' + ); + return; + } const _ = this.editor.ui.componentFactory, E = (O) => this._createToolbarImageButton(O); _.add("insertImage", E), _.add("imageInsert", E), this._attachUploader(); } - get _assetSources() { - return this.editor.config.get("assetSources"); + get _imageMode() { + return this.editor.config.get("imageMode"); + } + get _imageSources() { + return this.editor.config.get("imageSources"); + } + get _imageModalSettings() { + return this.editor.config.get("imageModalSettings") ?? {}; + } + get _imageEntryTypeId() { + return this.editor.config.get("imageEntryTypeId"); + } + get _imageFieldHandle() { + return this.editor.config.get("imageFieldHandle"); + } + /** + * Returns Craft.ElementEditor instance that the CKEditor field belongs to. + * + * @returns {*} + */ + get _elementEditor() { + return $(this.editor.ui.view.element).closest( + "form,.lp-editor-container" + ).data("elementEditor"); } _createToolbarImageButton(_) { const E = this.editor, O = E.t, T = new gi(_); T.isEnabled = !0, T.label = O("Insert image"), T.icon = su, T.tooltip = !0; - const Z = E.commands.get("insertImage"); - return T.bind("isEnabled").to(Z), this.listenTo(T, "execute", () => this._showImageSelectModal()), T; + const X = E.commands.get("insertImage"); + return T.bind("isEnabled").to(X), this.listenTo(T, "execute", () => this._showImageSelectModal()), T; } _showImageSelectModal() { - const _ = this._assetSources, E = this.editor, O = E.config, T = Object.assign({}, O.get("assetSelectionCriteria"), { + const _ = this._imageSources, E = this.editor, O = E.config, T = Object.assign({}, O.get("assetSelectionCriteria"), { kind: "image" }); Craft.createElementSelectorModal("craft\\elements\\Asset", { + ...this._imageModalSettings, storageKey: `ckeditor:${this.pluginName}:'craft\\elements\\Asset'`, sources: _, criteria: T, defaultSiteId: O.get("elementSiteId"), transforms: O.get("transforms"), - multiSelect: !0, autoFocusSearchBox: !1, - onSelect: (Z, i) => { - this._processAssetUrls(Z, i).then(() => { + multiSelect: !0, + onSelect: (X, i) => { + this._processSelectedAssets(X, i).then(() => { E.editing.view.focus(); }); }, @@ -53,25 +82,62 @@ class Xu extends au { closeOtherModals: !1 }); } - async _processAssetUrls(_, E) { + async _processSelectedAssets(_, E) { if (!_.length) return; - const O = this.editor, T = O.config.get("defaultTransform"), Z = []; + if (this._imageMode === "entries") { + for (const i of _) + await this._createImageEntry(i.id); + return; + } + const O = this.editor, T = O.config.get("defaultTransform"), X = []; for (const i of _) { const u = this._isTransformUrl(i.url); if (!u && T) { const f = await this._getTransformUrl(i.id, T); - Z.push(f); + X.push(f); } else { const f = this._buildAssetUrl( i.id, i.url, u ? E : T ); - Z.push(f); + X.push(f); } } - O.execute("insertImage", { source: Z }); + O.execute("insertImage", { source: X }); + } + async _createImageEntry(_) { + const E = this.editor, O = this._elementEditor, T = $(E.sourceElement).attr("name"); + O && T && await O.setFormValue(T, "*"); + const X = E.config.get( + "nestedElementAttributes" + ), i = { + ...X, + typeId: this._imageEntryTypeId + }; + O && (await O.markDeltaNameAsModified(E.sourceElement.name), i.ownerId = O.getDraftElementId( + X.ownerId + )); + let u; + try { + u = await Craft.sendActionRequest( + "POST", + "ckeditor/ckeditor/create-image-entry", + { + data: { + ...i, + assetIds: [_] + } + } + ); + } catch (f) { + throw Craft.cp.displayError(), f; + } + E.commands.execute("insertEntry", { + entryId: u.data.entryId, + siteId: u.data.siteId + }); } _buildAssetUrl(_, E, O) { return `${E}#asset:${_}:${O ? "transform:" + O : "url"}`; @@ -120,7 +186,7 @@ class Xu extends au { ), this.$fileInput = $("", { type: "file", class: "hidden", - multiple: !1 + multiple: !0 }).insertAfter(_.sourceElement), this.uploader = Craft.createUploader(null, this.$container, { dropZone: this.$container, fileInput: this.$fileInput, @@ -139,9 +205,9 @@ class Xu extends au { "drop", async (O, T) => { _.editing.view, _.model; - const Z = _.editing.mapper, i = T.dropRange; + const X = _.editing.mapper, i = T.dropRange; if (i) { - const u = i.start, f = Z.toModelPosition(u); + const u = i.start, f = X.toModelPosition(u); _.model.change((k) => { k.setSelection(f, 0); }); @@ -171,13 +237,16 @@ class Xu extends au { */ async _onUploadComplete(_, E = null) { const O = _ instanceof CustomEvent ? _.detail : E.result; - this.progressBar.hideProgressBar(), this.$container.removeClass("uploading"); - const T = this.editor.config.get("defaultTransform"), Z = this._isTransformUrl(O.url); + if (this.progressBar.hideProgressBar(), this.$container.removeClass("uploading"), this._imageMode === "entries") { + await this._createImageEntry(O.assetId); + return; + } + const T = this.editor.config.get("defaultTransform"), X = this._isTransformUrl(O.url); let i; - !Z && T ? i = await this._getTransformUrl(O.assetId, T) : i = this._buildAssetUrl( + !X && T ? i = await this._getTransformUrl(O.assetId, T) : i = this._buildAssetUrl( O.assetId, O.url, - Z ? transform : T + X ? transform : T ), this.editor.execute("insertImage", { source: i, breakBlock: !0 }); } /** @@ -186,11 +255,11 @@ class Xu extends au { _onUploadFailure(_, E = null) { var f, k; const O = _ instanceof CustomEvent ? _.detail : (f = E == null ? void 0 : E.jqXHR) == null ? void 0 : f.responseJSON; - let { message: T, filename: Z, errors: i } = O || {}; - Z = Z || ((k = E == null ? void 0 : E.files) == null ? void 0 : k[0].name); + let { message: T, filename: X, errors: i } = O || {}; + X = X || ((k = E == null ? void 0 : E.files) == null ? void 0 : k[0].name); let u = i ? Object.values(i).flat() : []; T || (u.length ? T = u.join(` -`) : Z ? T = Craft.t("app", "Upload failed for “{filename}”.", { filename: Z }) : T = Craft.t("app", "Upload failed.")), Craft.cp.displayError(T), this.progressBar.hideProgressBar(), this.$container.removeClass("uploading"); +`) : X ? T = Craft.t("app", "Upload failed for “{filename}”.", { filename: X }) : T = Craft.t("app", "Upload failed.")), Craft.cp.displayError(T), this.progressBar.hideProgressBar(), this.$container.removeClass("uploading"); } } /** @@ -239,17 +308,17 @@ class Eu extends El { * @fires execute */ execute(_) { - const O = this.editor.model, T = this._element(), Z = this._srcInfo(T); + const O = this.editor.model, T = this._element(), X = this._srcInfo(T); if (this.value = { transform: _.transform - }, Z) { - const i = `#asset:${Z.assetId}` + (_.transform ? `:transform:${_.transform}` : ""); + }, X) { + const i = `#asset:${X.assetId}` + (_.transform ? `:transform:${_.transform}` : ""); O.change((u) => { - const f = Z.src.replace(/#.*/, "") + i; + const f = X.src.replace(/#.*/, "") + i; u.setAttribute("src", f, T); }), Craft.sendActionRequest("post", "ckeditor/ckeditor/image-url", { data: { - assetId: Z.assetId, + assetId: X.assetId, transform: _.transform } }).then(({ data: u }) => { @@ -308,7 +377,7 @@ class Su extends Hn { const E = this.editor, O = E.t, T = { name: "transformImage:original", value: null - }, Z = [ + }, X = [ T, ..._.map((u) => ({ label: u.name, @@ -329,12 +398,12 @@ class Su extends Hn { if (!C || !C.transform) return this._getOptionLabelValue(T); const m = _.find( - (y) => y.handle === C.transform + (b) => b.handle === C.transform ); return m ? m.name : C.transform; }), k.bind("isEnabled").to(this), os( k, - () => this._getTransformDropdownListItemDefinitions(Z, f), + () => this._getTransformDropdownListItemDefinitions(X, f), { ariaLabel: O("Image resize list") } @@ -365,9 +434,9 @@ class Su extends Hn { _getTransformDropdownListItemDefinitions(_, E) { const O = new na(); return _.map((T) => { - const Z = { + const X = { type: "button", - model: new bi({ + model: new yi({ commandName: "transformImage", commandValue: T.value, label: this._getOptionLabelValue(T), @@ -375,7 +444,7 @@ class Su extends Hn { icon: null }) }; - Z.model.bind("isOn").to(E, "value", Cu(T.value)), O.add(Z); + X.model.bind("isOn").to(E, "value", Cu(T.value)), O.add(X); }), O; } } @@ -459,8 +528,8 @@ class Tu extends El { let T = { allowSavingAsNew: !1, // todo: we might want to change that, but currently we're doing the same functionality as in Redactor - onSave: (Z) => { - this._reloadImage(O.assetId, Z); + onSave: (X) => { + this._reloadImage(O.assetId, X); }, allowDegreeFractions: Craft.isImagick }; @@ -506,11 +575,11 @@ class Tu extends El { _getAllImageAssets() { const E = this.editor.model, O = E.createRangeIn(E.document.getRoot()); let T = []; - for (const Z of O.getWalker({ ignoreElementEnd: !0 })) - if (Z.item.is("element") && Z.item.name === "imageBlock") { - let i = this._srcInfo(Z.item); + for (const X of O.getWalker({ ignoreElementEnd: !0 })) + if (X.item.is("element") && X.item.name === "imageBlock") { + let i = this._srcInfo(X.item); i && T.push({ - element: Z.item, + element: X.item, srcInfo: i }); } @@ -555,13 +624,13 @@ class Ou extends Hn { */ _registerImageEditorButton() { const _ = this.editor, E = _.t, O = _.commands.get("imageEditor"), T = () => { - const Z = new gi(); - return Z.set({ + const X = new gi(); + return X.set({ label: E("Edit Image"), withText: !0 - }), Z.bind("isEnabled").to(O), this.listenTo(Z, "execute", (i) => { + }), X.bind("isEnabled").to(O), this.listenTo(X, "execute", (i) => { _.execute("imageEditor"), _.editing.view.focus(); - }), Z; + }), X; }; _.ui.componentFactory.add("imageEditor", T); } @@ -582,21 +651,26 @@ class Zu extends Hn { class Nu extends El { execute(_) { const E = this.editor, O = E.model.document.selection; - E.model.change((T) => { - const Z = T.createElement("craftEntryModel", { + if (!O.isCollapsed && O.getFirstRange()) { + const X = O.getSelectedElement(); + E.execute("insertParagraph", { + position: E.model.createPositionAfter(X) + }); + } + E.model.change((X) => { + const i = X.createElement("craftEntryModel", { ...Object.fromEntries(O.getAttributes()), cardHtml: _.cardHtml, entryId: _.entryId, siteId: _.siteId }); - E.model.insertObject(Z, null, null, { + E.model.insertObject(i, null, null, { setSelection: "on" }); }); } refresh() { - const E = this.editor.model.document.selection, O = !E.isCollapsed && E.getFirstRange(); - this.isEnabled = !O; + this.isEnabled = !0; } } class Pu extends Hn { @@ -648,9 +722,9 @@ class Pu extends Hn { // has to be lower case }, model: (O, { writer: T }) => { - const Z = O.getAttribute("data-card-html"), i = O.getAttribute("data-entry-id"), u = O.getAttribute("data-site-id") ?? null; + const X = O.getAttribute("data-card-html"), i = O.getAttribute("data-entry-id"), u = O.getAttribute("data-site-id") ?? null; return T.createElement("craftEntryModel", { - cardHtml: Z, + cardHtml: X, entryId: i, siteId: u }); @@ -658,9 +732,9 @@ class Pu extends Hn { }), _.for("editingDowncast").elementToElement({ model: "craftEntryModel", view: (O, { writer: T }) => { - const Z = O.getAttribute("entryId") ?? null, i = O.getAttribute("siteId") ?? null, u = T.createContainerElement("div", { + const X = O.getAttribute("entryId") ?? null, i = O.getAttribute("siteId") ?? null, u = T.createContainerElement("div", { class: "cke-entry-card", - "data-entry-id": Z, + "data-entry-id": X, "data-site-id": i }); return E(O, T, u), pu(u, T); @@ -668,14 +742,14 @@ class Pu extends Hn { }), _.for("dataDowncast").elementToElement({ model: "craftEntryModel", view: (O, { writer: T }) => { - const Z = O.getAttribute("entryId") ?? null, i = O.getAttribute("siteId") ?? null; + const X = O.getAttribute("entryId") ?? null, i = O.getAttribute("siteId") ?? null; return T.createContainerElement("craft-entry", { - "data-entry-id": Z, + "data-entry-id": X, "data-site-id": i }); } }); - const E = (O, T, Z) => { + const E = (O, T, X) => { this._getCardHtml(O).then((i) => { const u = T.createRawElement( "div", @@ -684,7 +758,7 @@ class Pu extends Hn { k.innerHTML = i.cardHtml, Craft.appendHeadHtml(i.headHtml), Craft.appendBodyHtml(i.bodyHtml); } ); - T.insert(T.createPositionAt(Z, 0), u); + T.insert(T.createPositionAt(X, 0), u); const f = this.editor; f.editing.view.focus(), setTimeout(() => { Craft.cp.elementThumbLoader.load($(f.ui.element)); @@ -707,24 +781,24 @@ class Pu extends Hn { const T = $(O[0]).data("layout-element"); if (E) return { cardHtml: E }; - const Z = _.getAttribute("entryId") ?? null, i = _.getAttribute("siteId") ?? null; + const X = _.getAttribute("entryId") ?? null, i = _.getAttribute("siteId") ?? null; try { const d = this.editor, m = $(d.ui.view.element).closest( "form,.lp-editor-container" ).data("elementEditor"); m && await m.checkForm(); - const { data: y } = await Craft.sendActionRequest( + const { data: b } = await Craft.sendActionRequest( "POST", "ckeditor/ckeditor/entry-card-html", { data: { - entryId: Z, + entryId: X, siteId: i, layoutElementUid: T } } ); - return y; + return b; } catch (d) { return console.error((u = d == null ? void 0 : d.response) == null ? void 0 : u.data), { cardHtml: '
' + (((k = (f = d == null ? void 0 : d.response) == null ? void 0 : f.data) == null ? void 0 : k.message) || "An unknown error occurred.") + "
" }; } @@ -742,7 +816,7 @@ class Iu extends Tr { constructor(_, E = {}) { super(_), this.set("isFocused", !1), this.entriesUi = E.entriesUi, this.editor = this.entriesUi.editor, this.entryType = E.entryType; const O = this.editor.commands.get("insertEntry"); - let T = new gi(), Z = { + let T = new gi(), X = { commandValue: this.entryType.model.commandValue, //entry type id label: this.entryType.model.label, @@ -751,7 +825,7 @@ class Iu extends Tr { type: this.entryType.model.label }) }, i = ["btn", "ck-reset_all-excluded"]; - this.entryType.model.icon && i.push(["icon", "cp-icon"]), Z.class = i.join(" "), this.entryType.model.withIcon && (Z.icon = this.entryType.model.icon), T.set(Z), this.listenTo(T, "execute", (u) => { + this.entryType.model.icon && i.push(["icon", "cp-icon"]), X.class = i.join(" "), this.entryType.model.withIcon && (X.icon = this.entryType.model.icon), T.set(X), this.listenTo(T, "execute", (u) => { this.entriesUi._showCreateEntrySlideout(u.source.commandValue); }), T.bind("isEnabled").to(O), this.setTemplate({ tag: "div", @@ -771,9 +845,9 @@ class Ru extends Tr { constructor(_, E = {}) { super(_), this.bindTemplate, this.set("isFocused", !1), this.entriesUi = E.entriesUi, this.editor = this.entriesUi.editor; const O = E.entryTypes, T = this.editor.commands.get("insertEntry"); - let Z = new na(); + let X = new na(); O.forEach((u) => { - u.model.color && (u.model.class || (u.model.class = ""), u.model.class += "icon " + u.model.color), Z.add(u); + u.model.color && (u.model.class || (u.model.class = ""), u.model.class += "icon " + u.model.color), X.add(u); }); const i = ra(_); i.buttonView.set({ @@ -781,7 +855,7 @@ class Ru extends Tr { icon: Mc, tooltip: !0, withText: !1 - }), i.bind("isEnabled").to(T), i.id = Craft.uuid(), os(i, () => Z, { + }), i.bind("isEnabled").to(T), i.id = Craft.uuid(), os(i, () => X, { ariaLabel: Craft.t("ckeditor", "Entry types list") }), this.listenTo(i, "execute", (u) => { this.entriesUi._showCreateEntrySlideout(u.source.commandValue); @@ -808,8 +882,8 @@ class Mu extends Tr { icon: Mc, tooltip: !0, withText: !1 - }), T.bind("isEnabled").to(O), T.id = Craft.uuid(), this.listenTo(T, "execute", (Z) => { - this.entriesUi._showCreateEntrySlideout(Z.source.commandValue); + }), T.bind("isEnabled").to(O), T.id = Craft.uuid(), this.listenTo(T, "execute", (X) => { + this.entriesUi._showCreateEntrySlideout(X.source.commandValue); }), this.setTemplate({ tag: "div", attributes: { @@ -870,10 +944,10 @@ class zu extends Hn { const _ = this.editor.editing.view, E = _.document; _.addObserver(Du), this.editor.listenTo(E, "dblclick", (O, T) => { if (!this.editor.isReadOnly) { - const Z = this.editor.editing.mapper.toModelElement( + const X = this.editor.editing.mapper.toModelElement( T.target.parent ); - Z.name === "craftEntryModel" && this._initEditEntrySlideout(T, Z); + X.name === "craftEntryModel" && this._initEditEntrySlideout(T, X); } }); } @@ -902,7 +976,7 @@ class zu extends Hn { else { let O = this._getEntryTypeButtonsCollection( E ?? [] - ), T = O.filter((i) => i.model.expanded), Z = O.filter((i) => !i.model.expanded); + ), T = O.filter((i) => i.model.expanded), X = O.filter((i) => !i.model.expanded); T.forEach((i, u) => { this.editor.ui.componentFactory.add( `createEntry-${i.model.uid}`, @@ -911,11 +985,11 @@ class zu extends Hn { entryType: i }) ); - }), Z.length && this.editor.ui.componentFactory.add( + }), X.length && this.editor.ui.componentFactory.add( "createEntry", (i) => new Ru(this.editor.locale, { entriesUi: this, - entryTypes: Z + entryTypes: X }) ); } @@ -932,7 +1006,7 @@ class zu extends Hn { return _.map((O) => { const T = { type: "button", - model: new bi({ + model: new yi({ commandValue: O.value, //entry type id color: O.expanded ? null : O.color, @@ -996,7 +1070,7 @@ class zu extends Hn { * @private */ _showEditEntrySlideout(_, E, O) { - const T = this.editor, Z = T.model, i = this.getElementEditor(); + const T = this.editor, X = T.model, i = this.getElementEditor(); let u = this._getCardElement(_); const f = u.data("owner-id"), k = Craft.createElementEditor(this.elementType, null, { elementId: _, @@ -1023,7 +1097,7 @@ class zu extends Hn { } }); k.on("beforeClose", () => { - Z.change((d) => { + X.change((d) => { d.setSelection(d.createPositionAfter(O)), T.editing.view.focus(); }); }), k.on("close", () => { @@ -1038,7 +1112,7 @@ class zu extends Hn { */ async _showCreateEntrySlideout(_) { var C, m; - const E = this.editor, O = E.model, Z = O.document.selection.getFirstRange(), i = E.config.get( + const E = this.editor, O = E.model, X = O.document.selection.getFirstRange(), i = E.config.get( "nestedElementAttributes" ), u = Object.assign({}, i, { typeId: _ @@ -1055,8 +1129,8 @@ class zu extends Hn { data: u } )).data; - } catch (y) { - throw Craft.cp.displayError((m = (C = y == null ? void 0 : y.response) == null ? void 0 : C.data) == null ? void 0 : m.error), y; + } catch (b) { + throw Craft.cp.displayError((m = (C = b == null ? void 0 : b.response) == null ? void 0 : C.data) == null ? void 0 : m.error), b; } const d = Craft.createElementEditor(this.elementType, { elementId: k.element.id, @@ -1065,19 +1139,19 @@ class zu extends Hn { fresh: 1, siteId: k.element.siteId }, - onSubmit: (y) => { + onSubmit: (b) => { E.commands.execute("insertEntry", { - entryId: y.data.id, - siteId: y.data.siteId + entryId: b.data.id, + siteId: b.data.siteId }); } }); d.on("beforeClose", () => { - d.$triggerElement = null, O.change((y) => { - y.setSelection( - y.createPositionAt( + d.$triggerElement = null, O.change((b) => { + b.setSelection( + b.createPositionAt( E.model.document.getRoot(), - Z.end.path[0] + X.end.path[0] ) ); }), E.editing.view.focus(); @@ -1121,12 +1195,12 @@ class ju extends Hn { _.for("downcast").attributeToElement({ model: this.conversionData[E].model, view: (O, { writer: T }) => { - const Z = T.createAttributeElement( + const X = T.createAttributeElement( "a", { [this.conversionData[E].view]: O }, { priority: 5 } ); - return T.setCustomProperty("link", !0, Z), Z; + return T.setCustomProperty("link", !0, X), X; } }), _.for("upcast").attributeToAttribute({ view: { @@ -1144,15 +1218,15 @@ class ju extends Hn { let O = !1; E.on( "execute", - (T, Z) => { + (T, X) => { if (O) { O = !1; return; } T.stop(), O = !0; - const i = Z[Z.length - 1], u = _.model.document.selection; + const i = X[X.length - 1], u = _.model.document.selection; _.model.change((f) => { - _.execute("link", ...Z); + _.execute("link", ...X); const k = u.getFirstPosition(); this.conversionData.forEach((d) => { if (u.isCollapsed) { @@ -1182,12 +1256,12 @@ class ju extends Hn { } _adjustUnlinkCommand() { const _ = this.editor, E = _.commands.get("unlink"), { model: O } = _, { selection: T } = O.document; - let Z = !1; + let X = !1; E.on( "execute", (i) => { - Z || (i.stop(), O.change(() => { - Z = !0, _.execute("unlink"), Z = !1, O.change((u) => { + X || (i.stop(), O.change(() => { + X = !0, _.execute("unlink"), X = !1, O.change((u) => { let f; this.conversionData.forEach((k) => { T.isCollapsed ? f = [ @@ -1265,7 +1339,7 @@ class Lu extends Tr { } } ).then((T) => { - var Z; + var X; if (Object.keys(T.data.elements).length > 0) { if (Craft.isMultiSite && this.linkUi.sitesView != null) for (const [f, k] of Object.entries( @@ -1291,7 +1365,7 @@ class Lu extends Tr { } ]; Craft.addActionsToChip(i, u), _._alignFocus(); - } else if (((Z = this.linkUi.previousLinkValue) == null ? void 0 : Z.length) > 0) { + } else if (((X = this.linkUi.previousLinkValue) == null ? void 0 : X.length) > 0) { const { formView: i } = this.linkUi._linkUI; i.urlInputView.fieldView.set( "value", @@ -1304,12 +1378,12 @@ class Lu extends Tr { class: "btn add icon dashed" }), this.button.render(), this.element.innerHTML = this.button.element.outerHTML; }).catch((T) => { - var Z, i, u, f; - throw Craft.cp.displayError((i = (Z = T == null ? void 0 : T.response) == null ? void 0 : Z.data) == null ? void 0 : i.message), ((f = (u = T == null ? void 0 : T.response) == null ? void 0 : u.data) == null ? void 0 : f.message) ?? T; + var X, i, u, f; + throw Craft.cp.displayError((i = (X = T == null ? void 0 : T.response) == null ? void 0 : X.data) == null ? void 0 : i.message), ((f = (u = T == null ? void 0 : T.response) == null ? void 0 : u.data) == null ? void 0 : f.message) ?? T; }); } } -class Uu extends Tr { +class Fu extends Tr { constructor(_, E = {}) { super(_), this.bindTemplate, this.set("isFocused", !1), this.linkUi = E.linkUi, this.editor = this.linkUi.editor, this.elementId = this.linkUi._getLinkElementId(), this.siteId = this.linkUi._getLinkSiteId(), this.linkOption = E.linkOption, this.linkUi._getLinkElementRefHandle(), this.siteDropdownView = ra(this.linkUi._linkUI.formView.locale), this.siteDropdownItemModels = null, this.localizedRefHandleRE = null; const O = CKE_LOCALIZED_REF_HANDLES.join("|"); @@ -1341,13 +1415,13 @@ class Uu extends Tr { }), this.siteDropdownItemModels = Object.fromEntries( Craft.sites.map((T) => [ T.id, - new bi({ + new yi({ label: T.name, siteId: T.id, withText: !0 }) ]) - ), this.siteDropdownItemModels.current = new bi({ + ), this.siteDropdownItemModels.current = new yi({ label: Craft.t("ckeditor", "Link to the current site"), siteId: null, withText: !0 @@ -1364,17 +1438,17 @@ class Uu extends Tr { } ]) ), this.siteDropdownView.on("execute", (T) => { - const Z = this.linkUi._urlInputRefMatch(this.localizedRefHandleRE); - if (!Z) { + const X = this.linkUi._urlInputRefMatch(this.localizedRefHandleRE); + if (!X) { console.warn( `No reference tag hash present in URL: ${this.linkUi._urlInputValue()}` ); return; } const { siteId: i } = T.source; - let u = Z[1]; + let u = X[1]; i && (u += `@${i}`), this.linkUi.previousLinkValue = this.linkUi._urlInputValue(); - const f = this.linkUi._urlInputValue().replace(Z[0], u); + const f = this.linkUi._urlInputValue().replace(X[0], u); _.urlInputView.fieldView.set("value", f), this._toggleSiteDropdownView(); }), this.listenTo(O, "change:value", () => { this._toggleSiteDropdownView(); @@ -1398,7 +1472,7 @@ class Uu extends Tr { }); } } -class Fu extends Tr { +class Uu extends Tr { constructor(_, E = {}) { super(_); const O = this.bindTemplate; @@ -1434,8 +1508,8 @@ class Fu extends Tr { const { formView: E } = this.linkUi._linkUI; if (_.target.open) { const O = E._focusables.getIndex(this); - this.advancedChildren._items.forEach((T, Z) => { - E._focusables.add(T, O + Z + 1), E.focusTracker.add(T.element, O + Z + 1); + this.advancedChildren._items.forEach((T, X) => { + E._focusables.add(T, O + X + 1), E.focusTracker.add(T.element, O + X + 1); }); } else this.advancedChildren._items.forEach((O, T) => { @@ -1468,9 +1542,9 @@ class Vu extends Hn { `(.+)(#((?:${E})):(\\d+))(?:@(\\d+))?` ), this._modifyFormViewTemplate(), this._balloon.on( "set:visibleView", - (O, T, Z, i) => { + (O, T, X, i) => { const { formView: u } = this._linkUI; - Z === i || Z !== u || this._alignFocus(); + X === i || X !== u || this._alignFocus(); } ); } @@ -1529,8 +1603,8 @@ class Vu extends Hn { ]) ), O.isEmpty && this._showLinkTypeForm("default"), this.linkTypeDropdownView.on("execute", (T) => { if (T.source.linkOption) { - const Z = T.source.linkOption; - this._selectLinkTypeDropdownItem(Z.refHandle), this._showLinkTypeForm(Z, _); + const X = T.source.linkOption; + this._selectLinkTypeDropdownItem(X.refHandle), this._showLinkTypeForm(X, _); } else this._selectLinkTypeDropdownItem("default"), this._showLinkTypeForm("default"); }), this.listenTo(O, "change:value", () => { @@ -1590,7 +1664,7 @@ class Vu extends Hn { const _ = []; for (const E of this.linkOptions) _.push( - new bi({ + new yi({ label: E.label, handle: E.refHandle, linkOption: E, @@ -1598,7 +1672,7 @@ class Vu extends Hn { }) ); return _.push( - new bi({ + new yi({ label: Craft.t("app", "URL"), handle: "default", withText: !0 @@ -1610,8 +1684,8 @@ class Vu extends Hn { */ _showLinkTypeForm(_) { var u, f, k, d; - const { formView: E } = this._linkUI, { children: O } = E, { urlInputView: T } = E, { displayedTextInputView: Z } = E; - Z.focus(), this.linkTypeWrapperView !== null && O.remove(this.linkTypeWrapperView), _ === "default" ? (this.elementInputView = T, this.sitesView !== null && (f = (u = this.sitesView) == null ? void 0 : u.siteDropdownView) != null && f.buttonView && this.sitesView.siteDropdownView.buttonView.set("isVisible", !1)) : (this.elementInputView = new Lu(E.locale, { + const { formView: E } = this._linkUI, { children: O } = E, { urlInputView: T } = E, { displayedTextInputView: X } = E; + X.focus(), this.linkTypeWrapperView !== null && O.remove(this.linkTypeWrapperView), _ === "default" ? (this.elementInputView = T, this.sitesView !== null && (f = (u = this.sitesView) == null ? void 0 : u.siteDropdownView) != null && f.buttonView && this.sitesView.siteDropdownView.buttonView.set("isVisible", !1)) : (this.elementInputView = new Lu(E.locale, { linkUi: this, linkOption: _, value: this._urlInputValue() @@ -1620,7 +1694,7 @@ class Vu extends Hn { this.linkTypeDropdownView, this.elementInputView ]; - if (Craft.isMultiSite && this.sitesView == null && (this.sitesView = new Uu(E.locale, { + if (Craft.isMultiSite && this.sitesView == null && (this.sitesView = new Fu(E.locale, { linkUi: this, linkOption: _ })), this.sitesView != null) { @@ -1650,8 +1724,8 @@ class Vu extends Hn { * Show element selector modal for given element type (link option). */ _showElementSelectorModal(_) { - const E = this.editor, O = E.model, T = O.document.selection, Z = T.isCollapsed, i = T.getFirstRange(), u = this._linkUI._getSelectedLinkElement(), f = () => { - E.editing.view.focus(), !Z && i && O.change((k) => { + const E = this.editor, O = E.model, T = O.document.selection, X = T.isCollapsed, i = T.getFirstRange(), u = this._linkUI._getSelectedLinkElement(), f = () => { + E.editing.view.focus(), !X && i && O.change((k) => { k.setSelection(i); }), this._linkUI._hideFakeVisualSelection(); }; @@ -1664,24 +1738,24 @@ class Vu extends Hn { onSelect: (k) => { if (k.length) { const d = k[0], C = `${d.url}#${_.refHandle}:${d.id}@${d.siteId}`; - if (E.editing.view.focus(), (!Z || u) && i) { + if (E.editing.view.focus(), (!X || u) && i) { O.change((v) => { v.setSelection(i); }); const m = E.commands.get("link"); - let y = this._getAdvancedFieldValues(); - m.execute(C, y); + let b = this._getAdvancedFieldValues(); + m.execute(C, b); } else O.change((m) => { - let y = this._getAdvancedFieldValues(); + let b = this._getAdvancedFieldValues(); if (m.insertText( d.label, { linkHref: C }, T.getFirstPosition(), - y - ), i instanceof bu) + b + ), i instanceof yu) try { const v = i.clone(); v.end.path[1] += d.label.length, m.setSelection(v); @@ -1713,46 +1787,46 @@ class Vu extends Hn { _addAdvancedLinkFieldInputs() { var T; const _ = this.editor.commands.get("link"), { formView: E } = this._linkUI, { children: O } = E; - this.advancedView = new Fu(E.locale, { + this.advancedView = new Uu(E.locale, { linkUi: this }), O.add(this.advancedView, 3); - for (const Z of this.advancedLinkFields) { - let i = (T = Z.conversion) == null ? void 0 : T.model; + for (const X of this.advancedLinkFields) { + let i = (T = X.conversion) == null ? void 0 : T.model; if (i && typeof E[i] > "u") - if (Z.conversion.type === "bool") { - const u = new yu(); + if (X.conversion.type === "bool") { + const u = new bu(); u.set({ withText: !0, - label: Z.label, + label: X.label, isToggleable: !0 - }), Z.tooltip && (u.tooltip = Z.tooltip), this.advancedView.advancedChildren.add(u), E[i] = u, E[i].bind("isOn").to(_, i, (f) => f === void 0 ? (E[i].element.value = "", !1) : (E[i].element.value = Z.conversion.value, !0)), u.on("execute", () => { - u.isOn ? (u.isOn = !1, E[i].element.value = "") : (u.isOn = !0, E[i].element.value = Z.conversion.value); + }), X.tooltip && (u.tooltip = X.tooltip), this.advancedView.advancedChildren.add(u), E[i] = u, E[i].bind("isOn").to(_, i, (f) => f === void 0 ? (E[i].element.value = "", !1) : (E[i].element.value = X.conversion.value, !0)), u.on("execute", () => { + u.isOn ? (u.isOn = !1, E[i].element.value = "") : (u.isOn = !0, E[i].element.value = X.conversion.value); }); } else { - let u = this._addLabeledField(Z); + let u = this._addLabeledField(X); E[i] = u, E[i].fieldView.bind("value").to(_, i), E[i].fieldView.element.value = _[i] || ""; } - else if (Z.value === "urlSuffix") { - let u = this._addLabeledField(Z); + else if (X.value === "urlSuffix") { + let u = this._addLabeledField(X); this.listenTo( u.fieldView, "change:isFocused", (f, k, d, C) => { if (d !== C && !d) { - let m = f.source.element.value, y = null; + let m = f.source.element.value, b = null; const v = this._urlInputRefMatch(this.urlWithRefHandleRE); - v ? y = v[1] : y = this._urlInputValue(); + v ? b = v[1] : b = this._urlInputValue(); try { - let N = new URL(y), I = N.search, D = N.hash, L = y.replace(D, "").replace(I, ""); + let N = new URL(b), I = N.search, D = N.hash, L = b.replace(D, "").replace(I, ""); const se = this._urlInputValue().replace( - y, + b, L + m ); E.urlInputView.fieldView.set("value", se); } catch { - let [I, D] = y.split("#"), [L, se] = I.split("?"); + let [I, D] = b.split("#"), [L, se] = I.split("?"); const ee = this._urlInputValue().replace( - y, + b, L + m ); E.urlInputView.fieldView.set("value", ee); @@ -1795,7 +1869,7 @@ class Vu extends Hn { let T = null; O ? T = O[1] : T = this._urlInputValue(); try { - let Z = new URL(T), i = Z.search, u = Z.hash; + let X = new URL(T), i = X.search, u = X.hash; _.fieldView.set("value", i + u); } catch { let [i, u] = T.split("#"), [f, k] = i.split("?"); @@ -1814,7 +1888,7 @@ class Vu extends Hn { let T = this._getAdvancedFieldValues(); E.once( "execute", - (Z, i) => { + (X, i) => { i.length === 4 ? Object.assign(i[3], T) : i.push(T); }, { priority: "highest" } @@ -1860,7 +1934,7 @@ function Hu(Te) { var _l = { exports: {} }; /*! For license information please see inspector.js.LICENSE.txt */ var Ic; -function Bu() { +function $u() { return Ic || (Ic = 1, (function(Te, _) { (function(E, O) { Te.exports = O(); @@ -1872,11 +1946,11 @@ function Bu() { k(d, C), i.exports = d.locals || {}; }, 42: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.toString = void 0; - const k = f(1099), d = f(7860), C = f(5180), m = { string: k.quoteString, number: (y) => Object.is(y, -0) ? "-0" : String(y), boolean: String, symbol: (y, v, N) => { - const I = Symbol.keyFor(y); - return I !== void 0 ? `Symbol.for(${N(I)})` : `Symbol(${N(y.description)})`; - }, bigint: (y, v, N) => `BigInt(${N(String(y))})`, undefined: String, object: d.objectToString, function: C.functionToString }; - u.toString = (y, v, N, I) => y === null ? "null" : m[typeof y](y, v, N, I); + const k = f(1099), d = f(7860), C = f(5180), m = { string: k.quoteString, number: (b) => Object.is(b, -0) ? "-0" : String(b), boolean: String, symbol: (b, v, N) => { + const I = Symbol.keyFor(b); + return I !== void 0 ? `Symbol.for(${N(I)})` : `Symbol(${N(b.description)})`; + }, bigint: (b, v, N) => `BigInt(${N(String(b))})`, undefined: String, object: d.objectToString, function: C.functionToString }; + u.toString = (b, v, N, I) => b === null ? "null" : m[typeof b](b, v, N, I); }, 312: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }); var k, d = f(1720), C = (k = d) && k.__esModule ? k : { default: k }; @@ -1910,73 +1984,73 @@ function Bu() { const C = d; }, 1089: (i, u, f) => { function k(R) { - return k = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(U) { - return typeof U; - } : function(U) { - return U && typeof Symbol == "function" && U.constructor === Symbol && U !== Symbol.prototype ? "symbol" : typeof U; + return k = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(F) { + return typeof F; + } : function(F) { + return F && typeof Symbol == "function" && F.constructor === Symbol && F !== Symbol.prototype ? "symbol" : typeof F; }, k(R); } - Object.defineProperty(u, "__esModule", { value: !0 }), u.matchesSelector = D, u.matchesSelectorAndParentsTo = function(R, U, H) { + Object.defineProperty(u, "__esModule", { value: !0 }), u.matchesSelector = D, u.matchesSelectorAndParentsTo = function(R, F, H) { var ne = R; do { - if (D(ne, U)) return !0; + if (D(ne, F)) return !0; if (ne === H) return !1; ne = ne.parentNode; } while (ne); return !1; - }, u.addEvent = function(R, U, H, ne) { + }, u.addEvent = function(R, F, H, ne) { if (R) { var pe = v({ capture: !0 }, ne); - R.addEventListener ? R.addEventListener(U, H, pe) : R.attachEvent ? R.attachEvent("on" + U, H) : R["on" + U] = H; + R.addEventListener ? R.addEventListener(F, H, pe) : R.attachEvent ? R.attachEvent("on" + F, H) : R["on" + F] = H; } - }, u.removeEvent = function(R, U, H, ne) { + }, u.removeEvent = function(R, F, H, ne) { if (R) { var pe = v({ capture: !0 }, ne); - R.removeEventListener ? R.removeEventListener(U, H, pe) : R.detachEvent ? R.detachEvent("on" + U, H) : R["on" + U] = null; + R.removeEventListener ? R.removeEventListener(F, H, pe) : R.detachEvent ? R.detachEvent("on" + F, H) : R["on" + F] = null; } }, u.outerHeight = function(R) { - var U = R.clientHeight, H = R.ownerDocument.defaultView.getComputedStyle(R); - return U += (0, d.int)(H.borderTopWidth), U += (0, d.int)(H.borderBottomWidth); + var F = R.clientHeight, H = R.ownerDocument.defaultView.getComputedStyle(R); + return F += (0, d.int)(H.borderTopWidth), F += (0, d.int)(H.borderBottomWidth); }, u.outerWidth = function(R) { - var U = R.clientWidth, H = R.ownerDocument.defaultView.getComputedStyle(R); - return U += (0, d.int)(H.borderLeftWidth), U += (0, d.int)(H.borderRightWidth); + var F = R.clientWidth, H = R.ownerDocument.defaultView.getComputedStyle(R); + return F += (0, d.int)(H.borderLeftWidth), F += (0, d.int)(H.borderRightWidth); }, u.innerHeight = function(R) { - var U = R.clientHeight, H = R.ownerDocument.defaultView.getComputedStyle(R); - return U -= (0, d.int)(H.paddingTop), U -= (0, d.int)(H.paddingBottom); + var F = R.clientHeight, H = R.ownerDocument.defaultView.getComputedStyle(R); + return F -= (0, d.int)(H.paddingTop), F -= (0, d.int)(H.paddingBottom); }, u.innerWidth = function(R) { - var U = R.clientWidth, H = R.ownerDocument.defaultView.getComputedStyle(R); - return U -= (0, d.int)(H.paddingLeft), U -= (0, d.int)(H.paddingRight); - }, u.offsetXYFromParent = function(R, U, H) { - var ne = U === U.ownerDocument.body ? { left: 0, top: 0 } : U.getBoundingClientRect(), pe = (R.clientX + U.scrollLeft - ne.left) / H, oe = (R.clientY + U.scrollTop - ne.top) / H; + var F = R.clientWidth, H = R.ownerDocument.defaultView.getComputedStyle(R); + return F -= (0, d.int)(H.paddingLeft), F -= (0, d.int)(H.paddingRight); + }, u.offsetXYFromParent = function(R, F, H) { + var ne = F === F.ownerDocument.body ? { left: 0, top: 0 } : F.getBoundingClientRect(), pe = (R.clientX + F.scrollLeft - ne.left) / H, oe = (R.clientY + F.scrollTop - ne.top) / H; return { x: pe, y: oe }; - }, u.createCSSTransform = function(R, U) { - var H = L(R, U, "px"); + }, u.createCSSTransform = function(R, F) { + var H = L(R, F, "px"); return N({}, (0, C.browserPrefixToKey)("transform", C.default), H); - }, u.createSVGTransform = function(R, U) { - return L(R, U, ""); - }, u.getTranslation = L, u.getTouch = function(R, U) { + }, u.createSVGTransform = function(R, F) { + return L(R, F, ""); + }, u.getTranslation = L, u.getTouch = function(R, F) { return R.targetTouches && (0, d.findInArray)(R.targetTouches, function(H) { - return U === H.identifier; + return F === H.identifier; }) || R.changedTouches && (0, d.findInArray)(R.changedTouches, function(H) { - return U === H.identifier; + return F === H.identifier; }); }, u.getTouchIdentifier = function(R) { if (R.targetTouches && R.targetTouches[0]) return R.targetTouches[0].identifier; if (R.changedTouches && R.changedTouches[0]) return R.changedTouches[0].identifier; }, u.addUserSelectStyles = function(R) { if (R) { - var U = R.getElementById("react-draggable-style-el"); - U || ((U = R.createElement("style")).type = "text/css", U.id = "react-draggable-style-el", U.innerHTML = `.react-draggable-transparent-selection *::-moz-selection {all: inherit;} -`, U.innerHTML += `.react-draggable-transparent-selection *::selection {all: inherit;} -`, R.getElementsByTagName("head")[0].appendChild(U)), R.body && se(R.body, "react-draggable-transparent-selection"); + var F = R.getElementById("react-draggable-style-el"); + F || ((F = R.createElement("style")).type = "text/css", F.id = "react-draggable-style-el", F.innerHTML = `.react-draggable-transparent-selection *::-moz-selection {all: inherit;} +`, F.innerHTML += `.react-draggable-transparent-selection *::selection {all: inherit;} +`, R.getElementsByTagName("head")[0].appendChild(F)), R.body && se(R.body, "react-draggable-transparent-selection"); } }, u.removeUserSelectStyles = function(R) { if (R) try { if (R.body && ee(R.body, "react-draggable-transparent-selection"), R.selection) R.selection.empty(); else { - var U = (R.defaultView || window).getSelection(); - U && U.type !== "Caret" && U.removeAllRanges(); + var F = (R.defaultView || window).getSelection(); + F && F.type !== "Caret" && F.removeAllRanges(); } } catch { } @@ -1984,14 +2058,14 @@ function Bu() { var d = f(7056), C = (function(R) { if (R && R.__esModule) return R; if (R === null || k(R) !== "object" && typeof R != "function") return { default: R }; - var U = m(); - if (U && U.has(R)) return U.get(R); + var F = m(); + if (F && F.has(R)) return F.get(R); var H = {}, ne = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var pe in R) if (Object.prototype.hasOwnProperty.call(R, pe)) { var oe = ne ? Object.getOwnPropertyDescriptor(R, pe) : null; oe && (oe.get || oe.set) ? Object.defineProperty(H, pe, oe) : H[pe] = R[pe]; } - return H.default = R, U && U.set(R, H), H; + return H.default = R, F && F.set(R, H), H; })(f(3514)); function m() { if (typeof WeakMap != "function") return null; @@ -2000,69 +2074,69 @@ function Bu() { return R; }, R; } - function y(R, U) { + function b(R, F) { var H = Object.keys(R); if (Object.getOwnPropertySymbols) { var ne = Object.getOwnPropertySymbols(R); - U && (ne = ne.filter(function(pe) { + F && (ne = ne.filter(function(pe) { return Object.getOwnPropertyDescriptor(R, pe).enumerable; })), H.push.apply(H, ne); } return H; } function v(R) { - for (var U = 1; U < arguments.length; U++) { - var H = arguments[U] != null ? arguments[U] : {}; - U % 2 ? y(Object(H), !0).forEach(function(ne) { + for (var F = 1; F < arguments.length; F++) { + var H = arguments[F] != null ? arguments[F] : {}; + F % 2 ? b(Object(H), !0).forEach(function(ne) { N(R, ne, H[ne]); - }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(R, Object.getOwnPropertyDescriptors(H)) : y(Object(H)).forEach(function(ne) { + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(R, Object.getOwnPropertyDescriptors(H)) : b(Object(H)).forEach(function(ne) { Object.defineProperty(R, ne, Object.getOwnPropertyDescriptor(H, ne)); }); } return R; } - function N(R, U, H) { - return U in R ? Object.defineProperty(R, U, { value: H, enumerable: !0, configurable: !0, writable: !0 }) : R[U] = H, R; + function N(R, F, H) { + return F in R ? Object.defineProperty(R, F, { value: H, enumerable: !0, configurable: !0, writable: !0 }) : R[F] = H, R; } var I = ""; - function D(R, U) { + function D(R, F) { return I || (I = (0, d.findInArray)(["matches", "webkitMatchesSelector", "mozMatchesSelector", "msMatchesSelector", "oMatchesSelector"], function(H) { return (0, d.isFunction)(R[H]); - })), !!(0, d.isFunction)(R[I]) && R[I](U); + })), !!(0, d.isFunction)(R[I]) && R[I](F); } - function L(R, U, H) { + function L(R, F, H) { var ne = R.x, pe = R.y, oe = "translate(".concat(ne).concat(H, ",").concat(pe).concat(H, ")"); - if (U) { - var fe = "".concat(typeof U.x == "string" ? U.x : U.x + H), ge = "".concat(typeof U.y == "string" ? U.y : U.y + H); + if (F) { + var fe = "".concat(typeof F.x == "string" ? F.x : F.x + H), ge = "".concat(typeof F.y == "string" ? F.y : F.y + H); oe = "translate(".concat(fe, ", ").concat(ge, ")") + oe; } return oe; } - function se(R, U) { - R.classList ? R.classList.add(U) : R.className.match(new RegExp("(?:^|\\s)".concat(U, "(?!\\S)"))) || (R.className += " ".concat(U)); + function se(R, F) { + R.classList ? R.classList.add(F) : R.className.match(new RegExp("(?:^|\\s)".concat(F, "(?!\\S)"))) || (R.className += " ".concat(F)); } - function ee(R, U) { - R.classList ? R.classList.remove(U) : R.className = R.className.replace(new RegExp("(?:^|\\s)".concat(U, "(?!\\S)"), "g"), ""); + function ee(R, F) { + R.classList ? R.classList.remove(F) : R.className = R.className.replace(new RegExp("(?:^|\\s)".concat(F, "(?!\\S)"), "g"), ""); } }, 1099: (i, u) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.stringifyPath = u.quoteKey = u.isValidVariableName = u.IS_VALID_IDENTIFIER = u.quoteString = void 0; const f = /[\\\'\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, k = /* @__PURE__ */ new Map([["\b", "\\b"], [" ", "\\t"], [` `, "\\n"], ["\f", "\\f"], ["\r", "\\r"], ["'", "\\'"], ['"', '\\"'], ["\\", "\\\\"]]); - function d(y) { - return k.get(y) || `\\u${`0000${y.charCodeAt(0).toString(16)}`.slice(-4)}`; + function d(b) { + return k.get(b) || `\\u${`0000${b.charCodeAt(0).toString(16)}`.slice(-4)}`; } - u.quoteString = function(y) { - return `'${y.replace(f, d)}'`; + u.quoteString = function(b) { + return `'${b.replace(f, d)}'`; }; const C = new Set("break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield".split(" ")); - function m(y) { - return typeof y == "string" && !C.has(y) && u.IS_VALID_IDENTIFIER.test(y); + function m(b) { + return typeof b == "string" && !C.has(b) && u.IS_VALID_IDENTIFIER.test(b); } - u.IS_VALID_IDENTIFIER = /^[A-Za-z_$][A-Za-z0-9_$]*$/, u.isValidVariableName = m, u.quoteKey = function(y, v) { - return m(y) ? y : v(y); - }, u.stringifyPath = function(y, v) { + u.IS_VALID_IDENTIFIER = /^[A-Za-z_$][A-Za-z0-9_$]*$/, u.isValidVariableName = m, u.quoteKey = function(b, v) { + return m(b) ? b : v(b); + }, u.stringifyPath = function(b, v) { let N = ""; - for (const I of y) m(I) ? N += `.${I}` : N += `[${v(I)}]`; + for (const I of b) m(I) ? N += `.${I}` : N += `[${v(I)}]`; return N; }; }, 1197: (i, u, f) => { @@ -2077,30 +2151,30 @@ function Bu() { k(d, C), i.exports = d.locals || {}; }, 1345: (i, u, f) => { function k() { - var y = this.constructor.getDerivedStateFromProps(this.props, this.state); - y != null && this.setState(y); + var b = this.constructor.getDerivedStateFromProps(this.props, this.state); + b != null && this.setState(b); } - function d(y) { + function d(b) { this.setState((function(v) { - var N = this.constructor.getDerivedStateFromProps(y, v); + var N = this.constructor.getDerivedStateFromProps(b, v); return N ?? null; }).bind(this)); } - function C(y, v) { + function C(b, v) { try { var N = this.props, I = this.state; - this.props = y, this.state = v, this.__reactInternalSnapshotFlag = !0, this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(N, I); + this.props = b, this.state = v, this.__reactInternalSnapshotFlag = !0, this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(N, I); } finally { this.props = N, this.state = I; } } - function m(y) { - var v = y.prototype; + function m(b) { + var v = b.prototype; if (!v || !v.isReactComponent) throw new Error("Can only polyfill class components"); - if (typeof y.getDerivedStateFromProps != "function" && typeof v.getSnapshotBeforeUpdate != "function") return y; + if (typeof b.getDerivedStateFromProps != "function" && typeof v.getSnapshotBeforeUpdate != "function") return b; var N = null, I = null, D = null; if (typeof v.componentWillMount == "function" ? N = "componentWillMount" : typeof v.UNSAFE_componentWillMount == "function" && (N = "UNSAFE_componentWillMount"), typeof v.componentWillReceiveProps == "function" ? I = "componentWillReceiveProps" : typeof v.UNSAFE_componentWillReceiveProps == "function" && (I = "UNSAFE_componentWillReceiveProps"), typeof v.componentWillUpdate == "function" ? D = "componentWillUpdate" : typeof v.UNSAFE_componentWillUpdate == "function" && (D = "UNSAFE_componentWillUpdate"), N !== null || I !== null || D !== null) { - var L = y.displayName || y.name, se = typeof y.getDerivedStateFromProps == "function" ? "getDerivedStateFromProps()" : "getSnapshotBeforeUpdate()"; + var L = b.displayName || b.name, se = typeof b.getDerivedStateFromProps == "function" ? "getDerivedStateFromProps()" : "getSnapshotBeforeUpdate()"; throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs. ` + L + " uses " + se + " but also contains the following legacy lifecycles:" + (N !== null ? ` @@ -2111,16 +2185,16 @@ function Bu() { The above lifecycles should be removed. Learn more about this warning here: https://fb.me/react-async-component-lifecycle-hooks`); } - if (typeof y.getDerivedStateFromProps == "function" && (v.componentWillMount = k, v.componentWillReceiveProps = d), typeof v.getSnapshotBeforeUpdate == "function") { + if (typeof b.getDerivedStateFromProps == "function" && (v.componentWillMount = k, v.componentWillReceiveProps = d), typeof v.getSnapshotBeforeUpdate == "function") { if (typeof v.componentDidUpdate != "function") throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype"); v.componentWillUpdate = C; var ee = v.componentDidUpdate; - v.componentDidUpdate = function(R, U, H) { + v.componentDidUpdate = function(R, F, H) { var ne = this.__reactInternalSnapshotFlag ? this.__reactInternalSnapshot : H; - ee.call(this, R, U, ne); + ee.call(this, R, F, ne); }; } - return y; + return b; } f.r(u), f.d(u, { polyfill: () => m }), k.__suppressDeprecationWarning = !0, d.__suppressDeprecationWarning = !0, C.__suppressDeprecationWarning = !0; }, 1720: (i, u, f) => { @@ -2134,14 +2208,14 @@ https://fb.me/react-async-component-lifecycle-hooks`); }, d = /* @__PURE__ */ (function() { function S(j, A) { for (var ae = 0; ae < A.length; ae++) { - var G = A[ae]; - G.enumerable = G.enumerable || !1, G.configurable = !0, "value" in G && (G.writable = !0), Object.defineProperty(j, G.key, G); + var Z = A[ae]; + Z.enumerable = Z.enumerable || !1, Z.configurable = !0, "value" in Z && (Z.writable = !0), Object.defineProperty(j, Z.key, Z); } } return function(j, A, ae) { return A && S(j.prototype, A), ae && S(j, ae), j; }; - })(), C = f(6540), m = ee(C), y = ee(f(961)), v = ee(f(5556)), N = ee(f(9090)), I = (function(S) { + })(), C = f(6540), m = ee(C), b = ee(f(961)), v = ee(f(5556)), N = ee(f(9090)), I = (function(S) { if (S && S.__esModule) return S; var j = {}; if (S != null) for (var A in S) Object.prototype.hasOwnProperty.call(S, A) && (j[A] = S[A]); @@ -2154,31 +2228,31 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (!S) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return !j || typeof j != "object" && typeof j != "function" ? S : j; } - var U = u.portalClassName = "ReactModalPortal", H = u.bodyOpenClassName = "ReactModal__Body--open", ne = D.canUseDOM && y.default.createPortal !== void 0, pe = function(S) { + var F = u.portalClassName = "ReactModalPortal", H = u.bodyOpenClassName = "ReactModal__Body--open", ne = D.canUseDOM && b.default.createPortal !== void 0, pe = function(S) { return document.createElement(S); }, oe = function() { - return ne ? y.default.createPortal : y.default.unstable_renderSubtreeIntoContainer; + return ne ? b.default.createPortal : b.default.unstable_renderSubtreeIntoContainer; }; function fe(S) { return S(); } var ge = (function(S) { function j() { - var A, ae, G; - (function(X, le) { - if (!(X instanceof le)) throw new TypeError("Cannot call a class as a function"); + var A, ae, Z; + (function(G, le) { + if (!(G instanceof le)) throw new TypeError("Cannot call a class as a function"); })(this, j); - for (var Ee = arguments.length, J = Array(Ee), F = 0; F < Ee; F++) J[F] = arguments[F]; - return ae = G = R(this, (A = j.__proto__ || Object.getPrototypeOf(j)).call.apply(A, [this].concat(J))), G.removePortal = function() { - !ne && y.default.unmountComponentAtNode(G.node); - var X = fe(G.props.parentSelector); - X && X.contains(G.node) ? X.removeChild(G.node) : console.warn('React-Modal: "parentSelector" prop did not returned any DOM element. Make sure that the parent element is unmounted to avoid any memory leaks.'); - }, G.portalRef = function(X) { - G.portal = X; - }, G.renderPortal = function(X) { - var le = oe()(G, m.default.createElement(N.default, k({ defaultStyles: j.defaultStyles }, X)), G.node); - G.portalRef(le); - }, R(G, ae); + for (var Ee = arguments.length, J = Array(Ee), U = 0; U < Ee; U++) J[U] = arguments[U]; + return ae = Z = R(this, (A = j.__proto__ || Object.getPrototypeOf(j)).call.apply(A, [this].concat(J))), Z.removePortal = function() { + !ne && b.default.unmountComponentAtNode(Z.node); + var G = fe(Z.props.parentSelector); + G && G.contains(Z.node) ? G.removeChild(Z.node) : console.warn('React-Modal: "parentSelector" prop did not returned any DOM element. Make sure that the parent element is unmounted to avoid any memory leaks.'); + }, Z.portalRef = function(G) { + Z.portal = G; + }, Z.renderPortal = function(G) { + var le = oe()(Z, m.default.createElement(N.default, k({ defaultStyles: j.defaultStyles }, G)), Z.node); + Z.portalRef(le); + }, R(Z, ae); } return (function(A, ae) { if (typeof ae != "function" && ae !== null) throw new TypeError("Super expression must either be null or a function, not " + typeof ae); @@ -2187,17 +2261,17 @@ https://fb.me/react-async-component-lifecycle-hooks`); D.canUseDOM && (ne || (this.node = pe("div")), this.node.className = this.props.portalClassName, fe(this.props.parentSelector).appendChild(this.node), !ne && this.renderPortal(this.props)); } }, { key: "getSnapshotBeforeUpdate", value: function(A) { return { prevParent: fe(A.parentSelector), nextParent: fe(this.props.parentSelector) }; - } }, { key: "componentDidUpdate", value: function(A, ae, G) { + } }, { key: "componentDidUpdate", value: function(A, ae, Z) { if (D.canUseDOM) { - var Ee = this.props, J = Ee.isOpen, F = Ee.portalClassName; - A.portalClassName !== F && (this.node.className = F); - var X = G.prevParent, le = G.nextParent; - le !== X && (X.removeChild(this.node), le.appendChild(this.node)), (A.isOpen || J) && !ne && this.renderPortal(this.props); + var Ee = this.props, J = Ee.isOpen, U = Ee.portalClassName; + A.portalClassName !== U && (this.node.className = U); + var G = Z.prevParent, le = Z.nextParent; + le !== G && (G.removeChild(this.node), le.appendChild(this.node)), (A.isOpen || J) && !ne && this.renderPortal(this.props); } } }, { key: "componentWillUnmount", value: function() { if (D.canUseDOM && this.node && this.portal) { - var A = this.portal.state, ae = Date.now(), G = A.isOpen && this.props.closeTimeoutMS && (A.closesAt || ae + this.props.closeTimeoutMS); - G ? (A.beforeClose || this.portal.closeWithTimeout(), setTimeout(this.removePortal, G - ae)) : this.removePortal(); + var A = this.portal.state, ae = Date.now(), Z = A.isOpen && this.props.closeTimeoutMS && (A.closesAt || ae + this.props.closeTimeoutMS); + Z ? (A.beforeClose || this.portal.closeWithTimeout(), setTimeout(this.removePortal, Z - ae)) : this.removePortal(); } } }, { key: "render", value: function() { return D.canUseDOM && ne ? (!this.node && ne && (this.node = pe("div")), oe()(m.default.createElement(N.default, k({ ref: this.portalRef, defaultStyles: j.defaultStyles }, this.props)), this.node)) : null; @@ -2205,7 +2279,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); I.setElement(A); } }]), j; })(C.Component); - ge.propTypes = { isOpen: v.default.bool.isRequired, style: v.default.shape({ content: v.default.object, overlay: v.default.object }), portalClassName: v.default.string, bodyOpenClassName: v.default.string, htmlOpenClassName: v.default.string, className: v.default.oneOfType([v.default.string, v.default.shape({ base: v.default.string.isRequired, afterOpen: v.default.string.isRequired, beforeClose: v.default.string.isRequired })]), overlayClassName: v.default.oneOfType([v.default.string, v.default.shape({ base: v.default.string.isRequired, afterOpen: v.default.string.isRequired, beforeClose: v.default.string.isRequired })]), appElement: v.default.oneOfType([v.default.instanceOf(L.default), v.default.instanceOf(D.SafeHTMLCollection), v.default.instanceOf(D.SafeNodeList), v.default.arrayOf(v.default.instanceOf(L.default))]), onAfterOpen: v.default.func, onRequestClose: v.default.func, closeTimeoutMS: v.default.number, ariaHideApp: v.default.bool, shouldFocusAfterRender: v.default.bool, shouldCloseOnOverlayClick: v.default.bool, shouldReturnFocusAfterClose: v.default.bool, preventScroll: v.default.bool, parentSelector: v.default.func, aria: v.default.object, data: v.default.object, role: v.default.string, contentLabel: v.default.string, shouldCloseOnEsc: v.default.bool, overlayRef: v.default.func, contentRef: v.default.func, id: v.default.string, overlayElement: v.default.func, contentElement: v.default.func }, ge.defaultProps = { isOpen: !1, portalClassName: U, bodyOpenClassName: H, role: "dialog", ariaHideApp: !0, closeTimeoutMS: 0, shouldFocusAfterRender: !0, shouldCloseOnEsc: !0, shouldCloseOnOverlayClick: !0, shouldReturnFocusAfterClose: !0, preventScroll: !1, parentSelector: function() { + ge.propTypes = { isOpen: v.default.bool.isRequired, style: v.default.shape({ content: v.default.object, overlay: v.default.object }), portalClassName: v.default.string, bodyOpenClassName: v.default.string, htmlOpenClassName: v.default.string, className: v.default.oneOfType([v.default.string, v.default.shape({ base: v.default.string.isRequired, afterOpen: v.default.string.isRequired, beforeClose: v.default.string.isRequired })]), overlayClassName: v.default.oneOfType([v.default.string, v.default.shape({ base: v.default.string.isRequired, afterOpen: v.default.string.isRequired, beforeClose: v.default.string.isRequired })]), appElement: v.default.oneOfType([v.default.instanceOf(L.default), v.default.instanceOf(D.SafeHTMLCollection), v.default.instanceOf(D.SafeNodeList), v.default.arrayOf(v.default.instanceOf(L.default))]), onAfterOpen: v.default.func, onRequestClose: v.default.func, closeTimeoutMS: v.default.number, ariaHideApp: v.default.bool, shouldFocusAfterRender: v.default.bool, shouldCloseOnOverlayClick: v.default.bool, shouldReturnFocusAfterClose: v.default.bool, preventScroll: v.default.bool, parentSelector: v.default.func, aria: v.default.object, data: v.default.object, role: v.default.string, contentLabel: v.default.string, shouldCloseOnEsc: v.default.bool, overlayRef: v.default.func, contentRef: v.default.func, id: v.default.string, overlayElement: v.default.func, contentElement: v.default.func }, ge.defaultProps = { isOpen: !1, portalClassName: F, bodyOpenClassName: H, role: "dialog", ariaHideApp: !0, closeTimeoutMS: 0, shouldFocusAfterRender: !0, shouldCloseOnEsc: !0, shouldCloseOnOverlayClick: !0, shouldReturnFocusAfterClose: !0, preventScroll: !1, parentSelector: function() { return document.body; }, overlayElement: function(S, j) { return m.default.createElement("div", S, j); @@ -2213,11 +2287,11 @@ https://fb.me/react-async-component-lifecycle-hooks`); return m.default.createElement("div", S, j); } }, ge.defaultStyles = { overlay: { position: "fixed", top: 0, left: 0, right: 0, bottom: 0, backgroundColor: "rgba(255, 255, 255, 0.75)" }, content: { position: "absolute", top: "40px", left: "40px", right: "40px", bottom: "40px", border: "1px solid #ccc", background: "#fff", overflow: "auto", WebkitOverflowScrolling: "touch", borderRadius: "4px", outline: "none", padding: "20px" } }, (0, se.polyfill)(ge), u.default = ge; }, 1726: (i, u, f) => { - Object.defineProperty(u, "__esModule", { value: !0 }), u.getBoundPosition = function(m, y, v) { - if (!m.props.bounds) return [y, v]; + Object.defineProperty(u, "__esModule", { value: !0 }), u.getBoundPosition = function(m, b, v) { + if (!m.props.bounds) return [b, v]; var N = m.props.bounds; - N = typeof N == "string" ? N : (function(U) { - return { left: U.left, top: U.top, right: U.right, bottom: U.bottom }; + N = typeof N == "string" ? N : (function(F) { + return { left: F.left, top: F.top, right: F.right, bottom: F.bottom }; })(N); var I = C(m); if (typeof N == "string") { @@ -2226,38 +2300,38 @@ https://fb.me/react-async-component-lifecycle-hooks`); var ee = se.getComputedStyle(I), R = se.getComputedStyle(D); N = { left: -I.offsetLeft + (0, k.int)(R.paddingLeft) + (0, k.int)(ee.marginLeft), top: -I.offsetTop + (0, k.int)(R.paddingTop) + (0, k.int)(ee.marginTop), right: (0, d.innerWidth)(D) - (0, d.outerWidth)(I) - I.offsetLeft + (0, k.int)(R.paddingRight) - (0, k.int)(ee.marginRight), bottom: (0, d.innerHeight)(D) - (0, d.outerHeight)(I) - I.offsetTop + (0, k.int)(R.paddingBottom) - (0, k.int)(ee.marginBottom) }; } - return (0, k.isNum)(N.right) && (y = Math.min(y, N.right)), (0, k.isNum)(N.bottom) && (v = Math.min(v, N.bottom)), (0, k.isNum)(N.left) && (y = Math.max(y, N.left)), (0, k.isNum)(N.top) && (v = Math.max(v, N.top)), [y, v]; - }, u.snapToGrid = function(m, y, v) { - var N = Math.round(y / m[0]) * m[0], I = Math.round(v / m[1]) * m[1]; + return (0, k.isNum)(N.right) && (b = Math.min(b, N.right)), (0, k.isNum)(N.bottom) && (v = Math.min(v, N.bottom)), (0, k.isNum)(N.left) && (b = Math.max(b, N.left)), (0, k.isNum)(N.top) && (v = Math.max(v, N.top)), [b, v]; + }, u.snapToGrid = function(m, b, v) { + var N = Math.round(b / m[0]) * m[0], I = Math.round(v / m[1]) * m[1]; return [N, I]; }, u.canDragX = function(m) { return m.props.axis === "both" || m.props.axis === "x"; }, u.canDragY = function(m) { return m.props.axis === "both" || m.props.axis === "y"; - }, u.getControlPosition = function(m, y, v) { - var N = typeof y == "number" ? (0, d.getTouch)(m, y) : null; - if (typeof y == "number" && !N) return null; + }, u.getControlPosition = function(m, b, v) { + var N = typeof b == "number" ? (0, d.getTouch)(m, b) : null; + if (typeof b == "number" && !N) return null; var I = C(v), D = v.props.offsetParent || I.offsetParent || I.ownerDocument.body; return (0, d.offsetXYFromParent)(N || m, D, v.props.scale); - }, u.createCoreData = function(m, y, v) { + }, u.createCoreData = function(m, b, v) { var N = m.state, I = !(0, k.isNum)(N.lastX), D = C(m); - return I ? { node: D, deltaX: 0, deltaY: 0, lastX: y, lastY: v, x: y, y: v } : { node: D, deltaX: y - N.lastX, deltaY: v - N.lastY, lastX: N.lastX, lastY: N.lastY, x: y, y: v }; - }, u.createDraggableData = function(m, y) { + return I ? { node: D, deltaX: 0, deltaY: 0, lastX: b, lastY: v, x: b, y: v } : { node: D, deltaX: b - N.lastX, deltaY: v - N.lastY, lastX: N.lastX, lastY: N.lastY, x: b, y: v }; + }, u.createDraggableData = function(m, b) { var v = m.props.scale; - return { node: y.node, x: m.state.x + y.deltaX / v, y: m.state.y + y.deltaY / v, deltaX: y.deltaX / v, deltaY: y.deltaY / v, lastX: m.state.x, lastY: m.state.y }; + return { node: b.node, x: m.state.x + b.deltaX / v, y: m.state.y + b.deltaY / v, deltaX: b.deltaX / v, deltaY: b.deltaY / v, lastX: m.state.x, lastY: m.state.y }; }; var k = f(7056), d = f(1089); function C(m) { - var y = m.findDOMNode(); - if (!y) throw new Error(": Unmounted during event!"); - return y; + var b = m.findDOMNode(); + if (!b) throw new Error(": Unmounted during event!"); + return b; } }, 2411: (i, u) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.default = function v(N) { var I = [].slice.call(N.querySelectorAll("*"), 0).reduce(function(D, L) { return D.concat(L.shadowRoot ? v(L.shadowRoot) : [L]); }, []); - return I.filter(y); + return I.filter(b); }; var f = "none", k = "contents", d = /^(input|select|textarea|button|object|iframe)$/; function C(v) { @@ -2282,7 +2356,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return !0; })(v); } - function y(v) { + function b(v) { var N = v.getAttribute("tabindex"); N === null && (N = void 0); var I = isNaN(N); @@ -2303,7 +2377,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return "Minified React error #" + e + "; visit " + t + " for the full message or use the non-minified dev environment for full errors and additional helpful warnings."; } if (!k) throw Error(m(227)); - function y(e, t, n, r, a, p, h, w, W) { + function b(e, t, n, r, a, p, h, w, W) { var V = Array.prototype.slice.call(arguments, 3); try { t.apply(n, V); @@ -2315,12 +2389,12 @@ https://fb.me/react-async-component-lifecycle-hooks`); v = !0, N = e; } }; function se(e, t, n, r, a, p, h, w, W) { - v = !1, N = null, y.apply(L, arguments); + v = !1, N = null, b.apply(L, arguments); } - var ee = null, R = null, U = null; + var ee = null, R = null, F = null; function H(e, t, n) { var r = e.type || "unknown-event"; - e.currentTarget = U(n), (function(a, p, h, w, W, V, ce, Re, Ve) { + e.currentTarget = F(n), (function(a, p, h, w, W, V, ce, Re, Ve) { if (se.apply(this, arguments), v) { if (!v) throw Error(m(198)); var ot = N; @@ -2365,8 +2439,8 @@ https://fb.me/react-async-component-lifecycle-hooks`); } n && oe(); } - var G = !(typeof window > "u" || window.document === void 0 || window.document.createElement === void 0), Ee = null, J = null, F = null; - function X(e) { + var Z = !(typeof window > "u" || window.document === void 0 || window.document.createElement === void 0), Ee = null, J = null, U = null; + function G(e) { if (e = R(e)) { if (typeof Ee != "function") throw Error(m(280)); var t = e.stateNode; @@ -2374,12 +2448,12 @@ https://fb.me/react-async-component-lifecycle-hooks`); } } function le(e) { - J ? F ? F.push(e) : F = [e] : J = e; + J ? U ? U.push(e) : U = [e] : J = e; } function me() { if (J) { - var e = J, t = F; - if (F = J = null, X(e), t) for (e = 0; e < t.length; e++) X(t[e]); + var e = J, t = U; + if (U = J = null, G(e), t) for (e = 0; e < t.length; e++) G(t[e]); } } function ke(e, t) { @@ -2388,13 +2462,13 @@ https://fb.me/react-async-component-lifecycle-hooks`); function Ne(e, t, n, r, a) { return e(t, n, r, a); } - function Fe() { + function Ue() { } var Ae = ke, Le = !1, Ke = !1; function Je() { - J === null && F === null || (Fe(), me()); + J === null && U === null || (Ue(), me()); } - function be(e, t, n) { + function ye(e, t, n) { if (Ke) return e(t, n); Ke = !0; try { @@ -2479,7 +2553,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); })(t) && (n === null ? e.removeAttribute(t) : e.setAttribute(t, "" + n)) : a.mustUseProperty ? e[a.propertyName] = n === null ? a.type !== 3 && "" : n : (t = a.attributeName, r = a.attributeNamespace, n === null ? e.removeAttribute(t) : (n = (a = a.type) === 3 || a === 4 && n === !0 ? "" : "" + n, r ? e.setAttributeNS(r, t, n) : e.setAttribute(t, n)))); } et.hasOwnProperty("ReactCurrentDispatcher") || (et.ReactCurrentDispatcher = { current: null }), et.hasOwnProperty("ReactCurrentBatchConfig") || (et.ReactCurrentBatchConfig = { suspense: null }); - var ko = /^(.*)[\\\/]/, Dt = typeof Symbol == "function" && Symbol.for, Gt = Dt ? Symbol.for("react.element") : 60103, On = Dt ? Symbol.for("react.portal") : 60106, Nn = Dt ? Symbol.for("react.fragment") : 60107, wo = Dt ? Symbol.for("react.strict_mode") : 60108, Bn = Dt ? Symbol.for("react.profiler") : 60114, $n = Dt ? Symbol.for("react.provider") : 60109, an = Dt ? Symbol.for("react.context") : 60110, pn = Dt ? Symbol.for("react.concurrent_mode") : 60111, sr = Dt ? Symbol.for("react.forward_ref") : 60112, Ht = Dt ? Symbol.for("react.suspense") : 60113, Wr = Dt ? Symbol.for("react.suspense_list") : 60120, qr = Dt ? Symbol.for("react.memo") : 60115, _o = Dt ? Symbol.for("react.lazy") : 60116, Eo = Dt ? Symbol.for("react.block") : 60121, xo = typeof Symbol == "function" && Symbol.iterator; + var ko = /^(.*)[\\\/]/, Dt = typeof Symbol == "function" && Symbol.for, Gt = Dt ? Symbol.for("react.element") : 60103, On = Dt ? Symbol.for("react.portal") : 60106, Nn = Dt ? Symbol.for("react.fragment") : 60107, wo = Dt ? Symbol.for("react.strict_mode") : 60108, $n = Dt ? Symbol.for("react.profiler") : 60114, Bn = Dt ? Symbol.for("react.provider") : 60109, an = Dt ? Symbol.for("react.context") : 60110, pn = Dt ? Symbol.for("react.concurrent_mode") : 60111, sr = Dt ? Symbol.for("react.forward_ref") : 60112, Ht = Dt ? Symbol.for("react.suspense") : 60113, Wr = Dt ? Symbol.for("react.suspense_list") : 60120, qr = Dt ? Symbol.for("react.memo") : 60115, _o = Dt ? Symbol.for("react.lazy") : 60116, Eo = Dt ? Symbol.for("react.block") : 60121, xo = typeof Symbol == "function" && Symbol.iterator; function Wn(e) { return e === null || typeof e != "object" ? null : typeof (e = xo && e[xo] || e["@@iterator"]) == "function" ? e : null; } @@ -2492,7 +2566,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return "Fragment"; case On: return "Portal"; - case Bn: + case $n: return "Profiler"; case wo: return "StrictMode"; @@ -2504,7 +2578,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (typeof e == "object") switch (e.$$typeof) { case an: return "Context.Consumer"; - case $n: + case Bn: return "Context.Provider"; case sr: var t = e.render; @@ -2658,7 +2732,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); var t = e.textContent; t === e._wrapperState.initialValue && t !== "" && t !== null && (e.value = t); } - var hn = "http://www.w3.org/1999/xhtml", yi = "http://www.w3.org/2000/svg"; + var hn = "http://www.w3.org/1999/xhtml", bi = "http://www.w3.org/2000/svg"; function mn(e) { switch (e) { case "svg": @@ -2673,7 +2747,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return e == null || e === "http://www.w3.org/1999/xhtml" ? mn(t) : e === "http://www.w3.org/2000/svg" && t === "foreignObject" ? "http://www.w3.org/1999/xhtml" : e; } var gn, ct, Dr = (ct = function(e, t) { - if (e.namespaceURI !== yi || "innerHTML" in e) e.innerHTML = t; + if (e.namespaceURI !== bi || "innerHTML" in e) e.innerHTML = t; else { for ((gn = gn || document.createElement("div")).innerHTML = "" + t.valueOf().toString() + "", t = gn.firstChild; e.firstChild; ) e.removeChild(e.firstChild); for (; t.firstChild; ) e.appendChild(t.firstChild); @@ -2702,8 +2776,8 @@ https://fb.me/react-async-component-lifecycle-hooks`); for (t in n) if (n.hasOwnProperty(t) && t in Ir) return Rn[e] = n[t]; return e; } - G && (Ir = document.createElement("div").style, "AnimationEvent" in window || (delete Qn.animationend.animation, delete Qn.animationiteration.animation, delete Qn.animationstart.animation), "TransitionEvent" in window || delete Qn.transitionend.transition); - var M = Rr("animationend"), Q = Rr("animationiteration"), ye = Rr("animationstart"), De = Rr("transitionend"), tt = "abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "), He = new (typeof WeakMap == "function" ? WeakMap : Map)(); + Z && (Ir = document.createElement("div").style, "AnimationEvent" in window || (delete Qn.animationend.animation, delete Qn.animationiteration.animation, delete Qn.animationstart.animation), "TransitionEvent" in window || delete Qn.transitionend.transition); + var M = Rr("animationend"), Q = Rr("animationiteration"), be = Rr("animationstart"), De = Rr("transitionend"), tt = "abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "), He = new (typeof WeakMap == "function" ? WeakMap : Map)(); function Ge(e) { var t = He.get(e); return t === void 0 && (t = /* @__PURE__ */ new Map(), He.set(e, t)), t; @@ -2809,8 +2883,8 @@ https://fb.me/react-async-component-lifecycle-hooks`); function jt(e, t, n) { Array.isArray(e) ? e.forEach(t, n) : e && t.call(n, e); } - var bt = null; - function yt(e) { + var yt = null; + function bt(e) { if (e) { var t = e._dispatchListeners, n = e._dispatchInstances; if (Array.isArray(t)) for (var r = 0; r < t.length && !e.isPropagationStopped(); r++) H(e, t[r], n[r]); @@ -2818,9 +2892,9 @@ https://fb.me/react-async-component-lifecycle-hooks`); e._dispatchListeners = null, e._dispatchInstances = null, e.isPersistent() || e.constructor.release(e); } } - function bn(e) { - if (e !== null && (bt = kt(bt, e)), e = bt, bt = null, e) { - if (jt(e, yt), bt) throw Error(m(95)); + function yn(e) { + if (e !== null && (yt = kt(yt, e)), e = yt, yt = null, e) { + if (jt(e, bt), yt) throw Error(m(95)); if (I) throw e = D, I = !1, D = null, e; } } @@ -2828,17 +2902,17 @@ https://fb.me/react-async-component-lifecycle-hooks`); return (e = e.target || e.srcElement || window).correspondingUseElement && (e = e.correspondingUseElement), e.nodeType === 3 ? e.parentNode : e; } function Mn(e) { - if (!G) return !1; + if (!Z) return !1; var t = (e = "on" + e) in document; return t || ((t = document.createElement("div")).setAttribute(e, "return;"), t = typeof t[e] == "function"), t; } - var yn = []; + var bn = []; function Xr(e) { - e.topLevelType = null, e.nativeEvent = null, e.targetInst = null, e.ancestors.length = 0, 10 > yn.length && yn.push(e); + e.topLevelType = null, e.nativeEvent = null, e.targetInst = null, e.ancestors.length = 0, 10 > bn.length && bn.push(e); } function To(e, t, n, r) { - if (yn.length) { - var a = yn.pop(); + if (bn.length) { + var a = bn.pop(); return a.topLevelType = e, a.eventSystemFlags = r, a.nativeEvent = t, a.targetInst = n, a; } return { topLevelType: e, eventSystemFlags: r, nativeEvent: t, targetInst: n, ancestors: [] }; @@ -2869,7 +2943,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); var V = ge[W]; V && (V = V.extractEvents(r, t, p, a, h)) && (w = kt(w, V)); } - bn(w); + yn(w); } } function nt(e, t, n) { @@ -2981,7 +3055,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); for (wt !== null && Zr(wt, e), Tt !== null && Zr(Tt, e), Lt !== null && Zr(Lt, e), kn.forEach(t), zn.forEach(t), n = 0; n < wn.length; n++) (r = wn[n]).blockedOn === e && (r.blockedOn = null); for (; 0 < wn.length && (n = wn[0]).blockedOn === null; ) Mr(n), n.blockedOn === null && wn.shift(); } - var oa = {}, ki = /* @__PURE__ */ new Map(), wi = /* @__PURE__ */ new Map(), is = ["abort", "abort", M, "animationEnd", Q, "animationIteration", ye, "animationStart", "canplay", "canPlay", "canplaythrough", "canPlayThrough", "durationchange", "durationChange", "emptied", "emptied", "encrypted", "encrypted", "ended", "ended", "error", "error", "gotpointercapture", "gotPointerCapture", "load", "load", "loadeddata", "loadedData", "loadedmetadata", "loadedMetadata", "loadstart", "loadStart", "lostpointercapture", "lostPointerCapture", "playing", "playing", "progress", "progress", "seeking", "seeking", "stalled", "stalled", "suspend", "suspend", "timeupdate", "timeUpdate", De, "transitionEnd", "waiting", "waiting"]; + var oa = {}, ki = /* @__PURE__ */ new Map(), wi = /* @__PURE__ */ new Map(), is = ["abort", "abort", M, "animationEnd", Q, "animationIteration", be, "animationStart", "canplay", "canPlay", "canplaythrough", "canPlayThrough", "durationchange", "durationChange", "emptied", "emptied", "encrypted", "encrypted", "ended", "ended", "error", "error", "gotpointercapture", "gotPointerCapture", "load", "load", "loadeddata", "loadedData", "loadedmetadata", "loadedMetadata", "loadstart", "loadStart", "lostpointercapture", "lostPointerCapture", "playing", "playing", "progress", "progress", "seeking", "seeking", "stalled", "stalled", "suspend", "suspend", "timeupdate", "timeUpdate", De, "transitionEnd", "waiting", "waiting"]; function _i(e, t) { for (var n = 0; n < e.length; n += 2) { var r = e[n], a = e[n + 1], p = "on" + (a[0].toUpperCase() + a.slice(1)); @@ -3009,7 +3083,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); n ? e.addEventListener(t, r, !0) : e.addEventListener(t, r, !1); } function ls(e, t, n, r) { - Le || Fe(); + Le || Ue(); var a = Po, p = Le; Le = !0; try { @@ -3045,7 +3119,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); })(a, e, t, n, r)) { Xn(e, r), e = To(e, r, null, t); try { - be(Oo, e); + ye(Oo, e); } finally { Xr(e); } @@ -3069,7 +3143,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } e = To(e, r, n, t); try { - be(Oo, e); + ye(Oo, e); } finally { Xr(e); } @@ -3176,7 +3250,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); var t = e && e.nodeName && e.nodeName.toLowerCase(); return t && (t === "input" && (e.type === "text" || e.type === "search" || e.type === "tel" || e.type === "url" || e.type === "password") || t === "textarea" || e.contentEditable === "true"); } - var eo = "$", to = "/$", Ni = "$?", br = "$!", Do = null, Et = null; + var eo = "$", to = "/$", Ni = "$?", yr = "$!", Do = null, Et = null; function Yt(e, t) { switch (e) { case "button": @@ -3203,7 +3277,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); for (var t = 0; e; ) { if (e.nodeType === 8) { var n = e.data; - if (n === eo || n === br || n === Ni) { + if (n === eo || n === yr || n === Ni) { if (t === 0) return e; t--; } else n === to && t++; @@ -3212,7 +3286,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } return null; } - var yr = Math.random().toString(36).slice(2), vr = "__reactInternalInstance$" + yr, ri = "__reactEventHandlers$" + yr, Io = "__reactContainere$" + yr; + var br = Math.random().toString(36).slice(2), vr = "__reactInternalInstance$" + br, ri = "__reactEventHandlers$" + br, Io = "__reactContainere$" + br; function no(e) { var t = e[vr]; if (t) return t; @@ -3287,7 +3361,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); function zi(e) { e && e.dispatchConfig.registrationName && er(e._targetInst, null, e); } - function Bt(e) { + function $t(e) { jt(e, Mi); } var tr = null, Ai = null, ii = null; @@ -3351,9 +3425,9 @@ https://fb.me/react-async-component-lifecycle-hooks`); var a = new t(); return d(a, n.prototype), n.prototype = a, n.prototype.constructor = n, n.Interface = d({}, r.Interface, e), n.extend = r.extend, Mo(n), n; }, Mo(Ot); - var ds = Ot.extend({ data: null }), ps = Ot.extend({ data: null }), da = [9, 13, 27, 32], ji = G && "CompositionEvent" in window, zo = null; - G && "documentMode" in document && (zo = document.documentMode); - var fs = G && "TextEvent" in window && !zo, pa = G && (!ji || zo && 8 < zo && 11 >= zo), fa = " ", nr = { beforeInput: { phasedRegistrationNames: { bubbled: "onBeforeInput", captured: "onBeforeInputCapture" }, dependencies: ["compositionend", "keypress", "textInput", "paste"] }, compositionEnd: { phasedRegistrationNames: { bubbled: "onCompositionEnd", captured: "onCompositionEndCapture" }, dependencies: "blur compositionend keydown keypress keyup mousedown".split(" ") }, compositionStart: { phasedRegistrationNames: { bubbled: "onCompositionStart", captured: "onCompositionStartCapture" }, dependencies: "blur compositionstart keydown keypress keyup mousedown".split(" ") }, compositionUpdate: { phasedRegistrationNames: { bubbled: "onCompositionUpdate", captured: "onCompositionUpdateCapture" }, dependencies: "blur compositionupdate keydown keypress keyup mousedown".split(" ") } }, ha = !1; + var ds = Ot.extend({ data: null }), ps = Ot.extend({ data: null }), da = [9, 13, 27, 32], ji = Z && "CompositionEvent" in window, zo = null; + Z && "documentMode" in document && (zo = document.documentMode); + var fs = Z && "TextEvent" in window && !zo, pa = Z && (!ji || zo && 8 < zo && 11 >= zo), fa = " ", nr = { beforeInput: { phasedRegistrationNames: { bubbled: "onBeforeInput", captured: "onBeforeInputCapture" }, dependencies: ["compositionend", "keypress", "textInput", "paste"] }, compositionEnd: { phasedRegistrationNames: { bubbled: "onCompositionEnd", captured: "onCompositionEndCapture" }, dependencies: "blur compositionend keydown keypress keyup mousedown".split(" ") }, compositionStart: { phasedRegistrationNames: { bubbled: "onCompositionStart", captured: "onCompositionStartCapture" }, dependencies: "blur compositionstart keydown keypress keyup mousedown".split(" ") }, compositionUpdate: { phasedRegistrationNames: { bubbled: "onCompositionUpdate", captured: "onCompositionUpdateCapture" }, dependencies: "blur compositionupdate keydown keypress keyup mousedown".split(" ") } }, ha = !1; function oo(e, t) { switch (e) { case "keyup": @@ -3388,7 +3462,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); p = void 0; } else io ? oo(e, n) && (p = nr.compositionEnd) : e === "keydown" && n.keyCode === 229 && (p = nr.compositionStart); - return p ? (pa && n.locale !== "ko" && (io || p !== nr.compositionStart ? p === nr.compositionEnd && io && (a = ua()) : (Ai = "value" in (tr = r) ? tr.value : tr.textContent, io = !0)), p = ds.getPooled(p, t, n, r), (a || (a = ma(n)) !== null) && (p.data = a), Bt(p), a = p) : a = null, (e = fs ? (function(h, w) { + return p ? (pa && n.locale !== "ko" && (io || p !== nr.compositionStart ? p === nr.compositionEnd && io && (a = ua()) : (Ai = "value" in (tr = r) ? tr.value : tr.textContent, io = !0)), p = ds.getPooled(p, t, n, r), (a || (a = ma(n)) !== null) && (p.data = a), $t(p), a = p) : a = null, (e = fs ? (function(h, w) { switch (h) { case "compositionend": return ma(w); @@ -3414,19 +3488,19 @@ https://fb.me/react-async-component-lifecycle-hooks`); case "compositionend": return pa && w.locale !== "ko" ? null : w.data; } - })(e, n)) ? ((t = ps.getPooled(nr.beforeInput, t, n, r)).data = e, Bt(t)) : t = null, a === null ? t : t === null ? a : [a, t]; + })(e, n)) ? ((t = ps.getPooled(nr.beforeInput, t, n, r)).data = e, $t(t)) : t = null, a === null ? t : t === null ? a : [a, t]; } }, hs = { color: !0, date: !0, datetime: !0, "datetime-local": !0, email: !0, month: !0, number: !0, password: !0, range: !0, search: !0, tel: !0, text: !0, time: !0, url: !0, week: !0 }; function ga(e) { var t = e && e.nodeName && e.nodeName.toLowerCase(); return t === "input" ? !!hs[e.type] : t === "textarea"; } - var ba = { change: { phasedRegistrationNames: { bubbled: "onChange", captured: "onChangeCapture" }, dependencies: "blur change click focus input keydown keyup selectionchange".split(" ") } }; - function ya(e, t, n) { - return (e = Ot.getPooled(ba.change, e, t, n)).type = "change", le(n), Bt(e), e; + var ya = { change: { phasedRegistrationNames: { bubbled: "onChange", captured: "onChangeCapture" }, dependencies: "blur change click focus input keydown keyup selectionchange".split(" ") } }; + function ba(e, t, n) { + return (e = Ot.getPooled(ya.change, e, t, n)).type = "change", le(n), $t(e), e; } var ao = null, Ao = null; function ms(e) { - bn(e); + yn(e); } function si(e) { if (sn(Zn(e))) return e; @@ -3439,7 +3513,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); ao && (ao.detachEvent("onpropertychange", ka), Ao = ao = null); } function ka(e) { - if (e.propertyName === "value" && si(Ao)) if (e = ya(Ao, e, ur(e)), Le) bn(e); + if (e.propertyName === "value" && si(Ao)) if (e = ba(Ao, e, ur(e)), Le) yn(e); else { Le = !0; try { @@ -3449,10 +3523,10 @@ https://fb.me/react-async-component-lifecycle-hooks`); } } } - function bs(e, t, n) { + function ys(e, t, n) { e === "focus" ? (va(), Ao = n, (ao = t).attachEvent("onpropertychange", ka)) : e === "blur" && va(); } - function ys(e) { + function bs(e) { if (e === "selectionchange" || e === "keyup" || e === "keydown") return si(Ao); } function vs(e, t) { @@ -3461,17 +3535,17 @@ https://fb.me/react-async-component-lifecycle-hooks`); function ks(e, t) { if (e === "input" || e === "change") return si(t); } - G && (Li = Mn("input") && (!document.documentMode || 9 < document.documentMode)); - var ws = { eventTypes: ba, _isInputEventSupported: Li, extractEvents: function(e, t, n, r) { + Z && (Li = Mn("input") && (!document.documentMode || 9 < document.documentMode)); + var ws = { eventTypes: ya, _isInputEventSupported: Li, extractEvents: function(e, t, n, r) { var a = t ? Zn(t) : window, p = a.nodeName && a.nodeName.toLowerCase(); if (p === "select" || p === "input" && a.type === "file") var h = gs; else if (ga(a)) if (Li) h = ks; else { - h = ys; - var w = bs; + h = bs; + var w = ys; } else (p = a.nodeName) && p.toLowerCase() === "input" && (a.type === "checkbox" || a.type === "radio") && (h = vs); - if (h && (h = h(e, t))) return ya(h, n, r); + if (h && (h = h(e, t))) return ba(h, n, r); w && w(e, a, t), e === "blur" && (e = a._wrapperState) && e.controlled && a.type === "number" && So(a, "number", a.value); } }, jo = Ot.extend({ view: null, detail: null }), _s = { Alt: "altKey", Control: "ctrlKey", Meta: "metaKey", Shift: "shiftKey" }; function Es(e) { @@ -3516,7 +3590,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } }, rr = typeof Object.is == "function" ? Object.is : function(e, t) { return e === t && (e !== 0 || 1 / e == 1 / t) || e != e && t != t; }, Ss = Object.prototype.hasOwnProperty; - function Ur(e, t) { + function Fr(e, t) { if (rr(e, t)) return !0; if (typeof e != "object" || e === null || typeof t != "object" || t === null) return !1; var n = Object.keys(e), r = Object.keys(t); @@ -3524,12 +3598,12 @@ https://fb.me/react-async-component-lifecycle-hooks`); for (r = 0; r < n.length; r++) if (!Ss.call(t, n[r]) || !rr(e[n[r]], t[n[r]])) return !1; return !0; } - var Cs = G && "documentMode" in document && 11 >= document.documentMode, Ui = { select: { phasedRegistrationNames: { bubbled: "onSelect", captured: "onSelectCapture" }, dependencies: "blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange".split(" ") } }, so = null, Fi = null, Fr = null, Vi = !1; + var Cs = Z && "documentMode" in document && 11 >= document.documentMode, Fi = { select: { phasedRegistrationNames: { bubbled: "onSelect", captured: "onSelectCapture" }, dependencies: "blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange".split(" ") } }, so = null, Ui = null, Ur = null, Vi = !1; function Sa(e, t) { var n = t.window === t ? t.document : t.nodeType === 9 ? t : t.ownerDocument; - return Vi || so == null || so !== Zt(n) ? null : ("selectionStart" in (n = so) && Oi(n) ? n = { start: n.selectionStart, end: n.selectionEnd } : n = { anchorNode: (n = (n.ownerDocument && n.ownerDocument.defaultView || window).getSelection()).anchorNode, anchorOffset: n.anchorOffset, focusNode: n.focusNode, focusOffset: n.focusOffset }, Fr && Ur(Fr, n) ? null : (Fr = n, (e = Ot.getPooled(Ui.select, Fi, e, t)).type = "select", e.target = so, Bt(e), e)); + return Vi || so == null || so !== Zt(n) ? null : ("selectionStart" in (n = so) && Oi(n) ? n = { start: n.selectionStart, end: n.selectionEnd } : n = { anchorNode: (n = (n.ownerDocument && n.ownerDocument.defaultView || window).getSelection()).anchorNode, anchorOffset: n.anchorOffset, focusNode: n.focusNode, focusOffset: n.focusOffset }, Ur && Fr(Ur, n) ? null : (Ur = n, (e = Ot.getPooled(Fi.select, Ui, e, t)).type = "select", e.target = so, $t(e), e)); } - var Ts = { eventTypes: Ui, extractEvents: function(e, t, n, r, a, p) { + var Ts = { eventTypes: Fi, extractEvents: function(e, t, n, r, a, p) { if (!(p = !(a = p || (r.window === r ? r.document : r.nodeType === 9 ? r : r.ownerDocument)))) { e: { a = Ge(a), p = A.onSelect; @@ -3544,10 +3618,10 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (p) return null; switch (a = t ? Zn(t) : window, e) { case "focus": - (ga(a) || a.contentEditable === "true") && (so = a, Fi = t, Fr = null); + (ga(a) || a.contentEditable === "true") && (so = a, Ui = t, Ur = null); break; case "blur": - Fr = Fi = so = null; + Ur = Ui = so = null; break; case "mousedown": Vi = !0; @@ -3582,7 +3656,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return e.type === "keydown" || e.type === "keyup" ? e.keyCode : 0; }, which: function(e) { return e.type === "keypress" ? ci(e) : e.type === "keydown" || e.type === "keyup" ? e.keyCode : 0; - } }), Be = jr.extend({ dataTransfer: null }), l = jo.extend({ touches: null, targetTouches: null, changedTouches: null, altKey: null, metaKey: null, ctrlKey: null, shiftKey: null, getModifierState: Lo }), o = Ot.extend({ propertyName: null, elapsedTime: null, pseudoElement: null }), s = jr.extend({ deltaX: function(e) { + } }), $e = jr.extend({ dataTransfer: null }), l = jo.extend({ touches: null, targetTouches: null, changedTouches: null, altKey: null, metaKey: null, ctrlKey: null, shiftKey: null, getModifierState: Lo }), o = Ot.extend({ propertyName: null, elapsedTime: null, pseudoElement: null }), s = jr.extend({ deltaX: function(e) { return "deltaX" in e ? e.deltaX : "wheelDeltaX" in e ? -e.wheelDeltaX : 0; }, deltaY: function(e) { return "deltaY" in e ? e.deltaY : "wheelDeltaY" in e ? -e.wheelDeltaY : "wheelDelta" in e ? -e.wheelDelta : 0; @@ -3620,7 +3694,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); case "dragover": case "dragstart": case "drop": - e = Be; + e = $e; break; case "touchcancel": case "touchend": @@ -3630,7 +3704,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); break; case M: case Q: - case ye: + case be: e = Os; break; case De: @@ -3660,16 +3734,16 @@ https://fb.me/react-async-component-lifecycle-hooks`); default: e = Ot; } - return Bt(t = e.getPooled(a, t, n, r)), t; + return $t(t = e.getPooled(a, t, n, r)), t; } }; if (ne) throw Error(m(101)); - ne = Array.prototype.slice.call("ResponderEventPlugin SimpleEventPlugin EnterLeaveEventPlugin ChangeEventPlugin SelectEventPlugin BeforeInputEventPlugin".split(" ")), oe(), ee = Ri, R = kr, U = Zn, ae({ SimpleEventPlugin: c, EnterLeaveEventPlugin: xs, ChangeEventPlugin: ws, SelectEventPlugin: Ts, BeforeInputEventPlugin: ai }); - var g = [], b = -1; + ne = Array.prototype.slice.call("ResponderEventPlugin SimpleEventPlugin EnterLeaveEventPlugin ChangeEventPlugin SelectEventPlugin BeforeInputEventPlugin".split(" ")), oe(), ee = Ri, R = kr, F = Zn, ae({ SimpleEventPlugin: c, EnterLeaveEventPlugin: xs, ChangeEventPlugin: ws, SelectEventPlugin: Ts, BeforeInputEventPlugin: ai }); + var g = [], y = -1; function x(e) { - 0 > b || (e.current = g[b], g[b] = null, b--); + 0 > y || (e.current = g[y], g[y] = null, y--); } function z(e, t) { - b++, g[b] = e.current, e.current = t; + y++, g[y] = e.current, e.current = t; } var K = {}, Y = { current: K }, ie = { current: !1 }, ue = K; function he(e, t) { @@ -3700,16 +3774,16 @@ https://fb.me/react-async-component-lifecycle-hooks`); function st(e) { return e = (e = e.stateNode) && e.__reactInternalMemoizedMergedChildContext || K, ue = Y.current, z(Y, e), z(ie, ie.current), !0; } - function $e(e, t, n) { + function Be(e, t, n) { var r = e.stateNode; if (!r) throw Error(m(169)); n ? (e = ze(e, t, ue), r.__reactInternalMemoizedMergedChildContext = e, x(ie), x(Y), z(Y, e)) : x(ie), z(ie, n); } - var je = C.unstable_runWithPriority, dt = C.unstable_scheduleCallback, vt = C.unstable_cancelCallback, $t = C.unstable_requestPaint, xt = C.unstable_now, It = C.unstable_getCurrentPriorityLevel, St = C.unstable_ImmediatePriority, mt = C.unstable_UserBlockingPriority, En = C.unstable_NormalPriority, it = C.unstable_LowPriority, xn = C.unstable_IdlePriority, jn = {}, lo = C.unstable_shouldYield, Wt = $t !== void 0 ? $t : function() { + var je = C.unstable_runWithPriority, dt = C.unstable_scheduleCallback, vt = C.unstable_cancelCallback, Bt = C.unstable_requestPaint, xt = C.unstable_now, It = C.unstable_getCurrentPriorityLevel, St = C.unstable_ImmediatePriority, mt = C.unstable_UserBlockingPriority, En = C.unstable_NormalPriority, it = C.unstable_LowPriority, xn = C.unstable_IdlePriority, jn = {}, lo = C.unstable_shouldYield, Wt = Bt !== void 0 ? Bt : function() { }, Jt = null, en = null, qt = !1, cn = xt(), Nt = 1e4 > cn ? xt : function() { return xt() - cn; }; - function Ut() { + function Ft() { switch (It()) { case St: return 99; @@ -3747,7 +3821,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); function Hi(e, t, n) { return e = un(e), dt(e, t, n); } - function Bi(e) { + function $i(e) { return Jt === null ? (Jt = [e], en = dt(St, Ta)) : Jt.push(e), jn; } function tn() { @@ -3778,16 +3852,16 @@ https://fb.me/react-async-component-lifecycle-hooks`); } } } - function Uo(e, t, n) { + function Fo(e, t, n) { return 1073741821 - (1 + ((1073741821 - e + t / 10) / (n /= 10) | 0)) * n; } function nn(e, t) { if (e && e.defaultProps) for (var n in t = d({}, t), e = e.defaultProps) t[n] === void 0 && (t[n] = e[n]); return t; } - var Vr = { current: null }, Fo = null, wr = null, co = null; + var Vr = { current: null }, Uo = null, wr = null, co = null; function ir() { - co = wr = Fo = null; + co = wr = Uo = null; } function Vo(e) { var t = Vr.current; @@ -3805,12 +3879,12 @@ https://fb.me/react-async-component-lifecycle-hooks`); } } function ui(e, t) { - Fo = e, co = wr = null, (e = e.dependencies) !== null && e.firstContext !== null && (e.expirationTime >= t && (Er = !0), e.firstContext = null); + Uo = e, co = wr = null, (e = e.dependencies) !== null && e.firstContext !== null && (e.expirationTime >= t && (Er = !0), e.firstContext = null); } function Ln(e, t) { if (co !== e && t !== !1 && t !== 0) if (typeof t == "number" && t !== 1073741823 || (co = e, t = 1073741823), t = { context: e, observedBits: t, next: null }, wr === null) { - if (Fo === null) throw Error(m(308)); - wr = t, Fo.dependencies = { expirationTime: 0, firstContext: t, responders: null }; + if (Uo === null) throw Error(m(308)); + wr = t, Uo.dependencies = { expirationTime: 0, firstContext: t, responders: null }; } else wr = wr.next = t; return e._currentValue; } @@ -3834,7 +3908,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); var n = e.alternate; n !== null && Ms(n, e), (n = (e = e.updateQueue).baseQueue) === null ? (e.baseQueue = t.next = t, t.next = t) : (t.next = n.next, n.next = t); } - function $i(e, t, n, r) { + function Bi(e, t, n, r) { var a = e.updateQueue; uo = !1; var p = a.baseQueue, h = a.shared.pending; @@ -3902,18 +3976,18 @@ https://fb.me/react-async-component-lifecycle-hooks`); }, enqueueSetState: function(e, t, n) { e = e._reactInternalFiber; var r = Sr(), a = Wi.suspense; - (a = po(r = Ko(r, e, a), a)).payload = t, n != null && (a.callback = n), fo(e, a), bo(e, r); + (a = po(r = Ko(r, e, a), a)).payload = t, n != null && (a.callback = n), fo(e, a), yo(e, r); }, enqueueReplaceState: function(e, t, n) { e = e._reactInternalFiber; var r = Sr(), a = Wi.suspense; - (a = po(r = Ko(r, e, a), a)).tag = 1, a.payload = t, n != null && (a.callback = n), fo(e, a), bo(e, r); + (a = po(r = Ko(r, e, a), a)).tag = 1, a.payload = t, n != null && (a.callback = n), fo(e, a), yo(e, r); }, enqueueForceUpdate: function(e, t) { e = e._reactInternalFiber; var n = Sr(), r = Wi.suspense; - (r = po(n = Ko(n, e, r), r)).tag = 2, t != null && (r.callback = t), fo(e, r), bo(e, n); + (r = po(n = Ko(n, e, r), r)).tag = 2, t != null && (r.callback = t), fo(e, r), yo(e, n); } }; function Ol(e, t, n, r, a, p, h) { - return typeof (e = e.stateNode).shouldComponentUpdate == "function" ? e.shouldComponentUpdate(r, p, h) : !t.prototype || !t.prototype.isPureReactComponent || !Ur(n, r) || !Ur(a, p); + return typeof (e = e.stateNode).shouldComponentUpdate == "function" ? e.shouldComponentUpdate(r, p, h) : !t.prototype || !t.prototype.isPureReactComponent || !Fr(n, r) || !Fr(a, p); } function Nl(e, t, n) { var r = !1, a = K, p = t.contextType; @@ -3926,7 +4000,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); var a = e.stateNode; a.props = n, a.state = e.memoizedState, a.refs = Tl, Rs(e); var p = t.contextType; - typeof p == "object" && p !== null ? a.context = Ln(p) : (p = de(t) ? ue : Y.current, a.context = he(e, p)), $i(e, n, a, r), a.state = e.memoizedState, typeof (p = t.getDerivedStateFromProps) == "function" && (Oa(e, t, p, n), a.state = e.memoizedState), typeof t.getDerivedStateFromProps == "function" || typeof a.getSnapshotBeforeUpdate == "function" || typeof a.UNSAFE_componentWillMount != "function" && typeof a.componentWillMount != "function" || (t = a.state, typeof a.componentWillMount == "function" && a.componentWillMount(), typeof a.UNSAFE_componentWillMount == "function" && a.UNSAFE_componentWillMount(), t !== a.state && Na.enqueueReplaceState(a, a.state, null), $i(e, n, a, r), a.state = e.memoizedState), typeof a.componentDidMount == "function" && (e.effectTag |= 4); + typeof p == "object" && p !== null ? a.context = Ln(p) : (p = de(t) ? ue : Y.current, a.context = he(e, p)), Bi(e, n, a, r), a.state = e.memoizedState, typeof (p = t.getDerivedStateFromProps) == "function" && (Oa(e, t, p, n), a.state = e.memoizedState), typeof t.getDerivedStateFromProps == "function" || typeof a.getSnapshotBeforeUpdate == "function" || typeof a.UNSAFE_componentWillMount != "function" && typeof a.componentWillMount != "function" || (t = a.state, typeof a.componentWillMount == "function" && a.componentWillMount(), typeof a.UNSAFE_componentWillMount == "function" && a.UNSAFE_componentWillMount(), t !== a.state && Na.enqueueReplaceState(a, a.state, null), Bi(e, n, a, r), a.state = e.memoizedState), typeof a.componentDidMount == "function" && (e.effectTag |= 4); } var Pa = Array.isArray; function qi(e, t, n) { @@ -3983,10 +4057,10 @@ https://fb.me/react-async-component-lifecycle-hooks`); return B !== null && B.elementType === re.type ? ((ve = a(B, re.props)).ref = qi(q, B, re), ve.return = q, ve) : ((ve = ts(re.type, re.key, re.props, null, q.mode, ve)).ref = qi(q, B, re), ve.return = q, ve); } function V(q, B, re, ve) { - return B === null || B.tag !== 4 || B.stateNode.containerInfo !== re.containerInfo || B.stateNode.implementation !== re.implementation ? ((B = bl(re, q.mode, ve)).return = q, B) : ((B = a(B, re.children || [])).return = q, B); + return B === null || B.tag !== 4 || B.stateNode.containerInfo !== re.containerInfo || B.stateNode.implementation !== re.implementation ? ((B = yl(re, q.mode, ve)).return = q, B) : ((B = a(B, re.children || [])).return = q, B); } function ce(q, B, re, ve, xe) { - return B === null || B.tag !== 7 ? ((B = yo(re, q.mode, ve, xe)).return = q, B) : ((B = a(B, re)).return = q, B); + return B === null || B.tag !== 7 ? ((B = bo(re, q.mode, ve, xe)).return = q, B) : ((B = a(B, re)).return = q, B); } function Re(q, B, re) { if (typeof B == "string" || typeof B == "number") return (B = gl("" + B, q.mode, re)).return = q, B; @@ -3995,9 +4069,9 @@ https://fb.me/react-async-component-lifecycle-hooks`); case Gt: return (re = ts(B.type, B.key, B.props, null, q.mode, re)).ref = qi(q, null, B), re.return = q, re; case On: - return (B = bl(B, q.mode, re)).return = q, B; + return (B = yl(B, q.mode, re)).return = q, B; } - if (Pa(B) || Wn(B)) return (B = yo(B, q.mode, re, null)).return = q, B; + if (Pa(B) || Wn(B)) return (B = bo(B, q.mode, re, null)).return = q, B; Da(q, B); } return null; @@ -4032,22 +4106,22 @@ https://fb.me/react-async-component-lifecycle-hooks`); return null; } function Vn(q, B, re, ve) { - for (var xe = null, Ie = null, Ue = B, at = B = 0, Mt = null; Ue !== null && at < re.length; at++) { - Ue.index > at ? (Mt = Ue, Ue = null) : Mt = Ue.sibling; - var Xe = Ve(q, Ue, re[at], ve); + for (var xe = null, Ie = null, Fe = B, at = B = 0, Mt = null; Fe !== null && at < re.length; at++) { + Fe.index > at ? (Mt = Fe, Fe = null) : Mt = Fe.sibling; + var Xe = Ve(q, Fe, re[at], ve); if (Xe === null) { - Ue === null && (Ue = Mt); + Fe === null && (Fe = Mt); break; } - e && Ue && Xe.alternate === null && t(q, Ue), B = p(Xe, B, at), Ie === null ? xe = Xe : Ie.sibling = Xe, Ie = Xe, Ue = Mt; + e && Fe && Xe.alternate === null && t(q, Fe), B = p(Xe, B, at), Ie === null ? xe = Xe : Ie.sibling = Xe, Ie = Xe, Fe = Mt; } - if (at === re.length) return n(q, Ue), xe; - if (Ue === null) { - for (; at < re.length; at++) (Ue = Re(q, re[at], ve)) !== null && (B = p(Ue, B, at), Ie === null ? xe = Ue : Ie.sibling = Ue, Ie = Ue); + if (at === re.length) return n(q, Fe), xe; + if (Fe === null) { + for (; at < re.length; at++) (Fe = Re(q, re[at], ve)) !== null && (B = p(Fe, B, at), Ie === null ? xe = Fe : Ie.sibling = Fe, Ie = Fe); return xe; } - for (Ue = r(q, Ue); at < re.length; at++) (Mt = ot(Ue, q, at, re[at], ve)) !== null && (e && Mt.alternate !== null && Ue.delete(Mt.key === null ? at : Mt.key), B = p(Mt, B, at), Ie === null ? xe = Mt : Ie.sibling = Mt, Ie = Mt); - return e && Ue.forEach(function(vo) { + for (Fe = r(q, Fe); at < re.length; at++) (Mt = ot(Fe, q, at, re[at], ve)) !== null && (e && Mt.alternate !== null && Fe.delete(Mt.key === null ? at : Mt.key), B = p(Mt, B, at), Ie === null ? xe = Mt : Ie.sibling = Mt, Ie = Mt); + return e && Fe.forEach(function(vo) { return t(q, vo); }), xe; } @@ -4055,22 +4129,22 @@ https://fb.me/react-async-component-lifecycle-hooks`); var xe = Wn(re); if (typeof xe != "function") throw Error(m(150)); if ((re = xe.call(re)) == null) throw Error(m(151)); - for (var Ie = xe = null, Ue = B, at = B = 0, Mt = null, Xe = re.next(); Ue !== null && !Xe.done; at++, Xe = re.next()) { - Ue.index > at ? (Mt = Ue, Ue = null) : Mt = Ue.sibling; - var vo = Ve(q, Ue, Xe.value, ve); + for (var Ie = xe = null, Fe = B, at = B = 0, Mt = null, Xe = re.next(); Fe !== null && !Xe.done; at++, Xe = re.next()) { + Fe.index > at ? (Mt = Fe, Fe = null) : Mt = Fe.sibling; + var vo = Ve(q, Fe, Xe.value, ve); if (vo === null) { - Ue === null && (Ue = Mt); + Fe === null && (Fe = Mt); break; } - e && Ue && vo.alternate === null && t(q, Ue), B = p(vo, B, at), Ie === null ? xe = vo : Ie.sibling = vo, Ie = vo, Ue = Mt; + e && Fe && vo.alternate === null && t(q, Fe), B = p(vo, B, at), Ie === null ? xe = vo : Ie.sibling = vo, Ie = vo, Fe = Mt; } - if (Xe.done) return n(q, Ue), xe; - if (Ue === null) { + if (Xe.done) return n(q, Fe), xe; + if (Fe === null) { for (; !Xe.done; at++, Xe = re.next()) (Xe = Re(q, Xe.value, ve)) !== null && (B = p(Xe, B, at), Ie === null ? xe = Xe : Ie.sibling = Xe, Ie = Xe); return xe; } - for (Ue = r(q, Ue); !Xe.done; at++, Xe = re.next()) (Xe = ot(Ue, q, at, Xe.value, ve)) !== null && (e && Xe.alternate !== null && Ue.delete(Xe.key === null ? at : Xe.key), B = p(Xe, B, at), Ie === null ? xe = Xe : Ie.sibling = Xe, Ie = Xe); - return e && Ue.forEach(function(iu) { + for (Fe = r(q, Fe); !Xe.done; at++, Xe = re.next()) (Xe = ot(Fe, q, at, Xe.value, ve)) !== null && (e && Xe.alternate !== null && Fe.delete(Xe.key === null ? at : Xe.key), B = p(Xe, B, at), Ie === null ? xe = Xe : Ie.sibling = Xe, Ie = Xe); + return e && Fe.forEach(function(iu) { return t(q, iu); }), xe; } @@ -4097,7 +4171,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } t(q, xe), xe = xe.sibling; } - re.type === Nn ? ((B = yo(re.props.children, q.mode, ve, re.key)).return = q, q = B) : ((ve = ts(re.type, re.key, re.props, null, q.mode, ve)).ref = qi(q, B, re), ve.return = q, q = ve); + re.type === Nn ? ((B = bo(re.props.children, q.mode, ve, re.key)).return = q, q = B) : ((ve = ts(re.type, re.key, re.props, null, q.mode, ve)).ref = qi(q, B, re), ve.return = q, q = ve); } return h(q); case On: @@ -4113,7 +4187,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } t(q, B), B = B.sibling; } - (B = bl(re, q.mode, ve)).return = q, q = B; + (B = yl(re, q.mode, ve)).return = q, q = B; } return h(q); } @@ -4160,7 +4234,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); for (var t = e; t !== null; ) { if (t.tag === 13) { var n = t.memoizedState; - if (n !== null && ((n = n.dehydrated) === null || n.data === Ni || n.data === br)) return t; + if (n !== null && ((n = n.dehydrated) === null || n.data === Ni || n.data === yr)) return t; } else if (t.tag === 19 && t.memoizedProps.revealOrder !== void 0) { if (64 & t.effectTag) return t; } else if (t.child !== null) { @@ -4176,27 +4250,27 @@ https://fb.me/react-async-component-lifecycle-hooks`); } return null; } - function Us(e, t) { + function Fs(e, t) { return { responder: e, props: t }; } - var Ra = et.ReactCurrentDispatcher, Un = et.ReactCurrentBatchConfig, ho = 0, Rt = null, rn = null, Xt = null, Ma = !1; + var Ra = et.ReactCurrentDispatcher, Fn = et.ReactCurrentBatchConfig, ho = 0, Rt = null, rn = null, Xt = null, Ma = !1; function Sn() { throw Error(m(321)); } - function Fs(e, t) { + function Us(e, t) { if (t === null) return !1; for (var n = 0; n < t.length && n < e.length; n++) if (!rr(e[n], t[n])) return !1; return !0; } function Vs(e, t, n, r, a, p) { - if (ho = p, Rt = t, t.memoizedState = null, t.updateQueue = null, t.expirationTime = 0, Ra.current = e === null || e.memoizedState === null ? Lc : Uc, e = n(r, a), t.expirationTime === ho) { + if (ho = p, Rt = t, t.memoizedState = null, t.updateQueue = null, t.expirationTime = 0, Ra.current = e === null || e.memoizedState === null ? Lc : Fc, e = n(r, a), t.expirationTime === ho) { p = 0; do { if (t.expirationTime = 0, !(25 > p)) throw Error(m(301)); - p += 1, Xt = rn = null, t.updateQueue = null, Ra.current = Fc, e = n(r, a); + p += 1, Xt = rn = null, t.updateQueue = null, Ra.current = Uc, e = n(r, a); } while (t.expirationTime === ho); } - if (Ra.current = Ua, t = rn !== null && rn.next !== null, ho = 0, Xt = rn = Rt = null, Ma = !1, t) throw Error(m(300)); + if (Ra.current = Fa, t = rn !== null && rn.next !== null, ho = 0, Xt = rn = Rt = null, Ma = !1, t) throw Error(m(300)); return e; } function fi() { @@ -4216,7 +4290,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } return Xt; } - function Bo(e, t) { + function $o(e, t) { return typeof t == "function" ? t(e) : t; } function za(e) { @@ -4263,17 +4337,17 @@ https://fb.me/react-async-component-lifecycle-hooks`); } function Hs(e) { var t = fi(); - return typeof e == "function" && (e = e()), t.memoizedState = t.baseState = e, e = (e = t.queue = { pending: null, dispatch: null, lastRenderedReducer: Bo, lastRenderedState: e }).dispatch = Fl.bind(null, Rt, e), [t.memoizedState, e]; + return typeof e == "function" && (e = e()), t.memoizedState = t.baseState = e, e = (e = t.queue = { pending: null, dispatch: null, lastRenderedReducer: $o, lastRenderedState: e }).dispatch = Ul.bind(null, Rt, e), [t.memoizedState, e]; } - function Bs(e, t, n, r) { + function $s(e, t, n, r) { return e = { tag: e, create: t, destroy: n, deps: r, next: null }, (t = Rt.updateQueue) === null ? (t = { lastEffect: null }, Rt.updateQueue = t, t.lastEffect = e.next = e) : (n = t.lastEffect) === null ? t.lastEffect = e.next = e : (r = n.next, n.next = e, e.next = r, t.lastEffect = e), e; } function Rl() { return hi().memoizedState; } - function $s(e, t, n, r) { + function Bs(e, t, n, r) { var a = fi(); - Rt.effectTag |= e, a.memoizedState = Bs(1 | t, n, void 0, r === void 0 ? null : r); + Rt.effectTag |= e, a.memoizedState = $s(1 | t, n, void 0, r === void 0 ? null : r); } function Ws(e, t, n, r) { var a = hi(); @@ -4281,12 +4355,12 @@ https://fb.me/react-async-component-lifecycle-hooks`); var p = void 0; if (rn !== null) { var h = rn.memoizedState; - if (p = h.destroy, r !== null && Fs(r, h.deps)) return void Bs(t, n, p, r); + if (p = h.destroy, r !== null && Us(r, h.deps)) return void $s(t, n, p, r); } - Rt.effectTag |= e, a.memoizedState = Bs(1 | t, n, p, r); + Rt.effectTag |= e, a.memoizedState = $s(1 | t, n, p, r); } function Ml(e, t) { - return $s(516, 4, e, t); + return Bs(516, 4, e, t); } function ja(e, t) { return Ws(516, 4, e, t); @@ -4313,29 +4387,29 @@ https://fb.me/react-async-component-lifecycle-hooks`); var n = hi(); t = t === void 0 ? null : t; var r = n.memoizedState; - return r !== null && t !== null && Fs(t, r[1]) ? r[0] : (n.memoizedState = [e, t], e); + return r !== null && t !== null && Us(t, r[1]) ? r[0] : (n.memoizedState = [e, t], e); } - function Ul(e, t) { + function Fl(e, t) { var n = hi(); t = t === void 0 ? null : t; var r = n.memoizedState; - return r !== null && t !== null && Fs(t, r[1]) ? r[0] : (e = e(), n.memoizedState = [e, t], e); + return r !== null && t !== null && Us(t, r[1]) ? r[0] : (e = e(), n.memoizedState = [e, t], e); } function Ks(e, t, n) { - var r = Ut(); + var r = Ft(); or(98 > r ? 98 : r, function() { e(!0); }), or(97 < r ? 97 : r, function() { - var a = Un.suspense; - Un.suspense = t === void 0 ? null : t; + var a = Fn.suspense; + Fn.suspense = t === void 0 ? null : t; try { e(!1), n(); } finally { - Un.suspense = a; + Fn.suspense = a; } }); } - function Fl(e, t, n) { + function Ul(e, t, n) { var r = Sr(), a = Wi.suspense; a = { expirationTime: r = Ko(r, e, a), suspenseConfig: a, action: n, eagerReducer: null, eagerState: null, next: null }; var p = t.pending; @@ -4346,68 +4420,68 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (a.eagerReducer = p, a.eagerState = w, rr(w, h)) return; } catch { } - bo(e, r); + yo(e, r); } } - var Ua = { readContext: Ln, useCallback: Sn, useContext: Sn, useEffect: Sn, useImperativeHandle: Sn, useLayoutEffect: Sn, useMemo: Sn, useReducer: Sn, useRef: Sn, useState: Sn, useDebugValue: Sn, useResponder: Sn, useDeferredValue: Sn, useTransition: Sn }, Lc = { readContext: Ln, useCallback: Ll, useContext: Ln, useEffect: Ml, useImperativeHandle: function(e, t, n) { - return n = n != null ? n.concat([e]) : null, $s(4, 2, Al.bind(null, t, e), n); + var Fa = { readContext: Ln, useCallback: Sn, useContext: Sn, useEffect: Sn, useImperativeHandle: Sn, useLayoutEffect: Sn, useMemo: Sn, useReducer: Sn, useRef: Sn, useState: Sn, useDebugValue: Sn, useResponder: Sn, useDeferredValue: Sn, useTransition: Sn }, Lc = { readContext: Ln, useCallback: Ll, useContext: Ln, useEffect: Ml, useImperativeHandle: function(e, t, n) { + return n = n != null ? n.concat([e]) : null, Bs(4, 2, Al.bind(null, t, e), n); }, useLayoutEffect: function(e, t) { - return $s(4, 2, e, t); + return Bs(4, 2, e, t); }, useMemo: function(e, t) { var n = fi(); return t = t === void 0 ? null : t, e = e(), n.memoizedState = [e, t], e; }, useReducer: function(e, t, n) { var r = fi(); - return t = n !== void 0 ? n(t) : t, r.memoizedState = r.baseState = t, e = (e = r.queue = { pending: null, dispatch: null, lastRenderedReducer: e, lastRenderedState: t }).dispatch = Fl.bind(null, Rt, e), [r.memoizedState, e]; + return t = n !== void 0 ? n(t) : t, r.memoizedState = r.baseState = t, e = (e = r.queue = { pending: null, dispatch: null, lastRenderedReducer: e, lastRenderedState: t }).dispatch = Ul.bind(null, Rt, e), [r.memoizedState, e]; }, useRef: function(e) { return e = { current: e }, fi().memoizedState = e; - }, useState: Hs, useDebugValue: qs, useResponder: Us, useDeferredValue: function(e, t) { + }, useState: Hs, useDebugValue: qs, useResponder: Fs, useDeferredValue: function(e, t) { var n = Hs(e), r = n[0], a = n[1]; return Ml(function() { - var p = Un.suspense; - Un.suspense = t === void 0 ? null : t; + var p = Fn.suspense; + Fn.suspense = t === void 0 ? null : t; try { a(e); } finally { - Un.suspense = p; + Fn.suspense = p; } }, [e, t]), r; }, useTransition: function(e) { var t = Hs(!1), n = t[0]; return t = t[1], [Ll(Ks.bind(null, t, e), [t, e]), n]; - } }, Uc = { readContext: Ln, useCallback: La, useContext: Ln, useEffect: ja, useImperativeHandle: jl, useLayoutEffect: zl, useMemo: Ul, useReducer: za, useRef: Rl, useState: function() { - return za(Bo); - }, useDebugValue: qs, useResponder: Us, useDeferredValue: function(e, t) { - var n = za(Bo), r = n[0], a = n[1]; + } }, Fc = { readContext: Ln, useCallback: La, useContext: Ln, useEffect: ja, useImperativeHandle: jl, useLayoutEffect: zl, useMemo: Fl, useReducer: za, useRef: Rl, useState: function() { + return za($o); + }, useDebugValue: qs, useResponder: Fs, useDeferredValue: function(e, t) { + var n = za($o), r = n[0], a = n[1]; return ja(function() { - var p = Un.suspense; - Un.suspense = t === void 0 ? null : t; + var p = Fn.suspense; + Fn.suspense = t === void 0 ? null : t; try { a(e); } finally { - Un.suspense = p; + Fn.suspense = p; } }, [e, t]), r; }, useTransition: function(e) { - var t = za(Bo), n = t[0]; + var t = za($o), n = t[0]; return t = t[1], [La(Ks.bind(null, t, e), [t, e]), n]; - } }, Fc = { readContext: Ln, useCallback: La, useContext: Ln, useEffect: ja, useImperativeHandle: jl, useLayoutEffect: zl, useMemo: Ul, useReducer: Aa, useRef: Rl, useState: function() { - return Aa(Bo); - }, useDebugValue: qs, useResponder: Us, useDeferredValue: function(e, t) { - var n = Aa(Bo), r = n[0], a = n[1]; + } }, Uc = { readContext: Ln, useCallback: La, useContext: Ln, useEffect: ja, useImperativeHandle: jl, useLayoutEffect: zl, useMemo: Fl, useReducer: Aa, useRef: Rl, useState: function() { + return Aa($o); + }, useDebugValue: qs, useResponder: Fs, useDeferredValue: function(e, t) { + var n = Aa($o), r = n[0], a = n[1]; return ja(function() { - var p = Un.suspense; - Un.suspense = t === void 0 ? null : t; + var p = Fn.suspense; + Fn.suspense = t === void 0 ? null : t; try { a(e); } finally { - Un.suspense = p; + Fn.suspense = p; } }, [e, t]), r; }, useTransition: function(e) { - var t = Aa(Bo), n = t[0]; + var t = Aa($o), n = t[0]; return t = t[1], [La(Ks.bind(null, t, e), [t, e]), n]; - } }, Hr = null, mo = null, $o = !1; + } }, Hr = null, mo = null, Bo = !1; function Vl(e, t) { var n = Cr(5, null, null, 0); n.elementType = "DELETED", n.type = "DELETED", n.stateNode = t, n.return = e, n.effectTag = 8, e.lastEffect !== null ? (e.lastEffect.nextEffect = n, e.lastEffect = n) : e.firstEffect = e.lastEffect = n; @@ -4424,28 +4498,28 @@ https://fb.me/react-async-component-lifecycle-hooks`); } } function Qs(e) { - if ($o) { + if (Bo) { var t = mo; if (t) { var n = t; if (!Hl(e, t)) { - if (!(t = Ar(n.nextSibling)) || !Hl(e, t)) return e.effectTag = -1025 & e.effectTag | 2, $o = !1, void (Hr = e); + if (!(t = Ar(n.nextSibling)) || !Hl(e, t)) return e.effectTag = -1025 & e.effectTag | 2, Bo = !1, void (Hr = e); Vl(Hr, n); } Hr = e, mo = Ar(t.firstChild); - } else e.effectTag = -1025 & e.effectTag | 2, $o = !1, Hr = e; + } else e.effectTag = -1025 & e.effectTag | 2, Bo = !1, Hr = e; } } - function Bl(e) { + function $l(e) { for (e = e.return; e !== null && e.tag !== 5 && e.tag !== 3 && e.tag !== 13; ) e = e.return; Hr = e; } - function Fa(e) { + function Ua(e) { if (e !== Hr) return !1; - if (!$o) return Bl(e), $o = !0, !1; + if (!Bo) return $l(e), Bo = !0, !1; var t = e.type; if (e.tag !== 5 || t !== "head" && t !== "body" && !Pi(t, e.memoizedProps)) for (t = mo; t; ) Vl(e, t), t = Ar(t.nextSibling); - if (Bl(e), e.tag === 13) { + if ($l(e), e.tag === 13) { if (!(e = (e = e.memoizedState) !== null ? e.dehydrated : null)) throw Error(m(317)); e: { for (e = e.nextSibling, t = 0; e; ) { @@ -4457,7 +4531,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); break e; } t--; - } else n !== eo && n !== br && n !== Ni || t++; + } else n !== eo && n !== yr && n !== Ni || t++; } e = e.nextSibling; } @@ -4467,26 +4541,26 @@ https://fb.me/react-async-component-lifecycle-hooks`); return !0; } function Ys() { - mo = Hr = null, $o = !1; + mo = Hr = null, Bo = !1; } var Vc = et.ReactCurrentOwner, Er = !1; - function Fn(e, t, n, r) { + function Un(e, t, n, r) { t.child = e === null ? As(t, null, n, r) : di(t, e.child, n, r); } - function $l(e, t, n, r, a) { + function Bl(e, t, n, r, a) { n = n.render; var p = t.ref; - return ui(t, a), r = Vs(e, t, n, r, p, a), e === null || Er ? (t.effectTag |= 1, Fn(e, t, r, a), t.child) : (t.updateQueue = e.updateQueue, t.effectTag &= -517, e.expirationTime <= a && (e.expirationTime = 0), Br(e, t, a)); + return ui(t, a), r = Vs(e, t, n, r, p, a), e === null || Er ? (t.effectTag |= 1, Un(e, t, r, a), t.child) : (t.updateQueue = e.updateQueue, t.effectTag &= -517, e.expirationTime <= a && (e.expirationTime = 0), $r(e, t, a)); } function Wl(e, t, n, r, a, p) { if (e === null) { var h = n.type; return typeof h != "function" || ml(h) || h.defaultProps !== void 0 || n.compare !== null || n.defaultProps !== void 0 ? ((e = ts(n.type, null, r, null, t.mode, p)).ref = t.ref, e.return = t, t.child = e) : (t.tag = 15, t.type = h, ql(e, t, h, r, a, p)); } - return h = e.child, a < p && (a = h.memoizedProps, (n = (n = n.compare) !== null ? n : Ur)(a, r) && e.ref === t.ref) ? Br(e, t, p) : (t.effectTag |= 1, (e = Go(h, r)).ref = t.ref, e.return = t, t.child = e); + return h = e.child, a < p && (a = h.memoizedProps, (n = (n = n.compare) !== null ? n : Fr)(a, r) && e.ref === t.ref) ? $r(e, t, p) : (t.effectTag |= 1, (e = Go(h, r)).ref = t.ref, e.return = t, t.child = e); } function ql(e, t, n, r, a, p) { - return e !== null && Ur(e.memoizedProps, r) && e.ref === t.ref && (Er = !1, a < p) ? (t.expirationTime = e.expirationTime, Br(e, t, p)) : Xs(e, t, n, r, p); + return e !== null && Fr(e.memoizedProps, r) && e.ref === t.ref && (Er = !1, a < p) ? (t.expirationTime = e.expirationTime, $r(e, t, p)) : Xs(e, t, n, r, p); } function Kl(e, t) { var n = t.ref; @@ -4494,7 +4568,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } function Xs(e, t, n, r, a) { var p = de(n) ? ue : Y.current; - return p = he(t, p), ui(t, a), n = Vs(e, t, n, r, p, a), e === null || Er ? (t.effectTag |= 1, Fn(e, t, n, a), t.child) : (t.updateQueue = e.updateQueue, t.effectTag &= -517, e.expirationTime <= a && (e.expirationTime = 0), Br(e, t, a)); + return p = he(t, p), ui(t, a), n = Vs(e, t, n, r, p, a), e === null || Er ? (t.effectTag |= 1, Un(e, t, n, a), t.child) : (t.updateQueue = e.updateQueue, t.effectTag &= -517, e.expirationTime <= a && (e.expirationTime = 0), $r(e, t, a)); } function Ql(e, t, n, r, a) { if (de(n)) { @@ -4510,17 +4584,17 @@ https://fb.me/react-async-component-lifecycle-hooks`); var ce = n.getDerivedStateFromProps, Re = typeof ce == "function" || typeof h.getSnapshotBeforeUpdate == "function"; Re || typeof h.UNSAFE_componentWillReceiveProps != "function" && typeof h.componentWillReceiveProps != "function" || (w !== r || W !== V) && Pl(t, h, r, V), uo = !1; var Ve = t.memoizedState; - h.state = Ve, $i(t, r, h, a), W = t.memoizedState, w !== r || Ve !== W || ie.current || uo ? (typeof ce == "function" && (Oa(t, n, ce, r), W = t.memoizedState), (w = uo || Ol(t, n, w, r, Ve, W, V)) ? (Re || typeof h.UNSAFE_componentWillMount != "function" && typeof h.componentWillMount != "function" || (typeof h.componentWillMount == "function" && h.componentWillMount(), typeof h.UNSAFE_componentWillMount == "function" && h.UNSAFE_componentWillMount()), typeof h.componentDidMount == "function" && (t.effectTag |= 4)) : (typeof h.componentDidMount == "function" && (t.effectTag |= 4), t.memoizedProps = r, t.memoizedState = W), h.props = r, h.state = W, h.context = V, r = w) : (typeof h.componentDidMount == "function" && (t.effectTag |= 4), r = !1); - } else h = t.stateNode, Ms(e, t), w = t.memoizedProps, h.props = t.type === t.elementType ? w : nn(t.type, w), W = h.context, typeof (V = n.contextType) == "object" && V !== null ? V = Ln(V) : V = he(t, V = de(n) ? ue : Y.current), (Re = typeof (ce = n.getDerivedStateFromProps) == "function" || typeof h.getSnapshotBeforeUpdate == "function") || typeof h.UNSAFE_componentWillReceiveProps != "function" && typeof h.componentWillReceiveProps != "function" || (w !== r || W !== V) && Pl(t, h, r, V), uo = !1, W = t.memoizedState, h.state = W, $i(t, r, h, a), Ve = t.memoizedState, w !== r || W !== Ve || ie.current || uo ? (typeof ce == "function" && (Oa(t, n, ce, r), Ve = t.memoizedState), (ce = uo || Ol(t, n, w, r, W, Ve, V)) ? (Re || typeof h.UNSAFE_componentWillUpdate != "function" && typeof h.componentWillUpdate != "function" || (typeof h.componentWillUpdate == "function" && h.componentWillUpdate(r, Ve, V), typeof h.UNSAFE_componentWillUpdate == "function" && h.UNSAFE_componentWillUpdate(r, Ve, V)), typeof h.componentDidUpdate == "function" && (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate == "function" && (t.effectTag |= 256)) : (typeof h.componentDidUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 256), t.memoizedProps = r, t.memoizedState = Ve), h.props = r, h.state = Ve, h.context = V, r = ce) : (typeof h.componentDidUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 256), r = !1); + h.state = Ve, Bi(t, r, h, a), W = t.memoizedState, w !== r || Ve !== W || ie.current || uo ? (typeof ce == "function" && (Oa(t, n, ce, r), W = t.memoizedState), (w = uo || Ol(t, n, w, r, Ve, W, V)) ? (Re || typeof h.UNSAFE_componentWillMount != "function" && typeof h.componentWillMount != "function" || (typeof h.componentWillMount == "function" && h.componentWillMount(), typeof h.UNSAFE_componentWillMount == "function" && h.UNSAFE_componentWillMount()), typeof h.componentDidMount == "function" && (t.effectTag |= 4)) : (typeof h.componentDidMount == "function" && (t.effectTag |= 4), t.memoizedProps = r, t.memoizedState = W), h.props = r, h.state = W, h.context = V, r = w) : (typeof h.componentDidMount == "function" && (t.effectTag |= 4), r = !1); + } else h = t.stateNode, Ms(e, t), w = t.memoizedProps, h.props = t.type === t.elementType ? w : nn(t.type, w), W = h.context, typeof (V = n.contextType) == "object" && V !== null ? V = Ln(V) : V = he(t, V = de(n) ? ue : Y.current), (Re = typeof (ce = n.getDerivedStateFromProps) == "function" || typeof h.getSnapshotBeforeUpdate == "function") || typeof h.UNSAFE_componentWillReceiveProps != "function" && typeof h.componentWillReceiveProps != "function" || (w !== r || W !== V) && Pl(t, h, r, V), uo = !1, W = t.memoizedState, h.state = W, Bi(t, r, h, a), Ve = t.memoizedState, w !== r || W !== Ve || ie.current || uo ? (typeof ce == "function" && (Oa(t, n, ce, r), Ve = t.memoizedState), (ce = uo || Ol(t, n, w, r, W, Ve, V)) ? (Re || typeof h.UNSAFE_componentWillUpdate != "function" && typeof h.componentWillUpdate != "function" || (typeof h.componentWillUpdate == "function" && h.componentWillUpdate(r, Ve, V), typeof h.UNSAFE_componentWillUpdate == "function" && h.UNSAFE_componentWillUpdate(r, Ve, V)), typeof h.componentDidUpdate == "function" && (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate == "function" && (t.effectTag |= 256)) : (typeof h.componentDidUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 256), t.memoizedProps = r, t.memoizedState = Ve), h.props = r, h.state = Ve, h.context = V, r = ce) : (typeof h.componentDidUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 4), typeof h.getSnapshotBeforeUpdate != "function" || w === e.memoizedProps && W === e.memoizedState || (t.effectTag |= 256), r = !1); return Gs(e, t, n, r, p, a); } function Gs(e, t, n, r, a, p) { Kl(e, t); var h = !!(64 & t.effectTag); - if (!r && !h) return a && $e(t, n, !1), Br(e, t, p); + if (!r && !h) return a && Be(t, n, !1), $r(e, t, p); r = t.stateNode, Vc.current = t; var w = h && typeof n.getDerivedStateFromError != "function" ? null : r.render(); - return t.effectTag |= 1, e !== null && h ? (t.child = di(t, e.child, null, p), t.child = di(t, null, w, p)) : Fn(e, t, w, p), t.memoizedState = r.state, a && $e(t, n, !0), t.child; + return t.effectTag |= 1, e !== null && h ? (t.child = di(t, e.child, null, p), t.child = di(t, null, w, p)) : Un(e, t, w, p), t.memoizedState = r.state, a && Be(t, n, !0), t.child; } function Yl(e) { var t = e.stateNode; @@ -4531,8 +4605,8 @@ https://fb.me/react-async-component-lifecycle-hooks`); var r, a = t.mode, p = t.pendingProps, h = Ct.current, w = !1; if ((r = !!(64 & t.effectTag)) || (r = !!(2 & h) && (e === null || e.memoizedState !== null)), r ? (w = !0, t.effectTag &= -65) : e !== null && e.memoizedState === null || p.fallback === void 0 || p.unstable_avoidThisFallback === !0 || (h |= 1), z(Ct, 1 & h), e === null) { if (p.fallback !== void 0 && Qs(t), w) { - if (w = p.fallback, (p = yo(null, a, 0, null)).return = t, !(2 & t.mode)) for (e = t.memoizedState !== null ? t.child.child : t.child, p.child = e; e !== null; ) e.return = p, e = e.sibling; - return (n = yo(w, a, n, null)).return = t, p.sibling = n, t.memoizedState = Js, t.child = p, n; + if (w = p.fallback, (p = bo(null, a, 0, null)).return = t, !(2 & t.mode)) for (e = t.memoizedState !== null ? t.child.child : t.child, p.child = e; e !== null; ) e.return = p, e = e.sibling; + return (n = bo(w, a, n, null)).return = t, p.sibling = n, t.memoizedState = Js, t.child = p, n; } return a = p.children, t.memoizedState = null, t.child = As(t, null, a, n); } @@ -4544,8 +4618,8 @@ https://fb.me/react-async-component-lifecycle-hooks`); return n = di(t, e.child, p.children, n), t.memoizedState = null, t.child = n; } if (e = e.child, w) { - if (w = p.fallback, (p = yo(null, a, 0, null)).return = t, p.child = e, e !== null && (e.return = p), !(2 & t.mode)) for (e = t.memoizedState !== null ? t.child.child : t.child, p.child = e; e !== null; ) e.return = p, e = e.sibling; - return (n = yo(w, a, n, null)).return = t, p.sibling = n, n.effectTag |= 2, p.childExpirationTime = 0, t.memoizedState = Js, t.child = p, n; + if (w = p.fallback, (p = bo(null, a, 0, null)).return = t, p.child = e, e !== null && (e.return = p), !(2 & t.mode)) for (e = t.memoizedState !== null ? t.child.child : t.child, p.child = e; e !== null; ) e.return = p, e = e.sibling; + return (n = bo(w, a, n, null)).return = t, p.sibling = n, n.effectTag |= 2, p.childExpirationTime = 0, t.memoizedState = Js, t.child = p, n; } return t.memoizedState = null, t.child = di(t, e, p.children, n); } @@ -4560,7 +4634,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } function tc(e, t, n) { var r = t.pendingProps, a = r.revealOrder, p = r.tail; - if (Fn(e, t, r.children, n), 2 & (r = Ct.current)) r = 1 & r | 2, t.effectTag |= 64; + if (Un(e, t, r.children, n), 2 & (r = Ct.current)) r = 1 & r | 2, t.effectTag |= 64; else { if (e !== null && 64 & e.effectTag) e: for (e = t.child; e !== null; ) { if (e.tag === 13) e.memoizedState !== null && ec(e, n); @@ -4602,7 +4676,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); else t.memoizedState = null; return t.child; } - function Br(e, t, n) { + function $r(e, t, n) { e !== null && (t.dependencies = e.dependencies); var r = t.expirationTime; if (r !== 0 && es(r), t.childExpirationTime < n) return null; @@ -4644,7 +4718,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); case 17: return de(t.type) && Oe(), null; case 3: - return pi(), x(ie), x(Y), (n = t.stateNode).pendingContext && (n.context = n.pendingContext, n.pendingContext = null), e !== null && e.child !== null || !Fa(t) || (t.effectTag |= 4), Zs(t), null; + return pi(), x(ie), x(Y), (n = t.stateNode).pendingContext && (n.context = n.pendingContext, n.pendingContext = null), e !== null && e.child !== null || !Ua(t) || (t.effectTag |= 4), Zs(t), null; case 5: Ls(t), n = Ho(Yi.current); var a = t.type; @@ -4654,7 +4728,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (t.stateNode === null) throw Error(m(166)); return null; } - if (e = Ho(_r.current), Fa(t)) { + if (e = Ho(_r.current), Ua(t)) { r = t.stateNode, a = t.type; var p = t.memoizedProps; switch (r[vr] = t, r[ri] = p, a) { @@ -4780,11 +4854,11 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (e && t.stateNode != null) Zl(e, t, e.memoizedProps, r); else { if (typeof r != "string" && t.stateNode === null) throw Error(m(166)); - n = Ho(Yi.current), Ho(_r.current), Fa(t) ? (n = t.stateNode, r = t.memoizedProps, n[vr] = t, n.nodeValue !== r && (t.effectTag |= 4)) : ((n = (n.nodeType === 9 ? n : n.ownerDocument).createTextNode(r))[vr] = t, t.stateNode = n); + n = Ho(Yi.current), Ho(_r.current), Ua(t) ? (n = t.stateNode, r = t.memoizedProps, n[vr] = t, n.nodeValue !== r && (t.effectTag |= 4)) : ((n = (n.nodeType === 9 ? n : n.ownerDocument).createTextNode(r))[vr] = t, t.stateNode = n); } return null; case 13: - return x(Ct), r = t.memoizedState, 64 & t.effectTag ? (t.expirationTime = n, t) : (n = r !== null, r = !1, e === null ? t.memoizedProps.fallback !== void 0 && Fa(t) : (r = (a = e.memoizedState) !== null, n || a === null || (a = e.child.sibling) !== null && ((p = t.firstEffect) !== null ? (t.firstEffect = a, a.nextEffect = p) : (t.firstEffect = t.lastEffect = a, a.nextEffect = null), a.effectTag = 8)), n && !r && 2 & t.mode && (e === null && t.memoizedProps.unstable_avoidThisFallback !== !0 || 1 & Ct.current ? Vt === Wo && (Vt = $a) : (Vt !== Wo && Vt !== $a || (Vt = Wa), Gi !== 0 && Cn !== null && (Zo(Cn, dn), Tc(Cn, Gi)))), (n || r) && (t.effectTag |= 4), null); + return x(Ct), r = t.memoizedState, 64 & t.effectTag ? (t.expirationTime = n, t) : (n = r !== null, r = !1, e === null ? t.memoizedProps.fallback !== void 0 && Ua(t) : (r = (a = e.memoizedState) !== null, n || a === null || (a = e.child.sibling) !== null && ((p = t.firstEffect) !== null ? (t.firstEffect = a, a.nextEffect = p) : (t.firstEffect = t.lastEffect = a, a.nextEffect = null), a.effectTag = 8)), n && !r && 2 & t.mode && (e === null && t.memoizedProps.unstable_avoidThisFallback !== !0 || 1 & Ct.current ? Vt === Wo && (Vt = Ba) : (Vt !== Wo && Vt !== Ba || (Vt = Wa), Gi !== 0 && Cn !== null && (Zo(Cn, dn), Tc(Cn, Gi)))), (n || r) && (t.effectTag |= 4), null); case 4: return pi(), Zs(t), null; case 10: @@ -4810,7 +4884,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); } throw Error(m(156, t.tag)); } - function Bc(e) { + function $c(e) { switch (e.tag) { case 1: de(e.type) && Oe(); @@ -4886,7 +4960,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); }, Zl = function(e, t, n, r) { n !== r && (t.effectTag |= 4); }; - var $c = typeof WeakSet == "function" ? WeakSet : Set; + var Bc = typeof WeakSet == "function" ? WeakSet : Set; function nl(e, t) { var n = t.source, r = t.stack; r === null && n !== null && (r = zt(n)), n !== null && Kt(n.type), t = t.value, e !== null && e.tag === 1 && Kt(e.type); @@ -5212,7 +5286,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (t !== null) { e.updateQueue = null; var n = e.stateNode; - n === null && (n = e.stateNode = new $c()), t.forEach(function(r) { + n === null && (n = e.stateNode = new Bc()), t.forEach(function(r) { var a = tu.bind(null, e, r); n.has(r) || (n.add(r), r.then(a, a)); }); @@ -5242,26 +5316,26 @@ https://fb.me/react-async-component-lifecycle-hooks`); this.componentDidCatch(t.value, { componentStack: h !== null ? h : "" }); }), n; } - var fc, Qc = Math.ceil, Ha = et.ReactCurrentDispatcher, hc = et.ReactCurrentOwner, Ft = 0, al = 8, ar = 16, xr = 32, Wo = 0, Ba = 1, mc = 2, $a = 3, Wa = 4, sl = 5, We = Ft, Cn = null, qe = null, dn = 0, Vt = Wo, qa = null, $r = 1073741823, Xi = 1073741823, Ka = null, Gi = 0, Qa = !1, ll = 0, gc = 500, Me = null, Ya = !1, cl = null, go = null, Xa = !1, Zi = null, Ji = 90, qo = null, ea = 0, ul = null, Ga = 0; + var fc, Qc = Math.ceil, Ha = et.ReactCurrentDispatcher, hc = et.ReactCurrentOwner, Ut = 0, al = 8, ar = 16, xr = 32, Wo = 0, $a = 1, mc = 2, Ba = 3, Wa = 4, sl = 5, We = Ut, Cn = null, qe = null, dn = 0, Vt = Wo, qa = null, Br = 1073741823, Xi = 1073741823, Ka = null, Gi = 0, Qa = !1, ll = 0, gc = 500, Me = null, Ya = !1, cl = null, go = null, Xa = !1, Zi = null, Ji = 90, qo = null, ea = 0, ul = null, Ga = 0; function Sr() { - return (We & (ar | xr)) !== Ft ? 1073741821 - (Nt() / 10 | 0) : Ga !== 0 ? Ga : Ga = 1073741821 - (Nt() / 10 | 0); + return (We & (ar | xr)) !== Ut ? 1073741821 - (Nt() / 10 | 0) : Ga !== 0 ? Ga : Ga = 1073741821 - (Nt() / 10 | 0); } function Ko(e, t, n) { if (!(2 & (t = t.mode))) return 1073741823; - var r = Ut(); + var r = Ft(); if (!(4 & t)) return r === 99 ? 1073741823 : 1073741822; - if ((We & ar) !== Ft) return dn; - if (n !== null) e = Uo(e, 0 | n.timeoutMs || 5e3, 250); + if ((We & ar) !== Ut) return dn; + if (n !== null) e = Fo(e, 0 | n.timeoutMs || 5e3, 250); else switch (r) { case 99: e = 1073741823; break; case 98: - e = Uo(e, 150, 100); + e = Fo(e, 150, 100); break; case 97: case 96: - e = Uo(e, 5e3, 250); + e = Fo(e, 5e3, 250); break; case 95: e = 2; @@ -5271,11 +5345,11 @@ https://fb.me/react-async-component-lifecycle-hooks`); } return Cn !== null && e === dn && --e, e; } - function bo(e, t) { + function yo(e, t) { if (50 < ea) throw ea = 0, ul = null, Error(m(185)); if ((e = Za(e, t)) !== null) { - var n = Ut(); - t === 1073741823 ? (We & al) !== Ft && (We & (ar | xr)) === Ft ? dl(e) : (Tn(e), We === Ft && tn()) : Tn(e), (4 & We) === Ft || n !== 98 && n !== 99 || (qo === null ? qo = /* @__PURE__ */ new Map([[e, t]]) : ((n = qo.get(e)) === void 0 || n > t) && qo.set(e, t)); + var n = Ft(); + t === 1073741823 ? (We & al) !== Ut && (We & (ar | xr)) === Ut ? dl(e) : (Tn(e), We === Ut && tn()) : Tn(e), (4 & We) === Ut || n !== 98 && n !== 99 || (qo === null ? qo = /* @__PURE__ */ new Map([[e, t]]) : ((n = qo.get(e)) === void 0 || n > t) && qo.set(e, t)); } } function Za(e, t) { @@ -5300,7 +5374,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); return 2 >= (e = n > (e = e.nextKnownPendingLevel) ? n : e) && t !== e ? 0 : e; } function Tn(e) { - if (e.lastExpiredTime !== 0) e.callbackExpirationTime = 1073741823, e.callbackPriority = 99, e.callbackNode = Bi(dl.bind(null, e)); + if (e.lastExpiredTime !== 0) e.callbackExpirationTime = 1073741823, e.callbackPriority = 99, e.callbackNode = $i(dl.bind(null, e)); else { var t = Ja(e), n = e.callbackNode; if (t === 0) n !== null && (e.callbackNode = null, e.callbackExpirationTime = 0, e.callbackPriority = 90); @@ -5311,15 +5385,15 @@ https://fb.me/react-async-component-lifecycle-hooks`); if (e.callbackExpirationTime === t && a >= r) return; n !== jn && vt(n); } - e.callbackExpirationTime = t, e.callbackPriority = r, t = t === 1073741823 ? Bi(dl.bind(null, e)) : Hi(r, bc.bind(null, e), { timeout: 10 * (1073741821 - t) - Nt() }), e.callbackNode = t; + e.callbackExpirationTime = t, e.callbackPriority = r, t = t === 1073741823 ? $i(dl.bind(null, e)) : Hi(r, yc.bind(null, e), { timeout: 10 * (1073741821 - t) - Nt() }), e.callbackNode = t; } } } - function bc(e, t) { - if (Ga = 0, t) return yl(e, t = Sr()), Tn(e), null; + function yc(e, t) { + if (Ga = 0, t) return bl(e, t = Sr()), Tn(e), null; var n = Ja(e); if (n !== 0) { - if (t = e.callbackNode, (We & (ar | xr)) !== Ft) throw Error(m(327)); + if (t = e.callbackNode, (We & (ar | xr)) !== Ut) throw Error(m(327)); if (mi(), e === Cn && n === dn || Qo(e, n), qe !== null) { var r = We; We |= ar; @@ -5329,16 +5403,16 @@ https://fb.me/react-async-component-lifecycle-hooks`); } catch (w) { kc(e, w); } - if (ir(), We = r, Ha.current = a, Vt === Ba) throw t = qa, Qo(e, n), Zo(e, n), Tn(e), t; + if (ir(), We = r, Ha.current = a, Vt === $a) throw t = qa, Qo(e, n), Zo(e, n), Tn(e), t; if (qe === null) switch (a = e.finishedWork = e.current.alternate, e.finishedExpirationTime = n, r = Vt, Cn = null, r) { case Wo: - case Ba: + case $a: throw Error(m(345)); case mc: - yl(e, 2 < n ? 2 : n); + bl(e, 2 < n ? 2 : n); break; - case $a: - if (Zo(e, n), n === (r = e.lastSuspendedTime) && (e.nextKnownPendingLevel = pl(a)), $r === 1073741823 && 10 < (a = ll + gc - Nt())) { + case Ba: + if (Zo(e, n), n === (r = e.lastSuspendedTime) && (e.nextKnownPendingLevel = pl(a)), Br === 1073741823 && 10 < (a = ll + gc - Nt())) { if (Qa) { var p = e.lastPingedTime; if (p === 0 || p >= n) { @@ -5366,15 +5440,15 @@ https://fb.me/react-async-component-lifecycle-hooks`); e.lastPingedTime = r; break; } - if (Xi !== 1073741823 ? r = 10 * (1073741821 - Xi) - Nt() : $r === 1073741823 ? r = 0 : (r = 10 * (1073741821 - $r) - 5e3, 0 > (r = (a = Nt()) - r) && (r = 0), (n = 10 * (1073741821 - n) - a) < (r = (120 > r ? 120 : 480 > r ? 480 : 1080 > r ? 1080 : 1920 > r ? 1920 : 3e3 > r ? 3e3 : 4320 > r ? 4320 : 1960 * Qc(r / 1960)) - r) && (r = n)), 10 < r) { + if (Xi !== 1073741823 ? r = 10 * (1073741821 - Xi) - Nt() : Br === 1073741823 ? r = 0 : (r = 10 * (1073741821 - Br) - 5e3, 0 > (r = (a = Nt()) - r) && (r = 0), (n = 10 * (1073741821 - n) - a) < (r = (120 > r ? 120 : 480 > r ? 480 : 1080 > r ? 1080 : 1920 > r ? 1920 : 3e3 > r ? 3e3 : 4320 > r ? 4320 : 1960 * Qc(r / 1960)) - r) && (r = n)), 10 < r) { e.timeoutHandle = Di(Yo.bind(null, e), r); break; } Yo(e); break; case sl: - if ($r !== 1073741823 && Ka !== null) { - p = $r; + if (Br !== 1073741823 && Ka !== null) { + p = Br; var h = Ka; if (0 >= (r = 0 | h.busyMinDurationMs) ? r = 0 : (a = 0 | h.busyDelayMs, r = (p = Nt() - (10 * (1073741821 - p) - (0 | h.timeoutMs || 5e3))) <= a ? 0 : a + r - p), 10 < r) { Zo(e, n), e.timeoutHandle = Di(Yo.bind(null, e), r); @@ -5386,14 +5460,14 @@ https://fb.me/react-async-component-lifecycle-hooks`); default: throw Error(m(329)); } - if (Tn(e), e.callbackNode === t) return bc.bind(null, e); + if (Tn(e), e.callbackNode === t) return yc.bind(null, e); } } return null; } function dl(e) { var t = e.lastExpiredTime; - if (t = t !== 0 ? t : 1073741823, (We & (ar | xr)) !== Ft) throw Error(m(327)); + if (t = t !== 0 ? t : 1073741823, (We & (ar | xr)) !== Ut) throw Error(m(327)); if (mi(), e === Cn && t === dn || Qo(e, t), qe !== null) { var n = We; We |= ar; @@ -5403,19 +5477,19 @@ https://fb.me/react-async-component-lifecycle-hooks`); } catch (a) { kc(e, a); } - if (ir(), We = n, Ha.current = r, Vt === Ba) throw n = qa, Qo(e, t), Zo(e, t), Tn(e), n; + if (ir(), We = n, Ha.current = r, Vt === $a) throw n = qa, Qo(e, t), Zo(e, t), Tn(e), n; if (qe !== null) throw Error(m(261)); e.finishedWork = e.current.alternate, e.finishedExpirationTime = t, Cn = null, Yo(e), Tn(e); } return null; } - function yc(e, t) { + function bc(e, t) { var n = We; We |= 1; try { return e(t); } finally { - (We = n) === Ft && tn(); + (We = n) === Ut && tn(); } } function vc(e, t) { @@ -5424,7 +5498,7 @@ https://fb.me/react-async-component-lifecycle-hooks`); try { return e(t); } finally { - (We = n) === Ft && tn(); + (We = n) === Ut && tn(); } } function Qo(e, t) { @@ -5454,16 +5528,16 @@ https://fb.me/react-async-component-lifecycle-hooks`); } n = n.return; } - Cn = e, qe = Go(e.current, null), dn = t, Vt = Wo, qa = null, Xi = $r = 1073741823, Ka = null, Gi = 0, Qa = !1; + Cn = e, qe = Go(e.current, null), dn = t, Vt = Wo, qa = null, Xi = Br = 1073741823, Ka = null, Gi = 0, Qa = !1; } function kc(e, t) { for (; ; ) { try { - if (ir(), Ra.current = Ua, Ma) for (var n = Rt.memoizedState; n !== null; ) { + if (ir(), Ra.current = Fa, Ma) for (var n = Rt.memoizedState; n !== null; ) { var r = n.queue; r !== null && (r.pending = null), n = n.next; } - if (ho = 0, Xt = rn = Rt = null, Ma = !1, qe === null || qe.return === null) return Vt = Ba, qa = t, qe = null; + if (ho = 0, Xt = rn = Rt = null, Ma = !1, qe === null || qe.return === null) return Vt = $a, qa = t, qe = null; e: { var a = e, p = qe.return, h = qe, w = t; if (t = dn, h.effectTag |= 2048, h.firstEffect = h.lastEffect = null, w !== null && typeof w == "object" && typeof w.then == "function") { @@ -5532,8 +5606,8 @@ Add a component higher in the tree to provide a loading } while (Re !== null); } qe = xc(qe); - } catch (Ue) { - t = Ue; + } catch (Fe) { + t = Fe; continue; } break; @@ -5541,10 +5615,10 @@ Add a component higher in the tree to provide a loading } function wc() { var e = Ha.current; - return Ha.current = Ua, e === null ? Ua : e; + return Ha.current = Fa, e === null ? Fa : e; } function _c(e, t) { - e < $r && 2 < e && ($r = e), t !== null && e < Xi && 2 < e && (Xi = e, Ka = t); + e < Br && 2 < e && (Br = e), t !== null && e < Xi && 2 < e && (Xi = e, Ka = t); } function es(e) { e > Gi && (Gi = e); @@ -5564,7 +5638,7 @@ Add a component higher in the tree to provide a loading do { var t = qe.alternate; if (e = qe.return, 2048 & qe.effectTag) { - if ((t = Bc(qe)) !== null) return t.effectTag &= 2047, t; + if ((t = $c(qe)) !== null) return t.effectTag &= 2047, t; e !== null && (e.firstEffect = e.lastEffect = null, e.effectTag |= 2048); } else { if (t = Hc(t, qe, dn), dn === 1 || qe.childExpirationTime !== 1) { @@ -5587,14 +5661,14 @@ Add a component higher in the tree to provide a loading return t > (e = e.childExpirationTime) ? t : e; } function Yo(e) { - var t = Ut(); + var t = Ft(); return or(99, Gc.bind(null, e, t)), null; } function Gc(e, t) { do mi(); while (Zi !== null); - if ((We & (ar | xr)) !== Ft) throw Error(m(327)); + if ((We & (ar | xr)) !== Ut) throw Error(m(327)); var n = e.finishedWork, r = e.finishedExpirationTime; if (n === null) return null; if (e.finishedWork = null, e.finishedExpirationTime = 0, n === e.current) throw Error(m(177)); @@ -5688,8 +5762,8 @@ Add a component higher in the tree to provide a loading do try { for (ve = e; Me !== null; ) { - var Ue = Me.effectTag; - if (36 & Ue && qc(ve, Me.alternate, Me), 128 & Ue) { + var Fe = Me.effectTag; + if (36 & Fe && qc(ve, Me.alternate, Me), 128 & Fe) { xe = void 0; var at = Me.ref; if (at !== null) { @@ -5709,7 +5783,7 @@ Add a component higher in the tree to provide a loading if (Xa) Xa = !1, Zi = e, Ji = t; else for (Me = a; Me !== null; ) t = Me.nextEffect, Me.nextEffect = null, Me = t; if ((t = e.firstPendingTime) === 0 && (go = null), t === 1073741823 ? e === ul ? ea++ : (ea = 0, ul = e) : ea = 0, typeof fl == "function" && fl(n.stateNode, r), Tn(e), Ya) throw Ya = !1, e = cl, cl = null, e; - return (We & al) !== Ft || tn(), null; + return (We & al) !== Ut || tn(), null; } function Zc() { for (; Me !== null; ) { @@ -5728,7 +5802,7 @@ Add a component higher in the tree to provide a loading function Jc() { if (Zi === null) return !1; var e = Zi; - if (Zi = null, (We & (ar | xr)) !== Ft) throw Error(m(331)); + if (Zi = null, (We & (ar | xr)) !== Ut) throw Error(m(331)); var t = We; for (We |= xr, e = e.current.firstEffect; e !== null; ) { try { @@ -5770,7 +5844,7 @@ Add a component higher in the tree to provide a loading } function eu(e, t, n) { var r = e.pingCache; - r !== null && r.delete(t), Cn === e && dn === n ? Vt === Wa || Vt === $a && $r === 1073741823 && Nt() - ll < gc ? Qo(e, dn) : Qa = !0 : Cc(e, n) && ((t = e.lastPingedTime) !== 0 && t < n || (e.lastPingedTime = n, Tn(e))); + r !== null && r.delete(t), Cn === e && dn === n ? Vt === Wa || Vt === Ba && Br === 1073741823 && Nt() - ll < gc ? Qo(e, dn) : Qa = !0 : Cc(e, n) && ((t = e.lastPingedTime) !== 0 && t < n || (e.lastPingedTime = n, Tn(e))); } function tu(e, t) { var n = e.stateNode; @@ -5800,7 +5874,7 @@ Add a component higher in the tree to provide a loading r = t.memoizedProps.value, a = t.type._context, z(Vr, a._currentValue), a._currentValue = r; break; case 13: - if (t.memoizedState !== null) return (r = t.child.childExpirationTime) !== 0 && r >= n ? Jl(e, t, n) : (z(Ct, 1 & Ct.current), (t = Br(e, t, n)) !== null ? t.sibling : null); + if (t.memoizedState !== null) return (r = t.child.childExpirationTime) !== 0 && r >= n ? Jl(e, t, n) : (z(Ct, 1 & Ct.current), (t = $r(e, t, n)) !== null ? t.sibling : null); z(Ct, 1 & Ct.current); break; case 19: @@ -5810,7 +5884,7 @@ Add a component higher in the tree to provide a loading } if ((a = t.memoizedState) !== null && (a.rendering = null, a.tail = null), z(Ct, Ct.current), !r) return null; } - return Br(e, t, n); + return $r(e, t, n); } Er = !1; } @@ -5825,7 +5899,7 @@ Add a component higher in the tree to provide a loading t.memoizedState = a.state !== null && a.state !== void 0 ? a.state : null, Rs(t); var h = r.getDerivedStateFromProps; typeof h == "function" && Oa(t, r, h, e), a.updater = Na, t.stateNode = a, a._reactInternalFiber = t, zs(t, r, e, n), t = Gs(null, t, r, !0, p, n); - } else t.tag = 0, Fn(null, t, a, n), t = t.child; + } else t.tag = 0, Un(null, t, a, n), t = t.child; return t; case 16: e: { @@ -5855,7 +5929,7 @@ Add a component higher in the tree to provide a loading t = Ql(null, t, a, e, n); break e; case 11: - t = $l(null, t, a, e, n); + t = Bl(null, t, a, e, n); break e; case 14: t = Wl(null, t, a, nn(a.type, e), r, n); @@ -5870,35 +5944,35 @@ Add a component higher in the tree to provide a loading return r = t.type, a = t.pendingProps, Ql(e, t, r, a = t.elementType === r ? a : nn(r, a), n); case 3: if (Yl(t), r = t.updateQueue, e === null || r === null) throw Error(m(282)); - if (r = t.pendingProps, a = (a = t.memoizedState) !== null ? a.element : null, Ms(e, t), $i(t, r, null, n), (r = t.memoizedState.element) === a) Ys(), t = Br(e, t, n); + if (r = t.pendingProps, a = (a = t.memoizedState) !== null ? a.element : null, Ms(e, t), Bi(t, r, null, n), (r = t.memoizedState.element) === a) Ys(), t = $r(e, t, n); else { - if ((a = t.stateNode.hydrate) && (mo = Ar(t.stateNode.containerInfo.firstChild), Hr = t, a = $o = !0), a) for (n = As(t, null, r, n), t.child = n; n; ) n.effectTag = -3 & n.effectTag | 1024, n = n.sibling; - else Fn(e, t, r, n), Ys(); + if ((a = t.stateNode.hydrate) && (mo = Ar(t.stateNode.containerInfo.firstChild), Hr = t, a = Bo = !0), a) for (n = As(t, null, r, n), t.child = n; n; ) n.effectTag = -3 & n.effectTag | 1024, n = n.sibling; + else Un(e, t, r, n), Ys(); t = t.child; } return t; case 5: - return Il(t), e === null && Qs(t), r = t.type, a = t.pendingProps, p = e !== null ? e.memoizedProps : null, h = a.children, Pi(r, a) ? h = null : p !== null && Pi(r, p) && (t.effectTag |= 16), Kl(e, t), 4 & t.mode && n !== 1 && a.hidden ? (t.expirationTime = t.childExpirationTime = 1, t = null) : (Fn(e, t, h, n), t = t.child), t; + return Il(t), e === null && Qs(t), r = t.type, a = t.pendingProps, p = e !== null ? e.memoizedProps : null, h = a.children, Pi(r, a) ? h = null : p !== null && Pi(r, p) && (t.effectTag |= 16), Kl(e, t), 4 & t.mode && n !== 1 && a.hidden ? (t.expirationTime = t.childExpirationTime = 1, t = null) : (Un(e, t, h, n), t = t.child), t; case 6: return e === null && Qs(t), null; case 13: return Jl(e, t, n); case 4: - return js(t, t.stateNode.containerInfo), r = t.pendingProps, e === null ? t.child = di(t, null, r, n) : Fn(e, t, r, n), t.child; + return js(t, t.stateNode.containerInfo), r = t.pendingProps, e === null ? t.child = di(t, null, r, n) : Un(e, t, r, n), t.child; case 11: - return r = t.type, a = t.pendingProps, $l(e, t, r, a = t.elementType === r ? a : nn(r, a), n); + return r = t.type, a = t.pendingProps, Bl(e, t, r, a = t.elementType === r ? a : nn(r, a), n); case 7: - return Fn(e, t, t.pendingProps, n), t.child; + return Un(e, t, t.pendingProps, n), t.child; case 8: case 12: - return Fn(e, t, t.pendingProps.children, n), t.child; + return Un(e, t, t.pendingProps.children, n), t.child; case 10: e: { r = t.type._context, a = t.pendingProps, h = t.memoizedProps, p = a.value; var w = t.type._context; if (z(Vr, w._currentValue), w._currentValue = p, h !== null) if (w = h.value, (p = rr(w, p) ? 0 : 0 | (typeof r._calculateChangedBits == "function" ? r._calculateChangedBits(w, p) : 1073741823)) === 0) { if (h.children === a.children && !ie.current) { - t = Br(e, t, n); + t = $r(e, t, n); break e; } } else for ((w = t.child) !== null && (w.return = t); w !== null; ) { @@ -5927,11 +6001,11 @@ Add a component higher in the tree to provide a loading } w = h; } - Fn(e, t, a.children, n), t = t.child; + Un(e, t, a.children, n), t = t.child; } return t; case 9: - return a = t.type, r = (p = t.pendingProps).children, ui(t, n), r = r(a = Ln(a, p.unstable_observedBits)), t.effectTag |= 1, Fn(e, t, r, n), t.child; + return a = t.type, r = (p = t.pendingProps).children, ui(t, n), r = r(a = Ln(a, p.unstable_observedBits)), t.effectTag |= 1, Un(e, t, r, n), t.child; case 14: return p = nn(a = t.type, t.pendingProps), Wl(e, t, a, p = nn(a.type, p), r, n); case 15: @@ -5963,22 +6037,22 @@ Add a component higher in the tree to provide a loading else if (typeof e == "string") h = 5; else e: switch (e) { case Nn: - return yo(n.children, a, p, t); + return bo(n.children, a, p, t); case pn: h = 8, a |= 7; break; case wo: h = 8, a |= 1; break; - case Bn: - return (e = Cr(12, n, t, 8 | a)).elementType = Bn, e.type = Bn, e.expirationTime = p, e; + case $n: + return (e = Cr(12, n, t, 8 | a)).elementType = $n, e.type = $n, e.expirationTime = p, e; case Ht: return (e = Cr(13, n, t, a)).type = Ht, e.elementType = Ht, e.expirationTime = p, e; case Wr: return (e = Cr(19, n, t, a)).elementType = Wr, e.expirationTime = p, e; default: if (typeof e == "object" && e !== null) switch (e.$$typeof) { - case $n: + case Bn: h = 10; break e; case an: @@ -6001,13 +6075,13 @@ Add a component higher in the tree to provide a loading } return (t = Cr(h, n, t, a)).elementType = e, t.type = r, t.expirationTime = p, t; } - function yo(e, t, n, r) { + function bo(e, t, n, r) { return (e = Cr(7, e, r, t)).expirationTime = n, e; } function gl(e, t, n) { return (e = Cr(6, e, null, t)).expirationTime = n, e; } - function bl(e, t, n) { + function yl(e, t, n) { return (t = Cr(4, e.children !== null ? e.children : [], e.key, t)).expirationTime = n, t.stateNode = { containerInfo: e.containerInfo, pendingChildren: null, implementation: e.implementation }, t; } function ru(e, t, n) { @@ -6026,7 +6100,7 @@ Add a component higher in the tree to provide a loading var n = e.firstSuspendedTime; n !== 0 && (t >= n ? e.firstSuspendedTime = e.lastSuspendedTime = e.nextKnownPendingLevel = 0 : t >= e.lastSuspendedTime && (e.lastSuspendedTime = t + 1), t > e.nextKnownPendingLevel && (e.nextKnownPendingLevel = t)); } - function yl(e, t) { + function bl(e, t) { var n = e.lastExpiredTime; (n === 0 || n > t) && (e.lastExpiredTime = t); } @@ -6061,7 +6135,7 @@ Add a component higher in the tree to provide a loading } n = w; } else n = K; - return t.context === null ? t.context = n : t.pendingContext = n, (t = po(p, h)).payload = { element: e }, (r = r === void 0 ? null : r) !== null && (t.callback = r), fo(a, t), bo(a, p), p; + return t.context === null ? t.context = n : t.pendingContext = n, (t = po(p, h)).payload = { element: e }, (r = r === void 0 ? null : r) !== null && (t.callback = r), fo(a, t), yo(a, p), p; } function vl(e) { return (e = e.current).child ? (e.child.tag, e.child.stateNode) : null; @@ -6132,15 +6206,15 @@ Add a component higher in the tree to provide a loading }); }, Ze = function(e) { if (e.tag === 13) { - var t = Uo(Sr(), 150, 100); - bo(e, t), kl(e, t); + var t = Fo(Sr(), 150, 100); + yo(e, t), kl(e, t); } }, Yn = function(e) { - e.tag === 13 && (bo(e, 3), kl(e, 3)); + e.tag === 13 && (yo(e, 3), kl(e, 3)); }, vn = function(e) { if (e.tag === 13) { var t = Sr(); - bo(e, t = Ko(t, e, null)), kl(e, t); + yo(e, t = Ko(t, e, null)), kl(e, t); } }, Ee = function(e, t, n) { switch (t) { @@ -6163,20 +6237,20 @@ Add a component higher in the tree to provide a loading case "select": (t = n.value) != null && Dn(e, !!n.multiple, t, !1); } - }, ke = yc, Ne = function(e, t, n, r, a) { + }, ke = bc, Ne = function(e, t, n, r, a) { var p = We; We |= 4; try { return or(98, e.bind(null, t, n, r, a)); } finally { - (We = p) === Ft && tn(); + (We = p) === Ut && tn(); } - }, Fe = function() { - (We & (1 | ar | xr)) === Ft && ((function() { + }, Ue = function() { + (We & (1 | ar | xr)) === Ut && ((function() { if (qo !== null) { var e = qo; qo = null, e.forEach(function(t, n) { - yl(n, t), Tn(n); + bl(n, t), Tn(n); }), tn(); } })(), mi()); @@ -6186,12 +6260,12 @@ Add a component higher in the tree to provide a loading try { return e(t); } finally { - (We = n) === Ft && tn(); + (We = n) === Ut && tn(); } }; - var ou = { Events: [kr, Zn, Ri, ae, S, Bt, function(e) { + var ou = { Events: [kr, Zn, Ri, ae, S, $t, function(e) { jt(e, zi); - }, le, me, Po, bn, mi, { current: !1 }] }; + }, le, me, Po, yn, mi, { current: !1 }] }; (function(e) { var t = e.findFiberByHostInstance; (function(n) { @@ -6226,7 +6300,7 @@ Add a component higher in the tree to provide a loading throw typeof e.render == "function" ? Error(m(188)) : Error(m(268, Object.keys(e))); return e = (e = ht(t)) === null ? null : e.stateNode; }, u.flushSync = function(e, t) { - if ((We & (ar | xr)) !== Ft) throw Error(m(187)); + if ((We & (ar | xr)) !== Ut) throw Error(m(187)); var n = We; We |= 1; try { @@ -6247,7 +6321,7 @@ Add a component higher in the tree to provide a loading e._reactRootContainer = null, e[Io] = null; }); }), !0); - }, u.unstable_batchedUpdates = yc, u.unstable_createPortal = function(e, t) { + }, u.unstable_batchedUpdates = bc, u.unstable_createPortal = function(e, t) { return Nc(e, t, 2 < arguments.length && arguments[2] !== void 0 ? arguments[2] : null); }, u.unstable_renderSubtreeIntoContainer = function(e, t, n, r) { if (!ta(n)) throw Error(m(200)); @@ -6279,15 +6353,15 @@ Add a component higher in the tree to provide a loading throw R.name = "Invariant Violation", R; } } - function y() { + function b() { return m; } m.isRequired = m; - var v = { array: m, bigint: m, bool: m, func: m, number: m, object: m, string: m, symbol: m, any: m, arrayOf: y, element: m, elementType: m, instanceOf: y, node: m, objectOf: y, oneOf: y, oneOfType: y, shape: y, exact: y, checkPropTypes: C, resetWarningCache: d }; + var v = { array: m, bigint: m, bool: m, func: m, number: m, object: m, string: m, symbol: m, any: m, arrayOf: b, element: m, elementType: m, instanceOf: b, node: m, objectOf: b, oneOf: b, oneOfType: b, shape: b, exact: b, checkPropTypes: C, resetWarningCache: d }; return v.PropTypes = v, v; }; }, 2799: (i, u) => { - var f = typeof Symbol == "function" && Symbol.for, k = f ? Symbol.for("react.element") : 60103, d = f ? Symbol.for("react.portal") : 60106, C = f ? Symbol.for("react.fragment") : 60107, m = f ? Symbol.for("react.strict_mode") : 60108, y = f ? Symbol.for("react.profiler") : 60114, v = f ? Symbol.for("react.provider") : 60109, N = f ? Symbol.for("react.context") : 60110, I = f ? Symbol.for("react.async_mode") : 60111, D = f ? Symbol.for("react.concurrent_mode") : 60111, L = f ? Symbol.for("react.forward_ref") : 60112, se = f ? Symbol.for("react.suspense") : 60113, ee = f ? Symbol.for("react.suspense_list") : 60120, R = f ? Symbol.for("react.memo") : 60115, U = f ? Symbol.for("react.lazy") : 60116, H = f ? Symbol.for("react.block") : 60121, ne = f ? Symbol.for("react.fundamental") : 60117, pe = f ? Symbol.for("react.responder") : 60118, oe = f ? Symbol.for("react.scope") : 60119; + var f = typeof Symbol == "function" && Symbol.for, k = f ? Symbol.for("react.element") : 60103, d = f ? Symbol.for("react.portal") : 60106, C = f ? Symbol.for("react.fragment") : 60107, m = f ? Symbol.for("react.strict_mode") : 60108, b = f ? Symbol.for("react.profiler") : 60114, v = f ? Symbol.for("react.provider") : 60109, N = f ? Symbol.for("react.context") : 60110, I = f ? Symbol.for("react.async_mode") : 60111, D = f ? Symbol.for("react.concurrent_mode") : 60111, L = f ? Symbol.for("react.forward_ref") : 60112, se = f ? Symbol.for("react.suspense") : 60113, ee = f ? Symbol.for("react.suspense_list") : 60120, R = f ? Symbol.for("react.memo") : 60115, F = f ? Symbol.for("react.lazy") : 60116, H = f ? Symbol.for("react.block") : 60121, ne = f ? Symbol.for("react.fundamental") : 60117, pe = f ? Symbol.for("react.responder") : 60118, oe = f ? Symbol.for("react.scope") : 60119; function fe(S) { if (typeof S == "object" && S !== null) { var j = S.$$typeof; @@ -6297,7 +6371,7 @@ Add a component higher in the tree to provide a loading case I: case D: case C: - case y: + case b: case m: case se: return S; @@ -6305,7 +6379,7 @@ Add a component higher in the tree to provide a loading switch (S = S && S.$$typeof) { case N: case L: - case U: + case F: case R: case v: return S; @@ -6321,7 +6395,7 @@ Add a component higher in the tree to provide a loading function ge(S) { return fe(S) === D; } - u.AsyncMode = I, u.ConcurrentMode = D, u.ContextConsumer = N, u.ContextProvider = v, u.Element = k, u.ForwardRef = L, u.Fragment = C, u.Lazy = U, u.Memo = R, u.Portal = d, u.Profiler = y, u.StrictMode = m, u.Suspense = se, u.isAsyncMode = function(S) { + u.AsyncMode = I, u.ConcurrentMode = D, u.ContextConsumer = N, u.ContextProvider = v, u.Element = k, u.ForwardRef = L, u.Fragment = C, u.Lazy = F, u.Memo = R, u.Portal = d, u.Profiler = b, u.StrictMode = m, u.Suspense = se, u.isAsyncMode = function(S) { return ge(S) || fe(S) === I; }, u.isConcurrentMode = ge, u.isContextConsumer = function(S) { return fe(S) === N; @@ -6334,19 +6408,19 @@ Add a component higher in the tree to provide a loading }, u.isFragment = function(S) { return fe(S) === C; }, u.isLazy = function(S) { - return fe(S) === U; + return fe(S) === F; }, u.isMemo = function(S) { return fe(S) === R; }, u.isPortal = function(S) { return fe(S) === d; }, u.isProfiler = function(S) { - return fe(S) === y; + return fe(S) === b; }, u.isStrictMode = function(S) { return fe(S) === m; }, u.isSuspense = function(S) { return fe(S) === se; }, u.isValidElementType = function(S) { - return typeof S == "string" || typeof S == "function" || S === C || S === D || S === y || S === m || S === se || S === ee || typeof S == "object" && S !== null && (S.$$typeof === U || S.$$typeof === R || S.$$typeof === v || S.$$typeof === N || S.$$typeof === L || S.$$typeof === ne || S.$$typeof === pe || S.$$typeof === oe || S.$$typeof === H); + return typeof S == "string" || typeof S == "function" || S === C || S === D || S === b || S === m || S === se || S === ee || typeof S == "object" && S !== null && (S.$$typeof === F || S.$$typeof === R || S.$$typeof === v || S.$$typeof === N || S.$$typeof === L || S.$$typeof === ne || S.$$typeof === pe || S.$$typeof === oe || S.$$typeof === H); }, u.typeOf = fe; }, 2841: (i, u, f) => { f.r(u), f.d(u, { default: () => C }); @@ -6356,20 +6430,20 @@ Add a component higher in the tree to provide a loading d.push([i.id, ".ck-inspector .ck-inspector-checkbox{vertical-align:middle}", ""]); const C = d; }, 3514: (i, u) => { - Object.defineProperty(u, "__esModule", { value: !0 }), u.getPrefix = k, u.browserPrefixToKey = d, u.browserPrefixToStyle = function(m, y) { - return y ? "-".concat(y.toLowerCase(), "-").concat(m) : m; + Object.defineProperty(u, "__esModule", { value: !0 }), u.getPrefix = k, u.browserPrefixToKey = d, u.browserPrefixToStyle = function(m, b) { + return b ? "-".concat(b.toLowerCase(), "-").concat(m) : m; }, u.default = void 0; var f = ["Moz", "Webkit", "O", "ms"]; function k() { var m = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "transform"; if (typeof window > "u" || window.document === void 0) return ""; - var y = window.document.documentElement.style; - if (m in y) return ""; - for (var v = 0; v < f.length; v++) if (d(m, f[v]) in y) return f[v]; + var b = window.document.documentElement.style; + if (m in b) return ""; + for (var v = 0; v < f.length; v++) if (d(m, f[v]) in b) return f[v]; return ""; } - function d(m, y) { - return y ? "".concat(y).concat((function(v) { + function d(m, b) { + return b ? "".concat(b).concat((function(v) { for (var N = "", I = !0, D = 0; D < v.length; D++) I ? (N += v[D].toUpperCase(), I = !1) : v[D] === "-" ? I = !0 : N += v[D]; return N; })(m)) : m; @@ -6389,32 +6463,32 @@ Add a component higher in the tree to provide a loading d.push([i.id, ".ck-inspector-side-pane{position:relative}", ""]); const C = d; }, 4146: (i, u, f) => { - var k = f(4363), d = { childContextTypes: !0, contextType: !0, contextTypes: !0, defaultProps: !0, displayName: !0, getDefaultProps: !0, getDerivedStateFromError: !0, getDerivedStateFromProps: !0, mixins: !0, propTypes: !0, type: !0 }, C = { name: !0, length: !0, prototype: !0, caller: !0, callee: !0, arguments: !0, arity: !0 }, m = { $$typeof: !0, compare: !0, defaultProps: !0, displayName: !0, propTypes: !0, type: !0 }, y = {}; + var k = f(4363), d = { childContextTypes: !0, contextType: !0, contextTypes: !0, defaultProps: !0, displayName: !0, getDefaultProps: !0, getDerivedStateFromError: !0, getDerivedStateFromProps: !0, mixins: !0, propTypes: !0, type: !0 }, C = { name: !0, length: !0, prototype: !0, caller: !0, callee: !0, arguments: !0, arity: !0 }, m = { $$typeof: !0, compare: !0, defaultProps: !0, displayName: !0, propTypes: !0, type: !0 }, b = {}; function v(R) { - return k.isMemo(R) ? m : y[R.$$typeof] || d; + return k.isMemo(R) ? m : b[R.$$typeof] || d; } - y[k.ForwardRef] = { $$typeof: !0, render: !0, defaultProps: !0, displayName: !0, propTypes: !0 }, y[k.Memo] = m; + b[k.ForwardRef] = { $$typeof: !0, render: !0, defaultProps: !0, displayName: !0, propTypes: !0 }, b[k.Memo] = m; var N = Object.defineProperty, I = Object.getOwnPropertyNames, D = Object.getOwnPropertySymbols, L = Object.getOwnPropertyDescriptor, se = Object.getPrototypeOf, ee = Object.prototype; - i.exports = function R(U, H, ne) { + i.exports = function R(F, H, ne) { if (typeof H != "string") { if (ee) { var pe = se(H); - pe && pe !== ee && R(U, pe, ne); + pe && pe !== ee && R(F, pe, ne); } var oe = I(H); D && (oe = oe.concat(D(H))); - for (var fe = v(U), ge = v(H), S = 0; S < oe.length; ++S) { + for (var fe = v(F), ge = v(H), S = 0; S < oe.length; ++S) { var j = oe[S]; if (!(C[j] || ne && ne[j] || ge && ge[j] || fe && fe[j])) { var A = L(H, j); try { - N(U, j, A); + N(F, j, A); } catch { } } } } - return U; + return F; }; }, 4343: (i, u, f) => { var k = f(5072), d = f(7260); @@ -6429,8 +6503,8 @@ Add a component higher in the tree to provide a loading Object.defineProperty(u, "__esModule", { value: !0 }), u.resetState = function() { var C = document.getElementsByTagName("html")[0]; for (var m in f) d(C, f[m]); - var y = document.body; - for (var v in k) d(y, k[v]); + var b = document.body; + for (var v in k) d(b, k[v]); f = {}, k = {}; }, u.log = function() { }; @@ -6439,19 +6513,19 @@ Add a component higher in the tree to provide a loading C.classList.remove(m); } u.add = function(C, m) { - return y = C.classList, v = C.nodeName.toLowerCase() == "html" ? f : k, void m.split(" ").forEach(function(N) { + return b = C.classList, v = C.nodeName.toLowerCase() == "html" ? f : k, void m.split(" ").forEach(function(N) { (function(I, D) { I[D] || (I[D] = 0), I[D] += 1; - })(v, N), y.add(N); + })(v, N), b.add(N); }); - var y, v; + var b, v; }, u.remove = function(C, m) { - return y = C.classList, v = C.nodeName.toLowerCase() == "html" ? f : k, void m.split(" ").forEach(function(N) { + return b = C.classList, v = C.nodeName.toLowerCase() == "html" ? f : k, void m.split(" ").forEach(function(N) { (function(I, D) { I[D] && (I[D] -= 1); - })(v, N), v[N] === 0 && y.remove(N); + })(v, N), v[N] === 0 && b.remove(N); }); - var y, v; + var b, v; }; }, 4987: (i) => { function u(v, N, I, D) { @@ -6481,11 +6555,11 @@ Add a component higher in the tree to provide a loading }, m.prototype.set = function(v, N) { this.cache[v] = N; }; - var y = { create: function() { + var b = { create: function() { return new m(); } }; i.exports = function(v, N) { - var I = N && N.cache ? N.cache : y, D = N && N.serializer ? N.serializer : C; + var I = N && N.cache ? N.cache : b, D = N && N.serializer ? N.serializer : C; return (N && N.strategy ? N.strategy : d)(v, { cache: I, serializer: D }); }, i.exports.strategies = { variadic: function(v, N) { return k(v, this, f, N.cache.create(), N.serializer); @@ -6510,7 +6584,7 @@ Add a component higher in the tree to provide a loading return H[ne]; }; })(), m = []; - function y(H) { + function b(H) { for (var ne = -1, pe = 0; pe < m.length; pe++) if (m[pe].identifier === H) { ne = pe; break; @@ -6521,8 +6595,8 @@ Add a component higher in the tree to provide a loading for (var pe = {}, oe = [], fe = 0; fe < H.length; fe++) { var ge = H[fe], S = ne.base ? ge[0] + ne.base : ge[0], j = pe[S] || 0, A = "".concat(S, " ").concat(j); pe[S] = j + 1; - var ae = y(A), G = { css: ge[1], media: ge[2], sourceMap: ge[3] }; - ae !== -1 ? (m[ae].references++, m[ae].updater(G)) : m.push({ identifier: A, updater: U(G, ne), references: 1 }), oe.push(A); + var ae = b(A), Z = { css: ge[1], media: ge[2], sourceMap: ge[3] }; + ae !== -1 ? (m[ae].references++, m[ae].updater(Z)) : m.push({ identifier: A, updater: F(Z, ne), references: 1 }), oe.push(A); } return oe; } @@ -6564,7 +6638,7 @@ Add a component higher in the tree to provide a loading } } var ee = null, R = 0; - function U(H, ne) { + function F(H, ne) { var pe, oe, fe; if (ne.singleton) { var ge = R++; @@ -6588,11 +6662,11 @@ Add a component higher in the tree to provide a loading return function(oe) { if (oe = oe || [], Object.prototype.toString.call(oe) === "[object Array]") { for (var fe = 0; fe < pe.length; fe++) { - var ge = y(pe[fe]); + var ge = b(pe[fe]); m[ge].references--; } for (var S = v(oe, ne), j = 0; j < pe.length; j++) { - var A = y(pe[j]); + var A = b(pe[j]); m[A].references === 0 && (m[A].updater(), m.splice(A, 1)); } pe = S; @@ -6602,7 +6676,7 @@ Add a component higher in the tree to provide a loading }, 5180: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.FunctionParser = u.dedentFunction = u.functionToString = u.USED_METHOD_KEY = void 0; const k = f(1099), d = { " "() { - } }[" "].toString().charAt(0) === '"', C = { Function: "function ", GeneratorFunction: "function* ", AsyncFunction: "async function ", AsyncGeneratorFunction: "async function* " }, m = { Function: "", GeneratorFunction: "*", AsyncFunction: "async ", AsyncGeneratorFunction: "async *" }, y = new Set("case delete else in instanceof new return throw typeof void , ; : + - ! ~ & | ^ * / % < > ? =".split(" ")); + } }[" "].toString().charAt(0) === '"', C = { Function: "function ", GeneratorFunction: "function* ", AsyncFunction: "async function ", AsyncGeneratorFunction: "async function* " }, m = { Function: "", GeneratorFunction: "*", AsyncFunction: "async ", AsyncGeneratorFunction: "async *" }, b = new Set("case delete else in instanceof new return throw typeof void , ; : + - ! ~ & | ^ * / % < > ? =".split(" ")); u.USED_METHOD_KEY = /* @__PURE__ */ new WeakSet(); function v(I) { let D; @@ -6706,7 +6780,7 @@ ${D}`).join(` const ee = this.consumeSyntax(); if (ee === L) return D + L; if (!ee || ee === ")" || ee === "]" || ee === "}") return; - ee === "/" && se && this.consumeMatch(/^(?:\\.|[^\\\/\n[]|\[(?:\\.|[^\]])*\])+\/[a-z]*/) ? (se = !1, this.consumeWhitespace()) : se = y.has(ee); + ee === "/" && se && this.consumeMatch(/^(?:\\.|[^\\\/\n[]|\[(?:\\.|[^\]])*\])+\/[a-z]*/) ? (se = !1, this.consumeWhitespace()) : se = b.has(ee); } } consumeMatch(D) { @@ -6739,28 +6813,28 @@ ${D}`).join(` if (Object.getOwnPropertyNames(C).map(function(v) { return C[v]; }).join("") !== "0123456789") return !1; - var y = {}; + var b = {}; return "abcdefghijklmnopqrst".split("").forEach(function(v) { - y[v] = v; - }), Object.keys(Object.assign({}, y)).join("") === "abcdefghijklmnopqrst"; + b[v] = v; + }), Object.keys(Object.assign({}, b)).join("") === "abcdefghijklmnopqrst"; } catch { return !1; } })() ? Object.assign : function(d, C) { - for (var m, y, v = (function(L) { + for (var m, b, v = (function(L) { if (L == null) throw new TypeError("Object.assign cannot be called with null or undefined"); return Object(L); })(d), N = 1; N < arguments.length; N++) { for (var I in m = Object(arguments[N])) f.call(m, I) && (v[I] = m[I]); if (u) { - y = u(m); - for (var D = 0; D < y.length; D++) k.call(m, y[D]) && (v[y[D]] = m[y[D]]); + b = u(m); + for (var D = 0; D < b.length; D++) k.call(m, b[D]) && (v[b[D]] = m[b[D]]); } } return v; }; }, 5287: (i, u, f) => { - var k = f(5228), d = typeof Symbol == "function" && Symbol.for, C = d ? Symbol.for("react.element") : 60103, m = d ? Symbol.for("react.portal") : 60106, y = d ? Symbol.for("react.fragment") : 60107, v = d ? Symbol.for("react.strict_mode") : 60108, N = d ? Symbol.for("react.profiler") : 60114, I = d ? Symbol.for("react.provider") : 60109, D = d ? Symbol.for("react.context") : 60110, L = d ? Symbol.for("react.forward_ref") : 60112, se = d ? Symbol.for("react.suspense") : 60113, ee = d ? Symbol.for("react.memo") : 60115, R = d ? Symbol.for("react.lazy") : 60116, U = typeof Symbol == "function" && Symbol.iterator; + var k = f(5228), d = typeof Symbol == "function" && Symbol.for, C = d ? Symbol.for("react.element") : 60103, m = d ? Symbol.for("react.portal") : 60106, b = d ? Symbol.for("react.fragment") : 60107, v = d ? Symbol.for("react.strict_mode") : 60108, N = d ? Symbol.for("react.profiler") : 60114, I = d ? Symbol.for("react.provider") : 60109, D = d ? Symbol.for("react.context") : 60110, L = d ? Symbol.for("react.forward_ref") : 60112, se = d ? Symbol.for("react.suspense") : 60113, ee = d ? Symbol.for("react.memo") : 60115, R = d ? Symbol.for("react.lazy") : 60116, F = typeof Symbol == "function" && Symbol.iterator; function H(P) { for (var te = "https://reactjs.org/docs/error-decoder.html?invariant=" + P, we = 1; we < arguments.length; we++) te += "&args[]=" + encodeURIComponent(arguments[we]); return "Minified React error #" + P + "; visit " + te + " for the full message or use the non-minified dev environment for full errors and additional helpful warnings."; @@ -6788,7 +6862,7 @@ ${D}`).join(` var S = ge.prototype = new fe(); S.constructor = ge, k(S, oe.prototype), S.isPureReactComponent = !0; var j = { current: null }, A = Object.prototype.hasOwnProperty, ae = { key: !0, ref: !0, __self: !0, __source: !0 }; - function G(P, te, we) { + function Z(P, te, we) { var Se, Pe = {}, _e = null, lt = null; if (te != null) for (Se in te.ref !== void 0 && (lt = te.ref), te.key !== void 0 && (_e = "" + te.key), te) A.call(te, Se) && !ae.hasOwnProperty(Se) && (Pe[Se] = te[Se]); var Qe = arguments.length - 2; @@ -6803,16 +6877,16 @@ ${D}`).join(` function Ee(P) { return typeof P == "object" && P !== null && P.$$typeof === C; } - var J = /\/+/g, F = []; - function X(P, te, we, Se) { - if (F.length) { - var Pe = F.pop(); + var J = /\/+/g, U = []; + function G(P, te, we, Se) { + if (U.length) { + var Pe = U.pop(); return Pe.result = P, Pe.keyPrefix = te, Pe.func = we, Pe.context = Se, Pe.count = 0, Pe; } return { result: P, keyPrefix: te, func: we, context: Se, count: 0 }; } function le(P) { - P.result = null, P.keyPrefix = null, P.func = null, P.context = null, P.count = 0, 10 > F.length && F.push(P); + P.result = null, P.keyPrefix = null, P.func = null, P.context = null, P.count = 0, 10 > U.length && U.push(P); } function me(P, te, we, Se) { var Pe = typeof P; @@ -6836,7 +6910,7 @@ ${D}`).join(` var Qe = te + Ne(Pe = P[lt], lt); _e += me(Pe, Qe, we, Se); } - else if (P === null || typeof P != "object" ? Qe = null : Qe = typeof (Qe = U && P[U] || P["@@iterator"]) == "function" ? Qe : null, typeof Qe == "function") for (P = Qe.call(P), lt = 0; !(Pe = P.next()).done; ) _e += me(Pe = Pe.value, Qe = te + Ne(Pe, lt++), we, Se); + else if (P === null || typeof P != "object" ? Qe = null : Qe = typeof (Qe = F && P[F] || P["@@iterator"]) == "function" ? Qe : null, typeof Qe == "function") for (P = Qe.call(P), lt = 0; !(Pe = P.next()).done; ) _e += me(Pe = Pe.value, Qe = te + Ne(Pe, lt++), we, Se); else if (Pe === "object") throw we = "" + P, Error(H(31, we === "[object Object]" ? "object with keys {" + Object.keys(P).join(", ") + "}" : we, "")); return _e; } @@ -6851,7 +6925,7 @@ ${D}`).join(` }); })(P.key) : te.toString(36); } - function Fe(P, te) { + function Ue(P, te) { P.func.call(P.context, te, P.count++); } function Ae(P, te, we) { @@ -6864,7 +6938,7 @@ ${D}`).join(` } function Le(P, te, we, Se, Pe) { var _e = ""; - we != null && (_e = ("" + we).replace(J, "$&/") + "/"), ke(P, Ae, te = X(te, _e, Se, Pe)), le(te); + we != null && (_e = ("" + we).replace(J, "$&/") + "/"), ke(P, Ae, te = G(te, _e, Se, Pe)), le(te); } var Ke = { current: null }; function Je() { @@ -6872,14 +6946,14 @@ ${D}`).join(` if (P === null) throw Error(H(321)); return P; } - var be = { ReactCurrentDispatcher: Ke, ReactCurrentBatchConfig: { suspense: null }, ReactCurrentOwner: j, IsSomeRendererActing: { current: !1 }, assign: k }; + var ye = { ReactCurrentDispatcher: Ke, ReactCurrentBatchConfig: { suspense: null }, ReactCurrentOwner: j, IsSomeRendererActing: { current: !1 }, assign: k }; u.Children = { map: function(P, te, we) { if (P == null) return P; var Se = []; return Le(P, Se, null, te, we), Se; }, forEach: function(P, te, we) { if (P == null) return P; - ke(P, Fe, te = X(null, null, te, we)), le(te); + ke(P, Ue, te = G(null, null, te, we)), le(te); }, count: function(P) { return ke(P, function() { return null; @@ -6892,7 +6966,7 @@ ${D}`).join(` }, only: function(P) { if (!Ee(P)) throw Error(H(143)); return P; - } }, u.Component = oe, u.Fragment = y, u.Profiler = N, u.PureComponent = ge, u.StrictMode = v, u.Suspense = se, u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = be, u.cloneElement = function(P, te, we) { + } }, u.Component = oe, u.Fragment = b, u.Profiler = N, u.PureComponent = ge, u.StrictMode = v, u.Suspense = se, u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = ye, u.cloneElement = function(P, te, we) { if (P == null) throw Error(H(267, P)); var Se = k({}, P.props), Pe = P.key, _e = P.ref, lt = P._owner; if (te != null) { @@ -6909,8 +6983,8 @@ ${D}`).join(` return { $$typeof: C, type: P.type, key: Pe, ref: _e, props: Se, _owner: lt }; }, u.createContext = function(P, te) { return te === void 0 && (te = null), (P = { $$typeof: D, _calculateChangedBits: te, _currentValue: P, _currentValue2: P, _threadCount: 0, Provider: null, Consumer: null }).Provider = { $$typeof: I, _context: P }, P.Consumer = P; - }, u.createElement = G, u.createFactory = function(P) { - var te = G.bind(null, P); + }, u.createElement = Z, u.createFactory = function(P) { + var te = Z.bind(null, P); return te.type = P, te; }, u.createRef = function() { return { current: null }; @@ -6943,13 +7017,13 @@ ${D}`).join(` }, 5323: (i, u, f) => { u.A = void 0; const k = f(42), d = f(1099), C = Symbol("root"); - u.A = function(m, y, v, N = {}) { + u.A = function(m, b, v, N = {}) { const I = typeof v == "string" ? v : " ".repeat(v || 0), D = [], L = /* @__PURE__ */ new Set(), se = /* @__PURE__ */ new Map(), ee = /* @__PURE__ */ new Map(); let R = 0; - const { maxDepth: U = 100, references: H = !1, skipUndefinedProperties: ne = !1, maxValues: pe = 1e5 } = N, oe = (function(j) { - return j ? (A, ae, G, Ee) => j(A, ae, (J) => k.toString(J, ae, G, Ee), Ee) : k.toString; - })(y), fe = (j, A) => { - if (++R > pe || ne && j === void 0 || D.length > U) return; + const { maxDepth: F = 100, references: H = !1, skipUndefinedProperties: ne = !1, maxValues: pe = 1e5 } = N, oe = (function(j) { + return j ? (A, ae, Z, Ee) => j(A, ae, (J) => k.toString(J, ae, Z, Ee), Ee) : k.toString; + })(b), fe = (j, A) => { + if (++R > pe || ne && j === void 0 || D.length > F) return; if (A === void 0) return oe(j, I, fe, A); D.push(A); const ae = ge(j, A === C ? void 0 : A); @@ -6970,8 +7044,8 @@ ${D}`).join(` const j = I ? " " : "", A = I ? ` ` : ""; let ae = `var x${j}=${j}${S};${A}`; - for (const [G, Ee] of ee.entries()) - ae += `x${d.stringifyPath(G, fe)}${j}=${j}x${d.stringifyPath(Ee, fe)};${A}`; + for (const [Z, Ee] of ee.entries()) + ae += `x${d.stringifyPath(Z, fe)}${j}=${j}x${d.stringifyPath(Ee, fe)};${A}`; return `(function${j}()${j}{${A}${ae}return x;${A}}())`; } return S; @@ -7000,15 +7074,15 @@ ${D}`).join(` var k = (function(J) { if (J && J.__esModule) return J; if (J === null || ee(J) !== "object" && typeof J != "function") return { default: J }; - var F = se(); - if (F && F.has(J)) return F.get(J); - var X = {}, le = Object.defineProperty && Object.getOwnPropertyDescriptor; + var U = se(); + if (U && U.has(J)) return U.get(J); + var G = {}, le = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var me in J) if (Object.prototype.hasOwnProperty.call(J, me)) { var ke = le ? Object.getOwnPropertyDescriptor(J, me) : null; - ke && (ke.get || ke.set) ? Object.defineProperty(X, me, ke) : X[me] = J[me]; + ke && (ke.get || ke.set) ? Object.defineProperty(G, me, ke) : G[me] = J[me]; } - return X.default = J, F && F.set(J, X), X; - })(f(6540)), d = L(f(5556)), C = L(f(961)), m = L(f(6942)), y = f(1089), v = f(1726), N = f(7056), I = L(f(6888)), D = L(f(8696)); + return G.default = J, U && U.set(J, G), G; + })(f(6540)), d = L(f(5556)), C = L(f(961)), m = L(f(6942)), b = f(1089), v = f(1726), N = f(7056), I = L(f(6888)), D = L(f(8696)); function L(J) { return J && J.__esModule ? J : { default: J }; } @@ -7020,108 +7094,108 @@ ${D}`).join(` }, J; } function ee(J) { - return ee = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(F) { - return typeof F; - } : function(F) { - return F && typeof Symbol == "function" && F.constructor === Symbol && F !== Symbol.prototype ? "symbol" : typeof F; + return ee = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(U) { + return typeof U; + } : function(U) { + return U && typeof Symbol == "function" && U.constructor === Symbol && U !== Symbol.prototype ? "symbol" : typeof U; }, ee(J); } function R() { return R = Object.assign || function(J) { - for (var F = 1; F < arguments.length; F++) { - var X = arguments[F]; - for (var le in X) Object.prototype.hasOwnProperty.call(X, le) && (J[le] = X[le]); + for (var U = 1; U < arguments.length; U++) { + var G = arguments[U]; + for (var le in G) Object.prototype.hasOwnProperty.call(G, le) && (J[le] = G[le]); } return J; }, R.apply(this, arguments); } - function U(J, F) { + function F(J, U) { if (J == null) return {}; - var X, le, me = (function(Ne, Fe) { + var G, le, me = (function(Ne, Ue) { if (Ne == null) return {}; var Ae, Le, Ke = {}, Je = Object.keys(Ne); - for (Le = 0; Le < Je.length; Le++) Ae = Je[Le], Fe.indexOf(Ae) >= 0 || (Ke[Ae] = Ne[Ae]); + for (Le = 0; Le < Je.length; Le++) Ae = Je[Le], Ue.indexOf(Ae) >= 0 || (Ke[Ae] = Ne[Ae]); return Ke; - })(J, F); + })(J, U); if (Object.getOwnPropertySymbols) { var ke = Object.getOwnPropertySymbols(J); - for (le = 0; le < ke.length; le++) X = ke[le], F.indexOf(X) >= 0 || Object.prototype.propertyIsEnumerable.call(J, X) && (me[X] = J[X]); + for (le = 0; le < ke.length; le++) G = ke[le], U.indexOf(G) >= 0 || Object.prototype.propertyIsEnumerable.call(J, G) && (me[G] = J[G]); } return me; } - function H(J, F) { - return (function(X) { - if (Array.isArray(X)) return X; - })(J) || (function(X, le) { - if (!(typeof Symbol > "u" || !(Symbol.iterator in Object(X)))) { - var me = [], ke = !0, Ne = !1, Fe = void 0; + function H(J, U) { + return (function(G) { + if (Array.isArray(G)) return G; + })(J) || (function(G, le) { + if (!(typeof Symbol > "u" || !(Symbol.iterator in Object(G)))) { + var me = [], ke = !0, Ne = !1, Ue = void 0; try { - for (var Ae, Le = X[Symbol.iterator](); !(ke = (Ae = Le.next()).done) && (me.push(Ae.value), !le || me.length !== le); ke = !0) ; + for (var Ae, Le = G[Symbol.iterator](); !(ke = (Ae = Le.next()).done) && (me.push(Ae.value), !le || me.length !== le); ke = !0) ; } catch (Ke) { - Ne = !0, Fe = Ke; + Ne = !0, Ue = Ke; } finally { try { ke || Le.return == null || Le.return(); } finally { - if (Ne) throw Fe; + if (Ne) throw Ue; } } return me; } - })(J, F) || (function(X, le) { - if (X) { - if (typeof X == "string") return ne(X, le); - var me = Object.prototype.toString.call(X).slice(8, -1); - if (me === "Object" && X.constructor && (me = X.constructor.name), me === "Map" || me === "Set") return Array.from(X); - if (me === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(me)) return ne(X, le); + })(J, U) || (function(G, le) { + if (G) { + if (typeof G == "string") return ne(G, le); + var me = Object.prototype.toString.call(G).slice(8, -1); + if (me === "Object" && G.constructor && (me = G.constructor.name), me === "Map" || me === "Set") return Array.from(G); + if (me === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(me)) return ne(G, le); } - })(J, F) || (function() { + })(J, U) || (function() { throw new TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`); })(); } - function ne(J, F) { - (F == null || F > J.length) && (F = J.length); - for (var X = 0, le = new Array(F); X < F; X++) le[X] = J[X]; + function ne(J, U) { + (U == null || U > J.length) && (U = J.length); + for (var G = 0, le = new Array(U); G < U; G++) le[G] = J[G]; return le; } - function pe(J, F) { - var X = Object.keys(J); + function pe(J, U) { + var G = Object.keys(J); if (Object.getOwnPropertySymbols) { var le = Object.getOwnPropertySymbols(J); - F && (le = le.filter(function(me) { + U && (le = le.filter(function(me) { return Object.getOwnPropertyDescriptor(J, me).enumerable; - })), X.push.apply(X, le); + })), G.push.apply(G, le); } - return X; + return G; } function oe(J) { - for (var F = 1; F < arguments.length; F++) { - var X = arguments[F] != null ? arguments[F] : {}; - F % 2 ? pe(Object(X), !0).forEach(function(le) { - G(J, le, X[le]); - }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(J, Object.getOwnPropertyDescriptors(X)) : pe(Object(X)).forEach(function(le) { - Object.defineProperty(J, le, Object.getOwnPropertyDescriptor(X, le)); + for (var U = 1; U < arguments.length; U++) { + var G = arguments[U] != null ? arguments[U] : {}; + U % 2 ? pe(Object(G), !0).forEach(function(le) { + Z(J, le, G[le]); + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(J, Object.getOwnPropertyDescriptors(G)) : pe(Object(G)).forEach(function(le) { + Object.defineProperty(J, le, Object.getOwnPropertyDescriptor(G, le)); }); } return J; } - function fe(J, F) { - for (var X = 0; X < F.length; X++) { - var le = F[X]; + function fe(J, U) { + for (var G = 0; G < U.length; G++) { + var le = U[G]; le.enumerable = le.enumerable || !1, le.configurable = !0, "value" in le && (le.writable = !0), Object.defineProperty(J, le.key, le); } } - function ge(J, F, X) { - return F && fe(J.prototype, F), X && fe(J, X), J; + function ge(J, U, G) { + return U && fe(J.prototype, U), G && fe(J, G), J; } - function S(J, F) { - return S = Object.setPrototypeOf || function(X, le) { - return X.__proto__ = le, X; - }, S(J, F); + function S(J, U) { + return S = Object.setPrototypeOf || function(G, le) { + return G.__proto__ = le, G; + }, S(J, U); } function j(J) { - var F = (function() { + var U = (function() { if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1; if (typeof Proxy == "function") return !0; try { @@ -7132,14 +7206,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } })(); return function() { - var X, le = ae(J); - if (F) { + var G, le = ae(J); + if (U) { var me = ae(this).constructor; - X = Reflect.construct(le, arguments, me); - } else X = le.apply(this, arguments); + G = Reflect.construct(le, arguments, me); + } else G = le.apply(this, arguments); return (function(ke, Ne) { return Ne && (ee(Ne) === "object" || typeof Ne == "function") ? Ne : A(ke); - })(this, X); + })(this, G); }; } function A(J) { @@ -7147,66 +7221,66 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho return J; } function ae(J) { - return ae = Object.setPrototypeOf ? Object.getPrototypeOf : function(F) { - return F.__proto__ || Object.getPrototypeOf(F); + return ae = Object.setPrototypeOf ? Object.getPrototypeOf : function(U) { + return U.__proto__ || Object.getPrototypeOf(U); }, ae(J); } - function G(J, F, X) { - return F in J ? Object.defineProperty(J, F, { value: X, enumerable: !0, configurable: !0, writable: !0 }) : J[F] = X, J; + function Z(J, U, G) { + return U in J ? Object.defineProperty(J, U, { value: G, enumerable: !0, configurable: !0, writable: !0 }) : J[U] = G, J; } var Ee = (function(J) { (function(le, me) { if (typeof me != "function" && me !== null) throw new TypeError("Super expression must either be null or a function"); le.prototype = Object.create(me && me.prototype, { constructor: { value: le, writable: !0, configurable: !0 } }), me && S(le, me); - })(X, J); - var F = j(X); - function X(le) { + })(G, J); + var U = j(G); + function G(le) { var me; return (function(ke, Ne) { if (!(ke instanceof Ne)) throw new TypeError("Cannot call a class as a function"); - })(this, X), G(A(me = F.call(this, le)), "onDragStart", function(ke, Ne) { + })(this, G), Z(A(me = U.call(this, le)), "onDragStart", function(ke, Ne) { if ((0, D.default)("Draggable: onDragStart: %j", Ne), me.props.onStart(ke, (0, v.createDraggableData)(A(me), Ne)) === !1) return !1; me.setState({ dragging: !0, dragged: !0 }); - }), G(A(me), "onDrag", function(ke, Ne) { + }), Z(A(me), "onDrag", function(ke, Ne) { if (!me.state.dragging) return !1; (0, D.default)("Draggable: onDrag: %j", Ne); - var Fe = (0, v.createDraggableData)(A(me), Ne), Ae = { x: Fe.x, y: Fe.y }; + var Ue = (0, v.createDraggableData)(A(me), Ne), Ae = { x: Ue.x, y: Ue.y }; if (me.props.bounds) { var Le = Ae.x, Ke = Ae.y; Ae.x += me.state.slackX, Ae.y += me.state.slackY; - var Je = H((0, v.getBoundPosition)(A(me), Ae.x, Ae.y), 2), be = Je[0], P = Je[1]; - Ae.x = be, Ae.y = P, Ae.slackX = me.state.slackX + (Le - Ae.x), Ae.slackY = me.state.slackY + (Ke - Ae.y), Fe.x = Ae.x, Fe.y = Ae.y, Fe.deltaX = Ae.x - me.state.x, Fe.deltaY = Ae.y - me.state.y; + var Je = H((0, v.getBoundPosition)(A(me), Ae.x, Ae.y), 2), ye = Je[0], P = Je[1]; + Ae.x = ye, Ae.y = P, Ae.slackX = me.state.slackX + (Le - Ae.x), Ae.slackY = me.state.slackY + (Ke - Ae.y), Ue.x = Ae.x, Ue.y = Ae.y, Ue.deltaX = Ae.x - me.state.x, Ue.deltaY = Ae.y - me.state.y; } - if (me.props.onDrag(ke, Fe) === !1) return !1; + if (me.props.onDrag(ke, Ue) === !1) return !1; me.setState(Ae); - }), G(A(me), "onDragStop", function(ke, Ne) { + }), Z(A(me), "onDragStop", function(ke, Ne) { if (!me.state.dragging || me.props.onStop(ke, (0, v.createDraggableData)(A(me), Ne)) === !1) return !1; (0, D.default)("Draggable: onDragStop: %j", Ne); - var Fe = { dragging: !1, slackX: 0, slackY: 0 }; + var Ue = { dragging: !1, slackX: 0, slackY: 0 }; if (me.props.position) { var Ae = me.props.position, Le = Ae.x, Ke = Ae.y; - Fe.x = Le, Fe.y = Ke; + Ue.x = Le, Ue.y = Ke; } - me.setState(Fe); + me.setState(Ue); }), me.state = { dragging: !1, dragged: !1, x: le.position ? le.position.x : le.defaultPosition.x, y: le.position ? le.position.y : le.defaultPosition.y, prevPropsPosition: oe({}, le.position), slackX: 0, slackY: 0, isElementSVG: !1 }, !le.position || le.onDrag || le.onStop || console.warn("A `position` was applied to this , without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element."), me; } - return ge(X, null, [{ key: "getDerivedStateFromProps", value: function(le, me) { + return ge(G, null, [{ key: "getDerivedStateFromProps", value: function(le, me) { var ke = le.position, Ne = me.prevPropsPosition; return !ke || Ne && ke.x === Ne.x && ke.y === Ne.y ? null : ((0, D.default)("Draggable: getDerivedStateFromProps %j", { position: ke, prevPropsPosition: Ne }), { x: ke.x, y: ke.y, prevPropsPosition: oe({}, ke) }); - } }]), ge(X, [{ key: "componentDidMount", value: function() { + } }]), ge(G, [{ key: "componentDidMount", value: function() { window.SVGElement !== void 0 && this.findDOMNode() instanceof window.SVGElement && this.setState({ isElementSVG: !0 }); } }, { key: "componentWillUnmount", value: function() { this.setState({ dragging: !1 }); } }, { key: "findDOMNode", value: function() { return this.props.nodeRef ? this.props.nodeRef.current : C.default.findDOMNode(this); } }, { key: "render", value: function() { - var le, me = this.props, ke = (me.axis, me.bounds, me.children), Ne = me.defaultPosition, Fe = me.defaultClassName, Ae = me.defaultClassNameDragging, Le = me.defaultClassNameDragged, Ke = me.position, Je = me.positionOffset, be = (me.scale, U(me, ["axis", "bounds", "children", "defaultPosition", "defaultClassName", "defaultClassNameDragging", "defaultClassNameDragged", "position", "positionOffset", "scale"])), P = {}, te = null, we = !Ke || this.state.dragging, Se = Ke || Ne, Pe = { x: (0, v.canDragX)(this) && we ? this.state.x : Se.x, y: (0, v.canDragY)(this) && we ? this.state.y : Se.y }; - this.state.isElementSVG ? te = (0, y.createSVGTransform)(Pe, Je) : P = (0, y.createCSSTransform)(Pe, Je); - var _e = (0, m.default)(ke.props.className || "", Fe, (G(le = {}, Ae, this.state.dragging), G(le, Le, this.state.dragged), le)); - return k.createElement(I.default, R({}, be, { onStart: this.onDragStart, onDrag: this.onDrag, onStop: this.onDragStop }), k.cloneElement(k.Children.only(ke), { className: _e, style: oe(oe({}, ke.props.style), P), transform: te })); - } }]), X; + var le, me = this.props, ke = (me.axis, me.bounds, me.children), Ne = me.defaultPosition, Ue = me.defaultClassName, Ae = me.defaultClassNameDragging, Le = me.defaultClassNameDragged, Ke = me.position, Je = me.positionOffset, ye = (me.scale, F(me, ["axis", "bounds", "children", "defaultPosition", "defaultClassName", "defaultClassNameDragging", "defaultClassNameDragged", "position", "positionOffset", "scale"])), P = {}, te = null, we = !Ke || this.state.dragging, Se = Ke || Ne, Pe = { x: (0, v.canDragX)(this) && we ? this.state.x : Se.x, y: (0, v.canDragY)(this) && we ? this.state.y : Se.y }; + this.state.isElementSVG ? te = (0, b.createSVGTransform)(Pe, Je) : P = (0, b.createCSSTransform)(Pe, Je); + var _e = (0, m.default)(ke.props.className || "", Ue, (Z(le = {}, Ae, this.state.dragging), Z(le, Le, this.state.dragged), le)); + return k.createElement(I.default, R({}, ye, { onStart: this.onDragStart, onDrag: this.onDrag, onStop: this.onDragStop }), k.cloneElement(k.Children.only(ke), { className: _e, style: oe(oe({}, ke.props.style), P), transform: te })); + } }]), G; })(k.Component); - u.default = Ee, G(Ee, "displayName", "Draggable"), G(Ee, "propTypes", oe(oe({}, I.default.propTypes), {}, { axis: d.default.oneOf(["both", "x", "y", "none"]), bounds: d.default.oneOfType([d.default.shape({ left: d.default.number, right: d.default.number, top: d.default.number, bottom: d.default.number }), d.default.string, d.default.oneOf([!1])]), defaultClassName: d.default.string, defaultClassNameDragging: d.default.string, defaultClassNameDragged: d.default.string, defaultPosition: d.default.shape({ x: d.default.number, y: d.default.number }), positionOffset: d.default.shape({ x: d.default.oneOfType([d.default.number, d.default.string]), y: d.default.oneOfType([d.default.number, d.default.string]) }), position: d.default.shape({ x: d.default.number, y: d.default.number }), className: N.dontSetMe, style: N.dontSetMe, transform: N.dontSetMe })), G(Ee, "defaultProps", oe(oe({}, I.default.defaultProps), {}, { axis: "both", bounds: !1, defaultClassName: "react-draggable", defaultClassNameDragging: "react-draggable-dragging", defaultClassNameDragged: "react-draggable-dragged", defaultPosition: { x: 0, y: 0 }, position: null, scale: 1 })); + u.default = Ee, Z(Ee, "displayName", "Draggable"), Z(Ee, "propTypes", oe(oe({}, I.default.propTypes), {}, { axis: d.default.oneOf(["both", "x", "y", "none"]), bounds: d.default.oneOfType([d.default.shape({ left: d.default.number, right: d.default.number, top: d.default.number, bottom: d.default.number }), d.default.string, d.default.oneOf([!1])]), defaultClassName: d.default.string, defaultClassNameDragging: d.default.string, defaultClassNameDragged: d.default.string, defaultPosition: d.default.shape({ x: d.default.number, y: d.default.number }), positionOffset: d.default.shape({ x: d.default.oneOfType([d.default.number, d.default.string]), y: d.default.oneOfType([d.default.number, d.default.string]) }), position: d.default.shape({ x: d.default.number, y: d.default.number }), className: N.dontSetMe, style: N.dontSetMe, transform: N.dontSetMe })), Z(Ee, "defaultProps", oe(oe({}, I.default.defaultProps), {}, { axis: "both", bounds: !1, defaultClassName: "react-draggable", defaultClassNameDragging: "react-draggable-dragging", defaultClassNameDragged: "react-draggable-dragged", defaultPosition: { x: 0, y: 0 }, position: null, scale: 1 })); }, 6314: (i) => { i.exports = function(u) { var f = []; @@ -7218,8 +7292,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }, f.i = function(k, d, C) { typeof k == "string" && (k = [[null, k, ""]]); var m = {}; - if (C) for (var y = 0; y < this.length; y++) { - var v = this[y][0]; + if (C) for (var b = 0; b < this.length; b++) { + var v = this[b][0]; v != null && (m[v] = !0); } for (var N = 0; N < k.length; N++) { @@ -7257,11 +7331,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }; }, 6462: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.resetState = function() { - y && (y.removeAttribute ? y.removeAttribute("aria-hidden") : y.length != null ? y.forEach(function(I) { + b && (b.removeAttribute ? b.removeAttribute("aria-hidden") : b.length != null ? b.forEach(function(I) { return I.removeAttribute("aria-hidden"); - }) : document.querySelectorAll(y).forEach(function(I) { + }) : document.querySelectorAll(b).forEach(function(I) { return I.removeAttribute("aria-hidden"); - })), y = null; + })), b = null; }, u.log = function() { }, u.assertNodeList = v, u.setElement = function(I) { var D = I; @@ -7269,14 +7343,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho var L = document.querySelectorAll(D); v(L, D), D = L; } - return y = D || y; + return b = D || b; }, u.validateElement = N, u.hide = function(I) { var D = !0, L = !1, se = void 0; try { for (var ee, R = N(I)[Symbol.iterator](); !(D = (ee = R.next()).done); D = !0) ee.value.setAttribute("aria-hidden", "true"); - } catch (U) { - L = !0, se = U; + } catch (F) { + L = !0, se = F; } finally { try { !D && R.return && R.return(); @@ -7289,8 +7363,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho try { for (var ee, R = N(I)[Symbol.iterator](); !(D = (ee = R.next()).done); D = !0) ee.value.removeAttribute("aria-hidden"); - } catch (U) { - L = !0, se = U; + } catch (F) { + L = !0, se = F; } finally { try { !D && R.return && R.return(); @@ -7299,14 +7373,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } } }, u.documentNotReadyOrSSRTesting = function() { - y = null; + b = null; }; - var k, d = f(9771), C = (k = d) && k.__esModule ? k : { default: k }, m = f(834), y = null; + var k, d = f(9771), C = (k = d) && k.__esModule ? k : { default: k }, m = f(834), b = null; function v(I, D) { if (!I || !I.length) throw new Error("react-modal: No elements were found for selector " + D + "."); } function N(I) { - var D = I || y; + var D = I || b; return D ? Array.isArray(D) || D instanceof HTMLCollection || D instanceof NodeList ? D : [D] : ((0, C.default)(!1, ["react-modal: App element is not defined.", "Please use `Modal.setAppElement(el)` or set `appElement={el}`.", "This is needed so screen readers don't see main content", "when modal is opened. It is not recommended, but you can opt-out", "by setting `ariaHideApp={false}`."].join(" ")), []); } }, 6540: (i, u, f) => { @@ -7323,13 +7397,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho if (A === null || L(A) !== "object" && typeof A != "function") return { default: A }; var ae = D(); if (ae && ae.has(A)) return ae.get(A); - var G = {}, Ee = Object.defineProperty && Object.getOwnPropertyDescriptor; + var Z = {}, Ee = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var J in A) if (Object.prototype.hasOwnProperty.call(A, J)) { - var F = Ee ? Object.getOwnPropertyDescriptor(A, J) : null; - F && (F.get || F.set) ? Object.defineProperty(G, J, F) : G[J] = A[J]; + var U = Ee ? Object.getOwnPropertyDescriptor(A, J) : null; + U && (U.get || U.set) ? Object.defineProperty(Z, J, U) : Z[J] = A[J]; } - return G.default = A, ae && ae.set(A, G), G; - })(f(6540)), d = I(f(5556)), C = I(f(961)), m = f(1089), y = f(1726), v = f(7056), N = I(f(8696)); + return Z.default = A, ae && ae.set(A, Z), Z; + })(f(6540)), d = I(f(5556)), C = I(f(961)), m = f(1089), b = f(1726), v = f(7056), N = I(f(8696)); function I(A) { return A && A.__esModule ? A : { default: A }; } @@ -7348,30 +7422,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }, L(A); } function se(A, ae) { - return (function(G) { - if (Array.isArray(G)) return G; - })(A) || (function(G, Ee) { - if (!(typeof Symbol > "u" || !(Symbol.iterator in Object(G)))) { - var J = [], F = !0, X = !1, le = void 0; + return (function(Z) { + if (Array.isArray(Z)) return Z; + })(A) || (function(Z, Ee) { + if (!(typeof Symbol > "u" || !(Symbol.iterator in Object(Z)))) { + var J = [], U = !0, G = !1, le = void 0; try { - for (var me, ke = G[Symbol.iterator](); !(F = (me = ke.next()).done) && (J.push(me.value), !Ee || J.length !== Ee); F = !0) ; + for (var me, ke = Z[Symbol.iterator](); !(U = (me = ke.next()).done) && (J.push(me.value), !Ee || J.length !== Ee); U = !0) ; } catch (Ne) { - X = !0, le = Ne; + G = !0, le = Ne; } finally { try { - F || ke.return == null || ke.return(); + U || ke.return == null || ke.return(); } finally { - if (X) throw le; + if (G) throw le; } } return J; } - })(A, ae) || (function(G, Ee) { - if (G) { - if (typeof G == "string") return ee(G, Ee); - var J = Object.prototype.toString.call(G).slice(8, -1); - if (J === "Object" && G.constructor && (J = G.constructor.name), J === "Map" || J === "Set") return Array.from(G); - if (J === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(J)) return ee(G, Ee); + })(A, ae) || (function(Z, Ee) { + if (Z) { + if (typeof Z == "string") return ee(Z, Ee); + var J = Object.prototype.toString.call(Z).slice(8, -1); + if (J === "Object" && Z.constructor && (J = Z.constructor.name), J === "Map" || J === "Set") return Array.from(Z); + if (J === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(J)) return ee(Z, Ee); } })(A, ae) || (function() { throw new TypeError(`Invalid attempt to destructure non-iterable instance. @@ -7380,19 +7454,19 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } function ee(A, ae) { (ae == null || ae > A.length) && (ae = A.length); - for (var G = 0, Ee = new Array(ae); G < ae; G++) Ee[G] = A[G]; + for (var Z = 0, Ee = new Array(ae); Z < ae; Z++) Ee[Z] = A[Z]; return Ee; } function R(A, ae) { - for (var G = 0; G < ae.length; G++) { - var Ee = ae[G]; + for (var Z = 0; Z < ae.length; Z++) { + var Ee = ae[Z]; Ee.enumerable = Ee.enumerable || !1, Ee.configurable = !0, "value" in Ee && (Ee.writable = !0), Object.defineProperty(A, Ee.key, Ee); } } - function U(A, ae) { - return U = Object.setPrototypeOf || function(G, Ee) { - return G.__proto__ = Ee, G; - }, U(A, ae); + function F(A, ae) { + return F = Object.setPrototypeOf || function(Z, Ee) { + return Z.__proto__ = Ee, Z; + }, F(A, ae); } function H(A) { var ae = (function() { @@ -7406,14 +7480,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } })(); return function() { - var G, Ee = pe(A); + var Z, Ee = pe(A); if (ae) { var J = pe(this).constructor; - G = Reflect.construct(Ee, arguments, J); - } else G = Ee.apply(this, arguments); - return (function(F, X) { - return X && (L(X) === "object" || typeof X == "function") ? X : ne(F); - })(this, G); + Z = Reflect.construct(Ee, arguments, J); + } else Z = Ee.apply(this, arguments); + return (function(U, G) { + return G && (L(G) === "object" || typeof G == "function") ? G : ne(U); + })(this, Z); }; } function ne(A) { @@ -7425,90 +7499,90 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho return ae.__proto__ || Object.getPrototypeOf(ae); }, pe(A); } - function oe(A, ae, G) { - return ae in A ? Object.defineProperty(A, ae, { value: G, enumerable: !0, configurable: !0, writable: !0 }) : A[ae] = G, A; + function oe(A, ae, Z) { + return ae in A ? Object.defineProperty(A, ae, { value: Z, enumerable: !0, configurable: !0, writable: !0 }) : A[ae] = Z, A; } var fe = { start: "touchstart", move: "touchmove", stop: "touchend" }, ge = { start: "mousedown", move: "mousemove", stop: "mouseup" }, S = ge, j = (function(A) { - (function(F, X) { - if (typeof X != "function" && X !== null) throw new TypeError("Super expression must either be null or a function"); - F.prototype = Object.create(X && X.prototype, { constructor: { value: F, writable: !0, configurable: !0 } }), X && U(F, X); + (function(U, G) { + if (typeof G != "function" && G !== null) throw new TypeError("Super expression must either be null or a function"); + U.prototype = Object.create(G && G.prototype, { constructor: { value: U, writable: !0, configurable: !0 } }), G && F(U, G); })(J, A); - var ae, G, Ee = H(J); + var ae, Z, Ee = H(J); function J() { - var F; + var U; (function(ke, Ne) { if (!(ke instanceof Ne)) throw new TypeError("Cannot call a class as a function"); })(this, J); - for (var X = arguments.length, le = new Array(X), me = 0; me < X; me++) le[me] = arguments[me]; - return oe(ne(F = Ee.call.apply(Ee, [this].concat(le))), "state", { dragging: !1, lastX: NaN, lastY: NaN, touchIdentifier: null }), oe(ne(F), "mounted", !1), oe(ne(F), "handleDragStart", function(ke) { - if (F.props.onMouseDown(ke), !F.props.allowAnyClick && typeof ke.button == "number" && ke.button !== 0) return !1; - var Ne = F.findDOMNode(); + for (var G = arguments.length, le = new Array(G), me = 0; me < G; me++) le[me] = arguments[me]; + return oe(ne(U = Ee.call.apply(Ee, [this].concat(le))), "state", { dragging: !1, lastX: NaN, lastY: NaN, touchIdentifier: null }), oe(ne(U), "mounted", !1), oe(ne(U), "handleDragStart", function(ke) { + if (U.props.onMouseDown(ke), !U.props.allowAnyClick && typeof ke.button == "number" && ke.button !== 0) return !1; + var Ne = U.findDOMNode(); if (!Ne || !Ne.ownerDocument || !Ne.ownerDocument.body) throw new Error(" not mounted on DragStart!"); - var Fe = Ne.ownerDocument; - if (!(F.props.disabled || !(ke.target instanceof Fe.defaultView.Node) || F.props.handle && !(0, m.matchesSelectorAndParentsTo)(ke.target, F.props.handle, Ne) || F.props.cancel && (0, m.matchesSelectorAndParentsTo)(ke.target, F.props.cancel, Ne))) { + var Ue = Ne.ownerDocument; + if (!(U.props.disabled || !(ke.target instanceof Ue.defaultView.Node) || U.props.handle && !(0, m.matchesSelectorAndParentsTo)(ke.target, U.props.handle, Ne) || U.props.cancel && (0, m.matchesSelectorAndParentsTo)(ke.target, U.props.cancel, Ne))) { ke.type === "touchstart" && ke.preventDefault(); var Ae = (0, m.getTouchIdentifier)(ke); - F.setState({ touchIdentifier: Ae }); - var Le = (0, y.getControlPosition)(ke, Ae, ne(F)); + U.setState({ touchIdentifier: Ae }); + var Le = (0, b.getControlPosition)(ke, Ae, ne(U)); if (Le != null) { - var Ke = Le.x, Je = Le.y, be = (0, y.createCoreData)(ne(F), Ke, Je); - (0, N.default)("DraggableCore: handleDragStart: %j", be), (0, N.default)("calling", F.props.onStart), F.props.onStart(ke, be) !== !1 && F.mounted !== !1 && (F.props.enableUserSelectHack && (0, m.addUserSelectStyles)(Fe), F.setState({ dragging: !0, lastX: Ke, lastY: Je }), (0, m.addEvent)(Fe, S.move, F.handleDrag), (0, m.addEvent)(Fe, S.stop, F.handleDragStop)); + var Ke = Le.x, Je = Le.y, ye = (0, b.createCoreData)(ne(U), Ke, Je); + (0, N.default)("DraggableCore: handleDragStart: %j", ye), (0, N.default)("calling", U.props.onStart), U.props.onStart(ke, ye) !== !1 && U.mounted !== !1 && (U.props.enableUserSelectHack && (0, m.addUserSelectStyles)(Ue), U.setState({ dragging: !0, lastX: Ke, lastY: Je }), (0, m.addEvent)(Ue, S.move, U.handleDrag), (0, m.addEvent)(Ue, S.stop, U.handleDragStop)); } } - }), oe(ne(F), "handleDrag", function(ke) { - var Ne = (0, y.getControlPosition)(ke, F.state.touchIdentifier, ne(F)); + }), oe(ne(U), "handleDrag", function(ke) { + var Ne = (0, b.getControlPosition)(ke, U.state.touchIdentifier, ne(U)); if (Ne != null) { - var Fe = Ne.x, Ae = Ne.y; - if (Array.isArray(F.props.grid)) { - var Le = Fe - F.state.lastX, Ke = Ae - F.state.lastY, Je = se((0, y.snapToGrid)(F.props.grid, Le, Ke), 2); + var Ue = Ne.x, Ae = Ne.y; + if (Array.isArray(U.props.grid)) { + var Le = Ue - U.state.lastX, Ke = Ae - U.state.lastY, Je = se((0, b.snapToGrid)(U.props.grid, Le, Ke), 2); if (Le = Je[0], Ke = Je[1], !Le && !Ke) return; - Fe = F.state.lastX + Le, Ae = F.state.lastY + Ke; + Ue = U.state.lastX + Le, Ae = U.state.lastY + Ke; } - var be = (0, y.createCoreData)(ne(F), Fe, Ae); - if ((0, N.default)("DraggableCore: handleDrag: %j", be), F.props.onDrag(ke, be) !== !1 && F.mounted !== !1) F.setState({ lastX: Fe, lastY: Ae }); + var ye = (0, b.createCoreData)(ne(U), Ue, Ae); + if ((0, N.default)("DraggableCore: handleDrag: %j", ye), U.props.onDrag(ke, ye) !== !1 && U.mounted !== !1) U.setState({ lastX: Ue, lastY: Ae }); else try { - F.handleDragStop(new MouseEvent("mouseup")); + U.handleDragStop(new MouseEvent("mouseup")); } catch { var P = document.createEvent("MouseEvents"); - P.initMouseEvent("mouseup", !0, !0, window, 0, 0, 0, 0, 0, !1, !1, !1, !1, 0, null), F.handleDragStop(P); + P.initMouseEvent("mouseup", !0, !0, window, 0, 0, 0, 0, 0, !1, !1, !1, !1, 0, null), U.handleDragStop(P); } } - }), oe(ne(F), "handleDragStop", function(ke) { - if (F.state.dragging) { - var Ne = (0, y.getControlPosition)(ke, F.state.touchIdentifier, ne(F)); + }), oe(ne(U), "handleDragStop", function(ke) { + if (U.state.dragging) { + var Ne = (0, b.getControlPosition)(ke, U.state.touchIdentifier, ne(U)); if (Ne != null) { - var Fe = Ne.x, Ae = Ne.y, Le = (0, y.createCoreData)(ne(F), Fe, Ae); - if (F.props.onStop(ke, Le) === !1 || F.mounted === !1) return !1; - var Ke = F.findDOMNode(); - Ke && F.props.enableUserSelectHack && (0, m.removeUserSelectStyles)(Ke.ownerDocument), (0, N.default)("DraggableCore: handleDragStop: %j", Le), F.setState({ dragging: !1, lastX: NaN, lastY: NaN }), Ke && ((0, N.default)("DraggableCore: Removing handlers"), (0, m.removeEvent)(Ke.ownerDocument, S.move, F.handleDrag), (0, m.removeEvent)(Ke.ownerDocument, S.stop, F.handleDragStop)); + var Ue = Ne.x, Ae = Ne.y, Le = (0, b.createCoreData)(ne(U), Ue, Ae); + if (U.props.onStop(ke, Le) === !1 || U.mounted === !1) return !1; + var Ke = U.findDOMNode(); + Ke && U.props.enableUserSelectHack && (0, m.removeUserSelectStyles)(Ke.ownerDocument), (0, N.default)("DraggableCore: handleDragStop: %j", Le), U.setState({ dragging: !1, lastX: NaN, lastY: NaN }), Ke && ((0, N.default)("DraggableCore: Removing handlers"), (0, m.removeEvent)(Ke.ownerDocument, S.move, U.handleDrag), (0, m.removeEvent)(Ke.ownerDocument, S.stop, U.handleDragStop)); } } - }), oe(ne(F), "onMouseDown", function(ke) { - return S = ge, F.handleDragStart(ke); - }), oe(ne(F), "onMouseUp", function(ke) { - return S = ge, F.handleDragStop(ke); - }), oe(ne(F), "onTouchStart", function(ke) { - return S = fe, F.handleDragStart(ke); - }), oe(ne(F), "onTouchEnd", function(ke) { - return S = fe, F.handleDragStop(ke); - }), F; - } - return ae = J, (G = [{ key: "componentDidMount", value: function() { + }), oe(ne(U), "onMouseDown", function(ke) { + return S = ge, U.handleDragStart(ke); + }), oe(ne(U), "onMouseUp", function(ke) { + return S = ge, U.handleDragStop(ke); + }), oe(ne(U), "onTouchStart", function(ke) { + return S = fe, U.handleDragStart(ke); + }), oe(ne(U), "onTouchEnd", function(ke) { + return S = fe, U.handleDragStop(ke); + }), U; + } + return ae = J, (Z = [{ key: "componentDidMount", value: function() { this.mounted = !0; - var F = this.findDOMNode(); - F && (0, m.addEvent)(F, fe.start, this.onTouchStart, { passive: !1 }); + var U = this.findDOMNode(); + U && (0, m.addEvent)(U, fe.start, this.onTouchStart, { passive: !1 }); } }, { key: "componentWillUnmount", value: function() { this.mounted = !1; - var F = this.findDOMNode(); - if (F) { - var X = F.ownerDocument; - (0, m.removeEvent)(X, ge.move, this.handleDrag), (0, m.removeEvent)(X, fe.move, this.handleDrag), (0, m.removeEvent)(X, ge.stop, this.handleDragStop), (0, m.removeEvent)(X, fe.stop, this.handleDragStop), (0, m.removeEvent)(F, fe.start, this.onTouchStart, { passive: !1 }), this.props.enableUserSelectHack && (0, m.removeUserSelectStyles)(X); + var U = this.findDOMNode(); + if (U) { + var G = U.ownerDocument; + (0, m.removeEvent)(G, ge.move, this.handleDrag), (0, m.removeEvent)(G, fe.move, this.handleDrag), (0, m.removeEvent)(G, ge.stop, this.handleDragStop), (0, m.removeEvent)(G, fe.stop, this.handleDragStop), (0, m.removeEvent)(U, fe.start, this.onTouchStart, { passive: !1 }), this.props.enableUserSelectHack && (0, m.removeUserSelectStyles)(G); } } }, { key: "findDOMNode", value: function() { return this.props.nodeRef ? this.props.nodeRef.current : C.default.findDOMNode(this); } }, { key: "render", value: function() { return k.cloneElement(k.Children.only(this.props.children), { onMouseDown: this.onMouseDown, onMouseUp: this.onMouseUp, onTouchEnd: this.onTouchEnd }); - } }]) && R(ae.prototype, G), J; + } }]) && R(ae.prototype, Z), J; })(k.Component); u.default = j, oe(j, "displayName", "DraggableCore"), oe(j, "propTypes", { allowAnyClick: d.default.bool, disabled: d.default.bool, enableUserSelectHack: d.default.bool, offsetParent: function(A, ae) { if (A[ae] && A[ae].nodeType !== 1) throw new Error("Draggable's offsetParent must be a DOM Node."); @@ -7524,23 +7598,23 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho (function() { var k = {}.hasOwnProperty; function d() { - for (var y = "", v = 0; v < arguments.length; v++) { + for (var b = "", v = 0; v < arguments.length; v++) { var N = arguments[v]; - N && (y = m(y, C(N))); + N && (b = m(b, C(N))); } - return y; + return b; } - function C(y) { - if (typeof y == "string" || typeof y == "number") return y; - if (typeof y != "object") return ""; - if (Array.isArray(y)) return d.apply(null, y); - if (y.toString !== Object.prototype.toString && !y.toString.toString().includes("[native code]")) return y.toString(); + function C(b) { + if (typeof b == "string" || typeof b == "number") return b; + if (typeof b != "object") return ""; + if (Array.isArray(b)) return d.apply(null, b); + if (b.toString !== Object.prototype.toString && !b.toString.toString().includes("[native code]")) return b.toString(); var v = ""; - for (var N in y) k.call(y, N) && y[N] && (v = m(v, N)); + for (var N in b) k.call(b, N) && b[N] && (v = m(v, N)); return v; } - function m(y, v) { - return v ? y ? y + " " + v : y + v : y; + function m(b, v) { + return v ? b ? b + " " + v : b + v : b; } i.exports ? (d.default = d, i.exports = d) : (f = (function() { return d; @@ -7564,26 +7638,26 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho if (f[k]) return new Error("Invalid prop ".concat(k, " passed to ").concat(d, " - do not set this, set it on the child.")); }; }, 7067: (i, u, f) => { - Object.defineProperty(u, "__esModule", { value: !0 }), u.default = function(y, v) { - var N = (0, C.default)(y); + Object.defineProperty(u, "__esModule", { value: !0 }), u.default = function(b, v) { + var N = (0, C.default)(b); if (!N.length) return void v.preventDefault(); var I = void 0, D = v.shiftKey, L = N[0], se = N[N.length - 1], ee = m(); - if (y === ee) { + if (b === ee) { if (!D) return; I = se; } if (se !== ee || D || (I = L), L === ee && D && (I = se), I) return v.preventDefault(), void I.focus(); var R = /(\bChrome\b|\bSafari\b)\//.exec(navigator.userAgent); if (!(R == null || R[1] == "Chrome" || /\biPod\b|\biPad\b/g.exec(navigator.userAgent) != null)) { - var U = N.indexOf(ee); - if (U > -1 && (U += D ? -1 : 1), (I = N[U]) === void 0) return v.preventDefault(), void (I = D ? se : L).focus(); + var F = N.indexOf(ee); + if (F > -1 && (F += D ? -1 : 1), (I = N[F]) === void 0) return v.preventDefault(), void (I = D ? se : L).focus(); v.preventDefault(), I.focus(); } }; var k, d = f(2411), C = (k = d) && k.__esModule ? k : { default: k }; function m() { - var y = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document; - return y.activeElement.shadowRoot ? m(y.activeElement.shadowRoot) : y.activeElement; + var b = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document; + return b.activeElement.shadowRoot ? m(b.activeElement.shadowRoot) : b.activeElement; } i.exports = u.default; }, 7195: (i, u, f) => { @@ -7603,20 +7677,20 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }, 7463: (i, u) => { var f, k, d, C, m; if (typeof window > "u" || typeof MessageChannel != "function") { - var y = null, v = null, N = function() { - if (y !== null) try { - var be = u.unstable_now(); - y(!0, be), y = null; + var b = null, v = null, N = function() { + if (b !== null) try { + var ye = u.unstable_now(); + b(!0, ye), b = null; } catch (P) { throw setTimeout(N, 0), P; } }, I = Date.now(); u.unstable_now = function() { return Date.now() - I; - }, f = function(be) { - y !== null ? setTimeout(f, 0, be) : (y = be, setTimeout(N, 0)); - }, k = function(be, P) { - v = setTimeout(be, P); + }, f = function(ye) { + b !== null ? setTimeout(f, 0, ye) : (b = ye, setTimeout(N, 0)); + }, k = function(ye, P) { + v = setTimeout(ye, P); }, d = function() { clearTimeout(v); }, C = function() { @@ -7633,63 +7707,63 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho return D.now(); }; else { - var U = L.now(); + var F = L.now(); u.unstable_now = function() { - return L.now() - U; + return L.now() - F; }; } var H = !1, ne = null, pe = -1, oe = 5, fe = 0; C = function() { return u.unstable_now() >= fe; }, m = function() { - }, u.unstable_forceFrameRate = function(be) { - 0 > be || 125 < be ? console.error("forceFrameRate takes a positive int between 0 and 125, forcing framerates higher than 125 fps is not unsupported") : oe = 0 < be ? Math.floor(1e3 / be) : 5; + }, u.unstable_forceFrameRate = function(ye) { + 0 > ye || 125 < ye ? console.error("forceFrameRate takes a positive int between 0 and 125, forcing framerates higher than 125 fps is not unsupported") : oe = 0 < ye ? Math.floor(1e3 / ye) : 5; }; var ge = new MessageChannel(), S = ge.port2; ge.port1.onmessage = function() { if (ne !== null) { - var be = u.unstable_now(); - fe = be + oe; + var ye = u.unstable_now(); + fe = ye + oe; try { - ne(!0, be) ? S.postMessage(null) : (H = !1, ne = null); + ne(!0, ye) ? S.postMessage(null) : (H = !1, ne = null); } catch (P) { throw S.postMessage(null), P; } } else H = !1; - }, f = function(be) { - ne = be, H || (H = !0, S.postMessage(null)); - }, k = function(be, P) { + }, f = function(ye) { + ne = ye, H || (H = !0, S.postMessage(null)); + }, k = function(ye, P) { pe = se(function() { - be(u.unstable_now()); + ye(u.unstable_now()); }, P); }, d = function() { ee(pe), pe = -1; }; } - function j(be, P) { - var te = be.length; - be.push(P); + function j(ye, P) { + var te = ye.length; + ye.push(P); e: for (; ; ) { - var we = te - 1 >>> 1, Se = be[we]; - if (!(Se !== void 0 && 0 < G(Se, P))) break e; - be[we] = P, be[te] = Se, te = we; + var we = te - 1 >>> 1, Se = ye[we]; + if (!(Se !== void 0 && 0 < Z(Se, P))) break e; + ye[we] = P, ye[te] = Se, te = we; } } - function A(be) { - return (be = be[0]) === void 0 ? null : be; + function A(ye) { + return (ye = ye[0]) === void 0 ? null : ye; } - function ae(be) { - var P = be[0]; + function ae(ye) { + var P = ye[0]; if (P !== void 0) { - var te = be.pop(); + var te = ye.pop(); if (te !== P) { - be[0] = te; - e: for (var we = 0, Se = be.length; we < Se; ) { - var Pe = 2 * (we + 1) - 1, _e = be[Pe], lt = Pe + 1, Qe = be[lt]; - if (_e !== void 0 && 0 > G(_e, te)) Qe !== void 0 && 0 > G(Qe, _e) ? (be[we] = Qe, be[lt] = te, we = lt) : (be[we] = _e, be[Pe] = te, we = Pe); + ye[0] = te; + e: for (var we = 0, Se = ye.length; we < Se; ) { + var Pe = 2 * (we + 1) - 1, _e = ye[Pe], lt = Pe + 1, Qe = ye[lt]; + if (_e !== void 0 && 0 > Z(_e, te)) Qe !== void 0 && 0 > Z(Qe, _e) ? (ye[we] = Qe, ye[lt] = te, we = lt) : (ye[we] = _e, ye[Pe] = te, we = Pe); else { - if (!(Qe !== void 0 && 0 > G(Qe, te))) break e; - be[we] = Qe, be[lt] = te, we = lt; + if (!(Qe !== void 0 && 0 > Z(Qe, te))) break e; + ye[we] = Qe, ye[lt] = te, we = lt; } } } @@ -7697,53 +7771,53 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } return null; } - function G(be, P) { - var te = be.sortIndex - P.sortIndex; - return te !== 0 ? te : be.id - P.id; + function Z(ye, P) { + var te = ye.sortIndex - P.sortIndex; + return te !== 0 ? te : ye.id - P.id; } - var Ee = [], J = [], F = 1, X = null, le = 3, me = !1, ke = !1, Ne = !1; - function Fe(be) { + var Ee = [], J = [], U = 1, G = null, le = 3, me = !1, ke = !1, Ne = !1; + function Ue(ye) { for (var P = A(J); P !== null; ) { if (P.callback === null) ae(J); else { - if (!(P.startTime <= be)) break; + if (!(P.startTime <= ye)) break; ae(J), P.sortIndex = P.expirationTime, j(Ee, P); } P = A(J); } } - function Ae(be) { - if (Ne = !1, Fe(be), !ke) if (A(Ee) !== null) ke = !0, f(Le); + function Ae(ye) { + if (Ne = !1, Ue(ye), !ke) if (A(Ee) !== null) ke = !0, f(Le); else { var P = A(J); - P !== null && k(Ae, P.startTime - be); + P !== null && k(Ae, P.startTime - ye); } } - function Le(be, P) { + function Le(ye, P) { ke = !1, Ne && (Ne = !1, d()), me = !0; var te = le; try { - for (Fe(P), X = A(Ee); X !== null && (!(X.expirationTime > P) || be && !C()); ) { - var we = X.callback; + for (Ue(P), G = A(Ee); G !== null && (!(G.expirationTime > P) || ye && !C()); ) { + var we = G.callback; if (we !== null) { - X.callback = null, le = X.priorityLevel; - var Se = we(X.expirationTime <= P); - P = u.unstable_now(), typeof Se == "function" ? X.callback = Se : X === A(Ee) && ae(Ee), Fe(P); + G.callback = null, le = G.priorityLevel; + var Se = we(G.expirationTime <= P); + P = u.unstable_now(), typeof Se == "function" ? G.callback = Se : G === A(Ee) && ae(Ee), Ue(P); } else ae(Ee); - X = A(Ee); + G = A(Ee); } - if (X !== null) var Pe = !0; + if (G !== null) var Pe = !0; else { var _e = A(J); _e !== null && k(Ae, _e.startTime - P), Pe = !1; } return Pe; } finally { - X = null, le = te, me = !1; + G = null, le = te, me = !1; } } - function Ke(be) { - switch (be) { + function Ke(ye) { + switch (ye) { case 1: return -1; case 2: @@ -7757,15 +7831,15 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } } var Je = m; - u.unstable_IdlePriority = 5, u.unstable_ImmediatePriority = 1, u.unstable_LowPriority = 4, u.unstable_NormalPriority = 3, u.unstable_Profiling = null, u.unstable_UserBlockingPriority = 2, u.unstable_cancelCallback = function(be) { - be.callback = null; + u.unstable_IdlePriority = 5, u.unstable_ImmediatePriority = 1, u.unstable_LowPriority = 4, u.unstable_NormalPriority = 3, u.unstable_Profiling = null, u.unstable_UserBlockingPriority = 2, u.unstable_cancelCallback = function(ye) { + ye.callback = null; }, u.unstable_continueExecution = function() { ke || me || (ke = !0, f(Le)); }, u.unstable_getCurrentPriorityLevel = function() { return le; }, u.unstable_getFirstCallbackNode = function() { return A(Ee); - }, u.unstable_next = function(be) { + }, u.unstable_next = function(ye) { switch (le) { case 1: case 2: @@ -7778,13 +7852,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho var te = le; le = P; try { - return be(); + return ye(); } finally { le = te; } }, u.unstable_pauseExecution = function() { - }, u.unstable_requestPaint = Je, u.unstable_runWithPriority = function(be, P) { - switch (be) { + }, u.unstable_requestPaint = Je, u.unstable_runWithPriority = function(ye, P) { + switch (ye) { case 1: case 2: case 3: @@ -7792,34 +7866,34 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho case 5: break; default: - be = 3; + ye = 3; } var te = le; - le = be; + le = ye; try { return P(); } finally { le = te; } - }, u.unstable_scheduleCallback = function(be, P, te) { + }, u.unstable_scheduleCallback = function(ye, P, te) { var we = u.unstable_now(); if (typeof te == "object" && te !== null) { var Se = te.delay; - Se = typeof Se == "number" && 0 < Se ? we + Se : we, te = typeof te.timeout == "number" ? te.timeout : Ke(be); - } else te = Ke(be), Se = we; - return be = { id: F++, callback: P, priorityLevel: be, startTime: Se, expirationTime: te = Se + te, sortIndex: -1 }, Se > we ? (be.sortIndex = Se, j(J, be), A(Ee) === null && be === A(J) && (Ne ? d() : Ne = !0, k(Ae, Se - we))) : (be.sortIndex = te, j(Ee, be), ke || me || (ke = !0, f(Le))), be; + Se = typeof Se == "number" && 0 < Se ? we + Se : we, te = typeof te.timeout == "number" ? te.timeout : Ke(ye); + } else te = Ke(ye), Se = we; + return ye = { id: U++, callback: P, priorityLevel: ye, startTime: Se, expirationTime: te = Se + te, sortIndex: -1 }, Se > we ? (ye.sortIndex = Se, j(J, ye), A(Ee) === null && ye === A(J) && (Ne ? d() : Ne = !0, k(Ae, Se - we))) : (ye.sortIndex = te, j(Ee, ye), ke || me || (ke = !0, f(Le))), ye; }, u.unstable_shouldYield = function() { - var be = u.unstable_now(); - Fe(be); + var ye = u.unstable_now(); + Ue(ye); var P = A(Ee); - return P !== X && X !== null && P !== null && P.callback !== null && P.startTime <= be && P.expirationTime < X.expirationTime || C(); - }, u.unstable_wrapCallback = function(be) { + return P !== G && G !== null && P !== null && P.callback !== null && P.startTime <= ye && P.expirationTime < G.expirationTime || C(); + }, u.unstable_wrapCallback = function(ye) { var P = le; return function() { var te = le; le = P; try { - return be.apply(this, arguments); + return ye.apply(this, arguments); } finally { le = te; } @@ -7827,25 +7901,25 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }; }, 7727: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.resetState = function() { - for (var I = [m, y], D = 0; D < I.length; D++) { + for (var I = [m, b], D = 0; D < I.length; D++) { var L = I[D]; L && L.parentNode && L.parentNode.removeChild(L); } - m = y = null, v = []; + m = b = null, v = []; }, u.log = function() { console.log("bodyTrap ----------"), console.log(v.length); - for (var I = [m, y], D = 0; D < I.length; D++) { + for (var I = [m, b], D = 0; D < I.length; D++) { var L = I[D] || {}; console.log(L.nodeName, L.className, L.id); } console.log("edn bodyTrap ----------"); }; - var k, d = f(9628), C = (k = d) && k.__esModule ? k : { default: k }, m = void 0, y = void 0, v = []; + var k, d = f(9628), C = (k = d) && k.__esModule ? k : { default: k }, m = void 0, b = void 0, v = []; function N() { v.length !== 0 && v[v.length - 1].focusContent(); } C.default.subscribe(function(I, D) { - m || y || ((m = document.createElement("div")).setAttribute("data-react-modal-body-trap", ""), m.style.position = "absolute", m.style.opacity = "0", m.setAttribute("tabindex", "0"), m.addEventListener("focus", N), (y = m.cloneNode()).addEventListener("focus", N)), (v = D).length > 0 ? (document.body.firstChild !== m && document.body.insertBefore(m, document.body.firstChild), document.body.lastChild !== y && document.body.appendChild(y)) : (m.parentElement && m.parentElement.removeChild(m), y.parentElement && y.parentElement.removeChild(y)); + m || b || ((m = document.createElement("div")).setAttribute("data-react-modal-body-trap", ""), m.style.position = "absolute", m.style.opacity = "0", m.setAttribute("tabindex", "0"), m.addEventListener("focus", N), (b = m.cloneNode()).addEventListener("focus", N)), (v = D).length > 0 ? (document.body.firstChild !== m && document.body.insertBefore(m, document.body.firstChild), document.body.lastChild !== b && document.body.appendChild(b)) : (m.parentElement && m.parentElement.removeChild(m), b.parentElement && b.parentElement.removeChild(b)); }); }, 7785: (i, u, f) => { var k = f(5072), d = f(2444); @@ -7868,19 +7942,19 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho }, u.popWithoutFocus = function() { m.length > 0 && m.pop(); }, u.setupScopedFocus = function(D) { - y = D, window.addEventListener ? (window.addEventListener("blur", N, !1), document.addEventListener("focus", I, !0)) : (window.attachEvent("onBlur", N), document.attachEvent("onFocus", I)); + b = D, window.addEventListener ? (window.addEventListener("blur", N, !1), document.addEventListener("focus", I, !0)) : (window.attachEvent("onBlur", N), document.attachEvent("onFocus", I)); }, u.teardownScopedFocus = function() { - y = null, window.addEventListener ? (window.removeEventListener("blur", N), document.removeEventListener("focus", I)) : (window.detachEvent("onBlur", N), document.detachEvent("onFocus", I)); + b = null, window.addEventListener ? (window.removeEventListener("blur", N), document.removeEventListener("focus", I)) : (window.detachEvent("onBlur", N), document.detachEvent("onFocus", I)); }; - var k, d = f(2411), C = (k = d) && k.__esModule ? k : { default: k }, m = [], y = null, v = !1; + var k, d = f(2411), C = (k = d) && k.__esModule ? k : { default: k }, m = [], b = null, v = !1; function N() { v = !0; } function I() { if (v) { - if (v = !1, !y) return; + if (v = !1, !b) return; setTimeout(function() { - y.contains(document.activeElement) || ((0, C.default)(y)[0] || y).focus(); + b.contains(document.activeElement) || ((0, C.default)(b)[0] || b).focus(); }, 0); } } @@ -7890,30 +7964,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho u.objectToString = (v, N, I, D) => { if (typeof Buffer == "function" && Buffer.isBuffer(v)) return `Buffer.from(${I(v.toString("base64"))}, 'base64')`; if (typeof f.g == "object" && v === f.g) return m(v, N, I); - const L = y[Object.prototype.toString.call(v)]; + const L = b[Object.prototype.toString.call(v)]; return L ? L(v, N, I, D) : void 0; }; - const m = (v, N, I) => `Function(${I("return this")})()`, y = { "[object Array]": C.arrayToString, "[object Object]": (v, N, I, D) => { + const m = (v, N, I) => `Function(${I("return this")})()`, b = { "[object Array]": C.arrayToString, "[object Object]": (v, N, I, D) => { const L = N ? ` -` : "", se = N ? " " : "", ee = Object.keys(v).reduce(function(R, U) { - const H = v[U], ne = I(H, U); +` : "", se = N ? " " : "", ee = Object.keys(v).reduce(function(R, F) { + const H = v[F], ne = I(H, F); if (ne === void 0) return R; const pe = ne.split(` `).join(` ${N}`); - return d.USED_METHOD_KEY.has(H) ? (R.push(`${N}${pe}`), R) : (R.push(`${N}${k.quoteKey(U, I)}:${se}${pe}`), R); + return d.USED_METHOD_KEY.has(H) ? (R.push(`${N}${pe}`), R) : (R.push(`${N}${k.quoteKey(F, I)}:${se}${pe}`), R); }, []).join(`,${L}`); return ee === "" ? "{}" : `{${L}${ee}${L}}`; }, "[object Error]": (v, N, I) => `new Error(${I(v.message)})`, "[object Date]": (v) => `new Date(${v.getTime()})`, "[object String]": (v, N, I) => `new String(${I(v.toString())})`, "[object Number]": (v) => `new Number(${v})`, "[object Boolean]": (v) => `new Boolean(${v})`, "[object Set]": (v, N, I) => `new Set(${I(Array.from(v))})`, "[object Map]": (v, N, I) => `new Map(${I(Array.from(v))})`, "[object RegExp]": String, "[object global]": m, "[object Window]": m }; }, 7965: (i, u, f) => { var k = f(6426), d = { "text/plain": "Text", "text/html": "Url", default: "Text" }; i.exports = function(C, m) { - var y, v, N, I, D, L, se = !1; - m || (m = {}), y = m.debug || !1; + var b, v, N, I, D, L, se = !1; + m || (m = {}), b = m.debug || !1; try { if (N = k(), I = document.createRange(), D = document.getSelection(), (L = document.createElement("span")).textContent = C, L.ariaHidden = "true", L.style.all = "unset", L.style.position = "fixed", L.style.top = 0, L.style.clip = "rect(0, 0, 0, 0)", L.style.whiteSpace = "pre", L.style.webkitUserSelect = "text", L.style.MozUserSelect = "text", L.style.msUserSelect = "text", L.style.userSelect = "text", L.addEventListener("copy", function(ee) { if (ee.stopPropagation(), m.format) if (ee.preventDefault(), ee.clipboardData === void 0) { - y && console.warn("unable to use e.clipboardData"), y && console.warn("trying IE specific stuff"), window.clipboardData.clearData(); + b && console.warn("unable to use e.clipboardData"), b && console.warn("trying IE specific stuff"), window.clipboardData.clearData(); var R = d[m.format] || d.default; window.clipboardData.setData(R, C); } else ee.clipboardData.clearData(), ee.clipboardData.setData(m.format, C); @@ -7921,13 +7995,13 @@ ${N}`); }), document.body.appendChild(L), I.selectNodeContents(L), D.addRange(I), !document.execCommand("copy")) throw new Error("copy command was unsuccessful"); se = !0; } catch (ee) { - y && console.error("unable to copy using execCommand: ", ee), y && console.warn("trying IE specific stuff"); + b && console.error("unable to copy using execCommand: ", ee), b && console.warn("trying IE specific stuff"); try { window.clipboardData.setData(m.format || "text", C), m.onCopy && m.onCopy(window.clipboardData), se = !0; } catch (R) { - y && console.error("unable to copy using clipboardData: ", R), y && console.error("falling back to prompt"), v = (function(U) { + b && console.error("unable to copy using clipboardData: ", R), b && console.error("falling back to prompt"), v = (function(F) { var H = (/mac os x/i.test(navigator.userAgent) ? "⌘" : "Ctrl") + "+C"; - return U.replace(/#{\s*key\s*}/g, H); + return F.replace(/#{\s*key\s*}/g, H); })("message" in m ? m.message : "Copy to clipboard: #{key}, Enter"), window.prompt(v, C); } } finally { @@ -7937,84 +8011,84 @@ ${N}`); }; }, 8142: (i, u, f) => { i = f.nmd(i); - var k = "__lodash_hash_undefined__", d = 9007199254740991, C = "[object Arguments]", m = "[object Array]", y = "[object Boolean]", v = "[object Date]", N = "[object Error]", I = "[object Function]", D = "[object Map]", L = "[object Number]", se = "[object Object]", ee = "[object Promise]", R = "[object RegExp]", U = "[object Set]", H = "[object String]", ne = "[object Symbol]", pe = "[object WeakMap]", oe = "[object ArrayBuffer]", fe = "[object DataView]", ge = /^\[object .+?Constructor\]$/, S = /^(?:0|[1-9]\d*)$/, j = {}; - j["[object Float32Array]"] = j["[object Float64Array]"] = j["[object Int8Array]"] = j["[object Int16Array]"] = j["[object Int32Array]"] = j["[object Uint8Array]"] = j["[object Uint8ClampedArray]"] = j["[object Uint16Array]"] = j["[object Uint32Array]"] = !0, j[C] = j[m] = j[oe] = j[y] = j[fe] = j[v] = j[N] = j[I] = j[D] = j[L] = j[se] = j[R] = j[U] = j[H] = j[pe] = !1; - var A = typeof f.g == "object" && f.g && f.g.Object === Object && f.g, ae = typeof self == "object" && self && self.Object === Object && self, G = A || ae || Function("return this")(), Ee = u && !u.nodeType && u, J = Ee && i && !i.nodeType && i, F = J && J.exports === Ee, X = F && A.process, le = (function() { + var k = "__lodash_hash_undefined__", d = 9007199254740991, C = "[object Arguments]", m = "[object Array]", b = "[object Boolean]", v = "[object Date]", N = "[object Error]", I = "[object Function]", D = "[object Map]", L = "[object Number]", se = "[object Object]", ee = "[object Promise]", R = "[object RegExp]", F = "[object Set]", H = "[object String]", ne = "[object Symbol]", pe = "[object WeakMap]", oe = "[object ArrayBuffer]", fe = "[object DataView]", ge = /^\[object .+?Constructor\]$/, S = /^(?:0|[1-9]\d*)$/, j = {}; + j["[object Float32Array]"] = j["[object Float64Array]"] = j["[object Int8Array]"] = j["[object Int16Array]"] = j["[object Int32Array]"] = j["[object Uint8Array]"] = j["[object Uint8ClampedArray]"] = j["[object Uint16Array]"] = j["[object Uint32Array]"] = !0, j[C] = j[m] = j[oe] = j[b] = j[fe] = j[v] = j[N] = j[I] = j[D] = j[L] = j[se] = j[R] = j[F] = j[H] = j[pe] = !1; + var A = typeof f.g == "object" && f.g && f.g.Object === Object && f.g, ae = typeof self == "object" && self && self.Object === Object && self, Z = A || ae || Function("return this")(), Ee = u && !u.nodeType && u, J = Ee && i && !i.nodeType && i, U = J && J.exports === Ee, G = U && A.process, le = (function() { try { - return X && X.binding && X.binding("util"); + return G && G.binding && G.binding("util"); } catch { } })(), me = le && le.isTypedArray; function ke(M, Q) { - for (var ye = -1, De = M == null ? 0 : M.length; ++ye < De; ) if (Q(M[ye], ye, M)) return !0; + for (var be = -1, De = M == null ? 0 : M.length; ++be < De; ) if (Q(M[be], be, M)) return !0; return !1; } function Ne(M) { - var Q = -1, ye = Array(M.size); + var Q = -1, be = Array(M.size); return M.forEach(function(De, tt) { - ye[++Q] = [tt, De]; - }), ye; + be[++Q] = [tt, De]; + }), be; } - function Fe(M) { - var Q = -1, ye = Array(M.size); + function Ue(M) { + var Q = -1, be = Array(M.size); return M.forEach(function(De) { - ye[++Q] = De; - }), ye; + be[++Q] = De; + }), be; } - var Ae, Le, Ke, Je = Array.prototype, be = Function.prototype, P = Object.prototype, te = G["__core-js_shared__"], we = be.toString, Se = P.hasOwnProperty, Pe = (Ae = /[^.]+$/.exec(te && te.keys && te.keys.IE_PROTO || "")) ? "Symbol(src)_1." + Ae : "", _e = P.toString, lt = RegExp("^" + we.call(Se).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), Qe = F ? G.Buffer : void 0, et = G.Symbol, Pt = G.Uint8Array, ko = P.propertyIsEnumerable, Dt = Je.splice, Gt = et ? et.toStringTag : void 0, On = Object.getOwnPropertySymbols, Nn = Qe ? Qe.isBuffer : void 0, wo = (Le = Object.keys, Ke = Object, function(M) { + var Ae, Le, Ke, Je = Array.prototype, ye = Function.prototype, P = Object.prototype, te = Z["__core-js_shared__"], we = ye.toString, Se = P.hasOwnProperty, Pe = (Ae = /[^.]+$/.exec(te && te.keys && te.keys.IE_PROTO || "")) ? "Symbol(src)_1." + Ae : "", _e = P.toString, lt = RegExp("^" + we.call(Se).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), Qe = U ? Z.Buffer : void 0, et = Z.Symbol, Pt = Z.Uint8Array, ko = P.propertyIsEnumerable, Dt = Je.splice, Gt = et ? et.toStringTag : void 0, On = Object.getOwnPropertySymbols, Nn = Qe ? Qe.isBuffer : void 0, wo = (Le = Object.keys, Ke = Object, function(M) { return Le(Ke(M)); - }), Bn = In(G, "DataView"), $n = In(G, "Map"), an = In(G, "Promise"), pn = In(G, "Set"), sr = In(G, "WeakMap"), Ht = In(Object, "create"), Wr = mn(Bn), qr = mn($n), _o = mn(an), Eo = mn(pn), xo = mn(sr), Wn = et ? et.prototype : void 0, Kt = Wn ? Wn.valueOf : void 0; + }), $n = In(Z, "DataView"), Bn = In(Z, "Map"), an = In(Z, "Promise"), pn = In(Z, "Set"), sr = In(Z, "WeakMap"), Ht = In(Object, "create"), Wr = mn($n), qr = mn(Bn), _o = mn(an), Eo = mn(pn), xo = mn(sr), Wn = et ? et.prototype : void 0, Kt = Wn ? Wn.valueOf : void 0; function zt(M) { - var Q = -1, ye = M == null ? 0 : M.length; - for (this.clear(); ++Q < ye; ) { + var Q = -1, be = M == null ? 0 : M.length; + for (this.clear(); ++Q < be; ) { var De = M[Q]; this.set(De[0], De[1]); } } function Ye(M) { - var Q = -1, ye = M == null ? 0 : M.length; - for (this.clear(); ++Q < ye; ) { + var Q = -1, be = M == null ? 0 : M.length; + for (this.clear(); ++Q < be; ) { var De = M[Q]; this.set(De[0], De[1]); } } function Pn(M) { - var Q = -1, ye = M == null ? 0 : M.length; - for (this.clear(); ++Q < ye; ) { + var Q = -1, be = M == null ? 0 : M.length; + for (this.clear(); ++Q < be; ) { var De = M[Q]; this.set(De[0], De[1]); } } function qn(M) { - var Q = -1, ye = M == null ? 0 : M.length; - for (this.__data__ = new Pn(); ++Q < ye; ) this.add(M[Q]); + var Q = -1, be = M == null ? 0 : M.length; + for (this.__data__ = new Pn(); ++Q < be; ) this.add(M[Q]); } function sn(M) { var Q = this.__data__ = new Ye(M); this.size = Q.size; } function Kr(M, Q) { - var ye = ct(M), De = !ye && gn(M), tt = !ye && !De && Dr(M), He = !ye && !De && !tt && Ir(M), Ge = ye || De || tt || He, rt = Ge ? (function(ht, kt) { - for (var jt = -1, bt = Array(ht); ++jt < ht; ) bt[jt] = kt(jt); - return bt; + var be = ct(M), De = !be && gn(M), tt = !be && !De && Dr(M), He = !be && !De && !tt && Ir(M), Ge = be || De || tt || He, rt = Ge ? (function(ht, kt) { + for (var jt = -1, yt = Array(ht); ++jt < ht; ) yt[jt] = kt(jt); + return yt; })(M.length, String) : [], At = rt.length; - for (var ft in M) !Se.call(M, ft) || Ge && (ft == "length" || tt && (ft == "offset" || ft == "parent") || He && (ft == "buffer" || ft == "byteLength" || ft == "byteOffset") || yi(ft, At)) || rt.push(ft); + for (var ft in M) !Se.call(M, ft) || Ge && (ft == "length" || tt && (ft == "offset" || ft == "parent") || He && (ft == "buffer" || ft == "byteLength" || ft == "byteOffset") || bi(ft, At)) || rt.push(ft); return rt; } function Or(M, Q) { - for (var ye = M.length; ye--; ) if (Yr(M[ye][0], Q)) return ye; + for (var be = M.length; be--; ) if (Yr(M[be][0], Q)) return be; return -1; } function fn(M) { return M == null ? M === void 0 ? "[object Undefined]" : "[object Null]" : Gt && Gt in Object(M) ? (function(Q) { - var ye = Se.call(Q, Gt), De = Q[Gt]; + var be = Se.call(Q, Gt), De = Q[Gt]; try { Q[Gt] = void 0; var tt = !0; } catch { } var He = _e.call(Q); - return tt && (ye ? Q[Gt] = De : delete Q[Gt]), He; + return tt && (be ? Q[Gt] = De : delete Q[Gt]), He; })(M) : (function(Q) { return _e.call(Q); })(M); @@ -8022,21 +8096,21 @@ ${N}`); function pt(M) { return Rn(M) && fn(M) == C; } - function Qr(M, Q, ye, De, tt) { + function Qr(M, Q, be, De, tt) { return M === Q || (M == null || Q == null || !Rn(M) && !Rn(Q) ? M != M && Q != Q : (function(He, Ge, rt, At, ft, ht) { - var kt = ct(He), jt = ct(Ge), bt = kt ? m : hn(He), yt = jt ? m : hn(Ge), bn = (bt = bt == C ? se : bt) == se, ur = (yt = yt == C ? se : yt) == se, Mn = bt == yt; + var kt = ct(He), jt = ct(Ge), yt = kt ? m : hn(He), bt = jt ? m : hn(Ge), yn = (yt = yt == C ? se : yt) == se, ur = (bt = bt == C ? se : bt) == se, Mn = yt == bt; if (Mn && Dr(He)) { if (!Dr(Ge)) return !1; - kt = !0, bn = !1; + kt = !0, yn = !1; } - if (Mn && !bn) return ht || (ht = new sn()), kt || Ir(He) ? Dn(He, Ge, rt, At, ft, ht) : (function(nt, Ze, Yn, vn, dr, ut, wt) { + if (Mn && !yn) return ht || (ht = new sn()), kt || Ir(He) ? Dn(He, Ge, rt, At, ft, ht) : (function(nt, Ze, Yn, vn, dr, ut, wt) { switch (Yn) { case fe: if (nt.byteLength != Ze.byteLength || nt.byteOffset != Ze.byteOffset) return !1; nt = nt.buffer, Ze = Ze.buffer; case oe: return !(nt.byteLength != Ze.byteLength || !ut(new Pt(nt), new Pt(Ze))); - case y: + case b: case v: case L: return Yr(+nt, +Ze); @@ -8047,9 +8121,9 @@ ${N}`); return nt == Ze + ""; case D: var Tt = Ne; - case U: + case F: var Lt = 1 & vn; - if (Tt || (Tt = Fe), nt.size != Ze.size && !Lt) return !1; + if (Tt || (Tt = Ue), nt.size != Ze.size && !Lt) return !1; var kn = wt.get(nt); if (kn) return kn == Ze; vn |= 2, wt.set(nt, Ze); @@ -8059,11 +8133,11 @@ ${N}`); if (Kt) return Kt.call(nt) == Kt.call(Ze); } return !1; - })(He, Ge, bt, rt, At, ft, ht); + })(He, Ge, yt, rt, At, ft, ht); if (!(1 & rt)) { - var yn = bn && Se.call(He, "__wrapped__"), Xr = ur && Se.call(Ge, "__wrapped__"); - if (yn || Xr) { - var To = yn ? He.value() : He, Oo = Xr ? Ge.value() : Ge; + var bn = yn && Se.call(He, "__wrapped__"), Xr = ur && Se.call(Ge, "__wrapped__"); + if (bn || Xr) { + var To = bn ? He.value() : He, Oo = Xr ? Ge.value() : Ge; return ht || (ht = new sn()), ft(To, Oo, rt, At, ht); } } @@ -8093,7 +8167,7 @@ ${N}`); } return ut.delete(nt), ut.delete(Ze), pr; })(He, Ge, rt, At, ft, ht)) : !1; - })(M, Q, ye, De, Qr, tt)); + })(M, Q, be, De, Qr, tt)); } function So(M) { return !(!Qn(M) || (function(Q) { @@ -8101,34 +8175,34 @@ ${N}`); })(M)) && (Kn(M) ? lt : ge).test(mn(M)); } function Nr(M) { - if (ye = (Q = M) && Q.constructor, De = typeof ye == "function" && ye.prototype || P, Q !== De) return wo(M); - var Q, ye, De, tt = []; + if (be = (Q = M) && Q.constructor, De = typeof be == "function" && be.prototype || P, Q !== De) return wo(M); + var Q, be, De, tt = []; for (var He in Object(M)) Se.call(M, He) && He != "constructor" && tt.push(He); return tt; } - function Dn(M, Q, ye, De, tt, He) { - var Ge = 1 & ye, rt = M.length, At = Q.length; + function Dn(M, Q, be, De, tt, He) { + var Ge = 1 & be, rt = M.length, At = Q.length; if (rt != At && !(Ge && At > rt)) return !1; var ft = He.get(M); if (ft && He.get(Q)) return ft == Q; - var ht = -1, kt = !0, jt = 2 & ye ? new qn() : void 0; + var ht = -1, kt = !0, jt = 2 & be ? new qn() : void 0; for (He.set(M, Q), He.set(Q, M); ++ht < rt; ) { - var bt = M[ht], yt = Q[ht]; - if (De) var bn = Ge ? De(yt, bt, ht, Q, M, He) : De(bt, yt, ht, M, Q, He); - if (bn !== void 0) { - if (bn) continue; + var yt = M[ht], bt = Q[ht]; + if (De) var yn = Ge ? De(bt, yt, ht, Q, M, He) : De(yt, bt, ht, M, Q, He); + if (yn !== void 0) { + if (yn) continue; kt = !1; break; } if (jt) { if (!ke(Q, function(ur, Mn) { - if (yn = Mn, !jt.has(yn) && (bt === ur || tt(bt, ur, ye, De, He))) return jt.push(Mn); - var yn; + if (bn = Mn, !jt.has(bn) && (yt === ur || tt(yt, ur, be, De, He))) return jt.push(Mn); + var bn; })) { kt = !1; break; } - } else if (bt !== yt && !tt(bt, yt, ye, De, He)) { + } else if (yt !== bt && !tt(yt, bt, be, De, He)) { kt = !1; break; } @@ -8136,8 +8210,8 @@ ${N}`); return He.delete(M), He.delete(Q), kt; } function Pr(M) { - return (function(Q, ye, De) { - var tt = ye(Q); + return (function(Q, be, De) { + var tt = be(Q); return ct(Q) ? tt : (function(He, Ge) { for (var rt = -1, At = Ge.length, ft = He.length; ++rt < At; ) He[ft + rt] = Ge[rt]; return He; @@ -8145,14 +8219,14 @@ ${N}`); })(M, Rr, Co); } function lr(M, Q) { - var ye, De, tt = M.__data__; - return ((De = typeof (ye = Q)) == "string" || De == "number" || De == "symbol" || De == "boolean" ? ye !== "__proto__" : ye === null) ? tt[typeof Q == "string" ? "string" : "hash"] : tt.map; + var be, De, tt = M.__data__; + return ((De = typeof (be = Q)) == "string" || De == "number" || De == "symbol" || De == "boolean" ? be !== "__proto__" : be === null) ? tt[typeof Q == "string" ? "string" : "hash"] : tt.map; } function In(M, Q) { - var ye = (function(De, tt) { + var be = (function(De, tt) { return De == null ? void 0 : De[tt]; })(M, Q); - return So(ye) ? ye : void 0; + return So(be) ? be : void 0; } zt.prototype.clear = function() { this.__data__ = Ht ? Ht(null) : {}, this.size = 0; @@ -8162,31 +8236,31 @@ ${N}`); }, zt.prototype.get = function(M) { var Q = this.__data__; if (Ht) { - var ye = Q[M]; - return ye === k ? void 0 : ye; + var be = Q[M]; + return be === k ? void 0 : be; } return Se.call(Q, M) ? Q[M] : void 0; }, zt.prototype.has = function(M) { var Q = this.__data__; return Ht ? Q[M] !== void 0 : Se.call(Q, M); }, zt.prototype.set = function(M, Q) { - var ye = this.__data__; - return this.size += this.has(M) ? 0 : 1, ye[M] = Ht && Q === void 0 ? k : Q, this; + var be = this.__data__; + return this.size += this.has(M) ? 0 : 1, be[M] = Ht && Q === void 0 ? k : Q, this; }, Ye.prototype.clear = function() { this.__data__ = [], this.size = 0; }, Ye.prototype.delete = function(M) { - var Q = this.__data__, ye = Or(Q, M); - return !(ye < 0) && (ye == Q.length - 1 ? Q.pop() : Dt.call(Q, ye, 1), --this.size, !0); + var Q = this.__data__, be = Or(Q, M); + return !(be < 0) && (be == Q.length - 1 ? Q.pop() : Dt.call(Q, be, 1), --this.size, !0); }, Ye.prototype.get = function(M) { - var Q = this.__data__, ye = Or(Q, M); - return ye < 0 ? void 0 : Q[ye][1]; + var Q = this.__data__, be = Or(Q, M); + return be < 0 ? void 0 : Q[be][1]; }, Ye.prototype.has = function(M) { return Or(this.__data__, M) > -1; }, Ye.prototype.set = function(M, Q) { - var ye = this.__data__, De = Or(ye, M); - return De < 0 ? (++this.size, ye.push([M, Q])) : ye[De][1] = Q, this; + var be = this.__data__, De = Or(be, M); + return De < 0 ? (++this.size, be.push([M, Q])) : be[De][1] = Q, this; }, Pn.prototype.clear = function() { - this.size = 0, this.__data__ = { hash: new zt(), map: new ($n || Ye)(), string: new zt() }; + this.size = 0, this.__data__ = { hash: new zt(), map: new (Bn || Ye)(), string: new zt() }; }, Pn.prototype.delete = function(M) { var Q = lr(this, M).delete(M); return this.size -= Q ? 1 : 0, Q; @@ -8195,8 +8269,8 @@ ${N}`); }, Pn.prototype.has = function(M) { return lr(this, M).has(M); }, Pn.prototype.set = function(M, Q) { - var ye = lr(this, M), De = ye.size; - return ye.set(M, Q), this.size += ye.size == De ? 0 : 1, this; + var be = lr(this, M), De = be.size; + return be.set(M, Q), this.size += be.size == De ? 0 : 1, this; }, qn.prototype.add = qn.prototype.push = function(M) { return this.__data__.set(M, k), this; }, qn.prototype.has = function(M) { @@ -8204,26 +8278,26 @@ ${N}`); }, sn.prototype.clear = function() { this.__data__ = new Ye(), this.size = 0; }, sn.prototype.delete = function(M) { - var Q = this.__data__, ye = Q.delete(M); - return this.size = Q.size, ye; + var Q = this.__data__, be = Q.delete(M); + return this.size = Q.size, be; }, sn.prototype.get = function(M) { return this.__data__.get(M); }, sn.prototype.has = function(M) { return this.__data__.has(M); }, sn.prototype.set = function(M, Q) { - var ye = this.__data__; - if (ye instanceof Ye) { - var De = ye.__data__; - if (!$n || De.length < 199) return De.push([M, Q]), this.size = ++ye.size, this; - ye = this.__data__ = new Pn(De); + var be = this.__data__; + if (be instanceof Ye) { + var De = be.__data__; + if (!Bn || De.length < 199) return De.push([M, Q]), this.size = ++be.size, this; + be = this.__data__ = new Pn(De); } - return ye.set(M, Q), this.size = ye.size, this; + return be.set(M, Q), this.size = be.size, this; }; var Co = On ? function(M) { - return M == null ? [] : (M = Object(M), (function(Q, ye) { + return M == null ? [] : (M = Object(M), (function(Q, be) { for (var De = -1, tt = Q == null ? 0 : Q.length, He = 0, Ge = []; ++De < tt; ) { var rt = Q[De]; - ye(rt, De, Q) && (Ge[He++] = rt); + be(rt, De, Q) && (Ge[He++] = rt); } return Ge; })(On(M), function(Q) { @@ -8232,7 +8306,7 @@ ${N}`); } : function() { return []; }, hn = fn; - function yi(M, Q) { + function bi(M, Q) { return !!(Q = Q ?? d) && (typeof M == "number" || S.test(M)) && M > -1 && M % 1 == 0 && M < Q; } function mn(M) { @@ -8251,8 +8325,8 @@ ${N}`); function Yr(M, Q) { return M === Q || M != M && Q != Q; } - (Bn && hn(new Bn(new ArrayBuffer(1))) != fe || $n && hn(new $n()) != D || an && hn(an.resolve()) != ee || pn && hn(new pn()) != U || sr && hn(new sr()) != pe) && (hn = function(M) { - var Q = fn(M), ye = Q == se ? M.constructor : void 0, De = ye ? mn(ye) : ""; + ($n && hn(new $n(new ArrayBuffer(1))) != fe || Bn && hn(new Bn()) != D || an && hn(an.resolve()) != ee || pn && hn(new pn()) != F || sr && hn(new sr()) != pe) && (hn = function(M) { + var Q = fn(M), be = Q == se ? M.constructor : void 0, De = be ? mn(be) : ""; if (De) switch (De) { case Wr: return fe; @@ -8261,7 +8335,7 @@ ${N}`); case _o: return ee; case Eo: - return U; + return F; case xo: return pe; } @@ -8334,8 +8408,8 @@ ${N}`); const C = d; }, 8814: (i, u) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.arrayToString = void 0, u.arrayToString = (f, k, d) => { - const C = f.map(function(y, v) { - const N = d(y, v); + const C = f.map(function(b, v) { + const N = d(b, v); return N === void 0 ? String(N) : k + N.split(` `).join(` ${k}`); @@ -8357,31 +8431,31 @@ ${k}`); var C = { injectType: "singletonStyleTag", attributes: { "data-cke-inspector": !0 }, insert: "head", singleton: !0 }; k(d, C), i.exports = d.locals || {}; }, 8989: (i, u) => { - var f = 60103, k = 60106, d = 60107, C = 60108, m = 60114, y = 60109, v = 60110, N = 60112, I = 60113, D = 60120, L = 60115, se = 60116; + var f = 60103, k = 60106, d = 60107, C = 60108, m = 60114, b = 60109, v = 60110, N = 60112, I = 60113, D = 60120, L = 60115, se = 60116; if (typeof Symbol == "function" && Symbol.for) { var ee = Symbol.for; - f = ee("react.element"), k = ee("react.portal"), d = ee("react.fragment"), C = ee("react.strict_mode"), m = ee("react.profiler"), y = ee("react.provider"), v = ee("react.context"), N = ee("react.forward_ref"), I = ee("react.suspense"), D = ee("react.suspense_list"), L = ee("react.memo"), se = ee("react.lazy"), ee("react.block"), ee("react.server.block"), ee("react.fundamental"), ee("react.debug_trace_mode"), ee("react.legacy_hidden"); + f = ee("react.element"), k = ee("react.portal"), d = ee("react.fragment"), C = ee("react.strict_mode"), m = ee("react.profiler"), b = ee("react.provider"), v = ee("react.context"), N = ee("react.forward_ref"), I = ee("react.suspense"), D = ee("react.suspense_list"), L = ee("react.memo"), se = ee("react.lazy"), ee("react.block"), ee("react.server.block"), ee("react.fundamental"), ee("react.debug_trace_mode"), ee("react.legacy_hidden"); } - function R(U) { - if (typeof U == "object" && U !== null) { - var H = U.$$typeof; + function R(F) { + if (typeof F == "object" && F !== null) { + var H = F.$$typeof; switch (H) { case f: - switch (U = U.type) { + switch (F = F.type) { case d: case m: case C: case I: case D: - return U; + return F; default: - switch (U = U && U.$$typeof) { + switch (F = F && F.$$typeof) { case v: case N: case se: case L: - case y: - return U; + case b: + return F; default: return H; } @@ -8391,8 +8465,8 @@ ${k}`); } } } - u.isContextConsumer = function(U) { - return R(U) === v; + u.isContextConsumer = function(F) { + return R(F) === v; }; }, 9090: (i, u, f) => { Object.defineProperty(u, "__esModule", { value: !0 }); @@ -8416,14 +8490,14 @@ ${k}`); return function(fe, ge, S) { return ge && oe(fe.prototype, ge), S && oe(fe, S), fe; }; - })(), m = f(6540), y = U(f(5556)), v = R(f(7791)), N = U(f(7067)), I = R(f(6462)), D = R(f(4838)), L = f(834), se = U(L), ee = U(f(9628)); + })(), m = f(6540), b = F(f(5556)), v = R(f(7791)), N = F(f(7067)), I = R(f(6462)), D = R(f(4838)), L = f(834), se = F(L), ee = F(f(9628)); function R(oe) { if (oe && oe.__esModule) return oe; var fe = {}; if (oe != null) for (var ge in oe) Object.prototype.hasOwnProperty.call(oe, ge) && (fe[ge] = oe[ge]); return fe.default = oe, fe; } - function U(oe) { + function F(oe) { return oe && oe.__esModule ? oe : { default: oe }; } f(7727); @@ -8441,8 +8515,8 @@ ${k}`); }, S.setContentRef = function(j) { S.content = j, S.props.contentRef && S.props.contentRef(j); }, S.afterClose = function() { - var j = S.props, A = j.appElement, ae = j.ariaHideApp, G = j.htmlOpenClassName, Ee = j.bodyOpenClassName, J = j.parentSelector, F = J && J().ownerDocument || document; - Ee && D.remove(F.body, Ee), G && D.remove(F.getElementsByTagName("html")[0], G), ae && ne > 0 && (ne -= 1) === 0 && I.show(A), S.props.shouldFocusAfterRender && (S.props.shouldReturnFocusAfterClose ? (v.returnFocus(S.props.preventScroll), v.teardownScopedFocus()) : v.popWithoutFocus()), S.props.onAfterClose && S.props.onAfterClose(), ee.default.deregister(S); + var j = S.props, A = j.appElement, ae = j.ariaHideApp, Z = j.htmlOpenClassName, Ee = j.bodyOpenClassName, J = j.parentSelector, U = J && J().ownerDocument || document; + Ee && D.remove(U.body, Ee), Z && D.remove(U.getElementsByTagName("html")[0], Z), ae && ne > 0 && (ne -= 1) === 0 && I.show(A), S.props.shouldFocusAfterRender && (S.props.shouldReturnFocusAfterClose ? (v.returnFocus(S.props.preventScroll), v.teardownScopedFocus()) : v.popWithoutFocus()), S.props.onAfterClose && S.props.onAfterClose(), ee.default.deregister(S); }, S.open = function() { S.beforeOpen(), S.state.afterOpen && S.state.beforeClose ? (clearTimeout(S.closeTimer), S.setState({ beforeClose: !1 })) : (S.props.shouldFocusAfterRender && (v.setupScopedFocus(S.node), v.markForFocusLater()), S.setState({ isOpen: !0 }, function() { S.openAnimationFrame = requestAnimationFrame(function() { @@ -8485,11 +8559,11 @@ ${k}`); }, S.contentHasFocus = function() { return document.activeElement === S.content || S.content.contains(document.activeElement); }, S.buildClassName = function(j, A) { - var ae = (A === void 0 ? "undefined" : d(A)) === "object" ? A : { base: H[j], afterOpen: H[j] + "--after-open", beforeClose: H[j] + "--before-close" }, G = ae.base; - return S.state.afterOpen && (G = G + " " + ae.afterOpen), S.state.beforeClose && (G = G + " " + ae.beforeClose), typeof A == "string" && A ? G + " " + A : G; + var ae = (A === void 0 ? "undefined" : d(A)) === "object" ? A : { base: H[j], afterOpen: H[j] + "--after-open", beforeClose: H[j] + "--before-close" }, Z = ae.base; + return S.state.afterOpen && (Z = Z + " " + ae.afterOpen), S.state.beforeClose && (Z = Z + " " + ae.beforeClose), typeof A == "string" && A ? Z + " " + A : Z; }, S.attributesFromObject = function(j, A) { - return Object.keys(A).reduce(function(ae, G) { - return ae[j + "-" + G] = A[G], ae; + return Object.keys(A).reduce(function(ae, Z) { + return ae[j + "-" + Z] = A[Z], ae; }, {}); }, S.state = { afterOpen: !1, beforeClose: !1 }, S.shouldClose = null, S.moveFromContentToOverlay = null, S; } @@ -8503,16 +8577,16 @@ ${k}`); } }, { key: "componentWillUnmount", value: function() { this.state.isOpen && this.afterClose(), clearTimeout(this.closeTimer), cancelAnimationFrame(this.openAnimationFrame); } }, { key: "beforeOpen", value: function() { - var ge = this.props, S = ge.appElement, j = ge.ariaHideApp, A = ge.htmlOpenClassName, ae = ge.bodyOpenClassName, G = ge.parentSelector, Ee = G && G().ownerDocument || document; + var ge = this.props, S = ge.appElement, j = ge.ariaHideApp, A = ge.htmlOpenClassName, ae = ge.bodyOpenClassName, Z = ge.parentSelector, Ee = Z && Z().ownerDocument || document; ae && D.add(Ee.body, ae), A && D.add(Ee.getElementsByTagName("html")[0], A), j && (ne += 1, I.hide(S)), ee.default.register(this); } }, { key: "render", value: function() { - var ge = this.props, S = ge.id, j = ge.className, A = ge.overlayClassName, ae = ge.defaultStyles, G = ge.children, Ee = j ? {} : ae.content, J = A ? {} : ae.overlay; + var ge = this.props, S = ge.id, j = ge.className, A = ge.overlayClassName, ae = ge.defaultStyles, Z = ge.children, Ee = j ? {} : ae.content, J = A ? {} : ae.overlay; if (this.shouldBeClosed()) return null; - var F = { ref: this.setOverlayRef, className: this.buildClassName("overlay", A), style: k({}, J, this.props.style.overlay), onClick: this.handleOverlayOnClick, onMouseDown: this.handleOverlayOnMouseDown }, X = k({ id: S, ref: this.setContentRef, style: k({}, Ee, this.props.style.content), className: this.buildClassName("content", j), tabIndex: "-1", onKeyDown: this.handleKeyDown, onMouseDown: this.handleContentOnMouseDown, onMouseUp: this.handleContentOnMouseUp, onClick: this.handleContentOnClick, role: this.props.role, "aria-label": this.props.contentLabel }, this.attributesFromObject("aria", k({ modal: !0 }, this.props.aria)), this.attributesFromObject("data", this.props.data || {}), { "data-testid": this.props.testId }), le = this.props.contentElement(X, G); - return this.props.overlayElement(F, le); + var U = { ref: this.setOverlayRef, className: this.buildClassName("overlay", A), style: k({}, J, this.props.style.overlay), onClick: this.handleOverlayOnClick, onMouseDown: this.handleOverlayOnMouseDown }, G = k({ id: S, ref: this.setContentRef, style: k({}, Ee, this.props.style.content), className: this.buildClassName("content", j), tabIndex: "-1", onKeyDown: this.handleKeyDown, onMouseDown: this.handleContentOnMouseDown, onMouseUp: this.handleContentOnMouseUp, onClick: this.handleContentOnClick, role: this.props.role, "aria-label": this.props.contentLabel }, this.attributesFromObject("aria", k({ modal: !0 }, this.props.aria)), this.attributesFromObject("data", this.props.data || {}), { "data-testid": this.props.testId }), le = this.props.contentElement(G, Z); + return this.props.overlayElement(U, le); } }]), fe; })(m.Component); - pe.defaultProps = { style: { overlay: {}, content: {} }, defaultStyles: {} }, pe.propTypes = { isOpen: y.default.bool.isRequired, defaultStyles: y.default.shape({ content: y.default.object, overlay: y.default.object }), style: y.default.shape({ content: y.default.object, overlay: y.default.object }), className: y.default.oneOfType([y.default.string, y.default.object]), overlayClassName: y.default.oneOfType([y.default.string, y.default.object]), parentSelector: y.default.func, bodyOpenClassName: y.default.string, htmlOpenClassName: y.default.string, ariaHideApp: y.default.bool, appElement: y.default.oneOfType([y.default.instanceOf(se.default), y.default.instanceOf(L.SafeHTMLCollection), y.default.instanceOf(L.SafeNodeList), y.default.arrayOf(y.default.instanceOf(se.default))]), onAfterOpen: y.default.func, onAfterClose: y.default.func, onRequestClose: y.default.func, closeTimeoutMS: y.default.number, shouldFocusAfterRender: y.default.bool, shouldCloseOnOverlayClick: y.default.bool, shouldReturnFocusAfterClose: y.default.bool, preventScroll: y.default.bool, role: y.default.string, contentLabel: y.default.string, aria: y.default.object, data: y.default.object, children: y.default.node, shouldCloseOnEsc: y.default.bool, overlayRef: y.default.func, contentRef: y.default.func, id: y.default.string, overlayElement: y.default.func, contentElement: y.default.func, testId: y.default.string }, u.default = pe, i.exports = u.default; + pe.defaultProps = { style: { overlay: {}, content: {} }, defaultStyles: {} }, pe.propTypes = { isOpen: b.default.bool.isRequired, defaultStyles: b.default.shape({ content: b.default.object, overlay: b.default.object }), style: b.default.shape({ content: b.default.object, overlay: b.default.object }), className: b.default.oneOfType([b.default.string, b.default.object]), overlayClassName: b.default.oneOfType([b.default.string, b.default.object]), parentSelector: b.default.func, bodyOpenClassName: b.default.string, htmlOpenClassName: b.default.string, ariaHideApp: b.default.bool, appElement: b.default.oneOfType([b.default.instanceOf(se.default), b.default.instanceOf(L.SafeHTMLCollection), b.default.instanceOf(L.SafeNodeList), b.default.arrayOf(b.default.instanceOf(se.default))]), onAfterOpen: b.default.func, onAfterClose: b.default.func, onRequestClose: b.default.func, closeTimeoutMS: b.default.number, shouldFocusAfterRender: b.default.bool, shouldCloseOnOverlayClick: b.default.bool, shouldReturnFocusAfterClose: b.default.bool, preventScroll: b.default.bool, role: b.default.string, contentLabel: b.default.string, aria: b.default.object, data: b.default.object, children: b.default.node, shouldCloseOnEsc: b.default.bool, overlayRef: b.default.func, contentRef: b.default.func, id: b.default.string, overlayElement: b.default.func, contentElement: b.default.func, testId: b.default.string }, u.default = pe, i.exports = u.default; }, 9628: (i, u) => { Object.defineProperty(u, "__esModule", { value: !0 }), u.log = function() { console.log("portalOpenInstances ----------"), console.log(k.openInstances.length), k.openInstances.forEach(function(d) { @@ -8523,18 +8597,18 @@ ${k}`); }; var f = function d() { var C = this; - (function(m, y) { - if (!(m instanceof y)) throw new TypeError("Cannot call a class as a function"); + (function(m, b) { + if (!(m instanceof b)) throw new TypeError("Cannot call a class as a function"); })(this, d), this.register = function(m) { C.openInstances.indexOf(m) === -1 && (C.openInstances.push(m), C.emit("register")); }, this.deregister = function(m) { - var y = C.openInstances.indexOf(m); - y !== -1 && (C.openInstances.splice(y, 1), C.emit("deregister")); + var b = C.openInstances.indexOf(m); + b !== -1 && (C.openInstances.splice(b, 1), C.emit("deregister")); }, this.subscribe = function(m) { C.subscribers.push(m); }, this.emit = function(m) { - C.subscribers.forEach(function(y) { - return y(m, C.openInstances.slice()); + C.subscribers.forEach(function(b) { + return b(m, C.openInstances.slice()); }); }, this.openInstances = [], this.subscribers = []; }, k = new f(); @@ -8584,9 +8658,9 @@ ${k}`); })(), T.o = (i, u) => Object.prototype.hasOwnProperty.call(i, u), T.r = (i) => { typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(i, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(i, "__esModule", { value: !0 }); }, T.nmd = (i) => (i.paths = [], i.children || (i.children = []), i), T.nc = void 0; - var Z = {}; + var X = {}; return (() => { - T.d(Z, { default: () => Be }); + T.d(X, { default: () => $e }); var i = T(6540), u = T(961); function f(l) { return "Minified Redux error #" + l + "; visit https://redux.js.org/Errors?code=" + l + " for the full message or use the non-minified dev environment for full errors. "; @@ -8599,21 +8673,21 @@ ${k}`); for (var o = l; Object.getPrototypeOf(o) !== null; ) o = Object.getPrototypeOf(o); return Object.getPrototypeOf(l) === o; } - function y(l, o, s) { + function b(l, o, s) { var c; if (typeof o == "function" && typeof s == "function" || typeof s == "function" && typeof arguments[3] == "function") throw new Error(f(0)); if (typeof o == "function" && s === void 0 && (s = o, o = void 0), s !== void 0) { if (typeof s != "function") throw new Error(f(1)); - return s(y)(l, o); + return s(b)(l, o); } if (typeof l != "function") throw new Error(f(2)); - var g = l, b = o, x = [], z = x, K = !1; + var g = l, y = o, x = [], z = x, K = !1; function Y() { z === x && (z = x.slice()); } function ie() { if (K) throw new Error(f(3)); - return b; + return y; } function ue(de) { if (typeof de != "function") throw new Error(f(4)); @@ -8633,7 +8707,7 @@ ${k}`); if (de.type === void 0) throw new Error(f(8)); if (K) throw new Error(f(9)); try { - K = !0, b = g(b, de); + K = !0, y = g(y, de); } finally { K = !1; } @@ -8670,7 +8744,7 @@ ${k}`); function g() { x.onStateChange && x.onStateChange(); } - function b() { + function y() { s || (s = o ? o.addNestedSub(g) : l.subscribe(g), c = (function() { var z = I(), K = null, Y = null; return { clear: function() { @@ -8691,12 +8765,12 @@ ${k}`); })()); } var x = { addNestedSub: function(z) { - return b(), c.subscribe(z); + return y(), c.subscribe(z); }, notifyNestedSubs: function() { c.notify(); }, handleChangeWrapper: g, isSubscribed: function() { return !!s; - }, trySubscribe: b, tryUnsubscribe: function() { + }, trySubscribe: y, tryUnsubscribe: function() { s && (s(), s = void 0, c.clear(), c = D); }, getListeners: function() { return c; @@ -8708,15 +8782,15 @@ ${k}`); var o = l.store, s = l.context, c = l.children, g = (0, i.useMemo)(function() { var z = L(o); return { store: o, subscription: z }; - }, [o]), b = (0, i.useMemo)(function() { + }, [o]), y = (0, i.useMemo)(function() { return o.getState(); }, [o]); se(function() { var z = g.subscription; - return z.onStateChange = z.notifyNestedSubs, z.trySubscribe(), b !== o.getState() && z.notifyNestedSubs(), function() { + return z.onStateChange = z.notifyNestedSubs, z.trySubscribe(), y !== o.getState() && z.notifyNestedSubs(), function() { z.tryUnsubscribe(), z.onStateChange = null; }; - }, [g, b]); + }, [g, y]); var x = s || v; return i.createElement(x.Provider, { value: g }, c); }; @@ -8729,7 +8803,7 @@ ${k}`); return l; }, R.apply(null, arguments); } - function U(l, o) { + function F(l, o) { if (l == null) return {}; var s = {}; for (var c in l) if ({}.hasOwnProperty.call(l, c)) { @@ -8748,10 +8822,10 @@ ${k}`); return l.apply(void 0, o); }, s); } - function ae(l, o, s, c, g, b, x) { - l.current = c, o.current = g, s.current = !1, b.current && (b.current = null, x()); + function ae(l, o, s, c, g, y, x) { + l.current = c, o.current = g, s.current = !1, y.current && (y.current = null, x()); } - function G(l, o, s, c, g, b, x, z, K, Y) { + function Z(l, o, s, c, g, y, x, z, K, Y) { if (l) { var ie = !1, ue = null, he = function() { if (!ie) { @@ -8761,7 +8835,7 @@ ${k}`); } catch (ze) { Oe = ze, ue = ze; } - Oe || (ue = null), de === b.current ? x.current || K() : (b.current = de, z.current = de, x.current = !0, Y({ type: "STORE_UPDATED", payload: { error: Oe } })); + Oe || (ue = null), de === y.current ? x.current || K() : (y.current = de, z.current = de, x.current = !0, Y({ type: "STORE_UPDATED", payload: { error: Oe } })); } }; return s.onStateChange = he, s.trySubscribe(), he(), function() { @@ -8776,35 +8850,35 @@ ${k}`); o === void 0 && (o = {}); var s = o, c = s.getDisplayName, g = c === void 0 ? function(je) { return "ConnectAdvanced(" + je + ")"; - } : c, b = s.methodName, x = b === void 0 ? "connectAdvanced" : b, z = s.renderCountProp, K = z === void 0 ? void 0 : z, Y = s.shouldHandleStateChanges, ie = Y === void 0 || Y, ue = s.storeKey, he = ue === void 0 ? "store" : ue, de = (s.withRef, s.forwardRef), Oe = de !== void 0 && de, Ce = s.context, ze = Ce === void 0 ? v : Ce, st = U(s, oe), $e = ze; + } : c, y = s.methodName, x = y === void 0 ? "connectAdvanced" : y, z = s.renderCountProp, K = z === void 0 ? void 0 : z, Y = s.shouldHandleStateChanges, ie = Y === void 0 || Y, ue = s.storeKey, he = ue === void 0 ? "store" : ue, de = (s.withRef, s.forwardRef), Oe = de !== void 0 && de, Ce = s.context, ze = Ce === void 0 ? v : Ce, st = F(s, oe), Be = ze; return function(je) { - var dt = je.displayName || je.name || "Component", vt = g(dt), $t = R({}, st, { getDisplayName: g, methodName: x, renderCountProp: K, shouldHandleStateChanges: ie, storeKey: he, displayName: vt, wrappedComponentName: dt, WrappedComponent: je }), xt = st.pure, It = xt ? i.useMemo : function(it) { + var dt = je.displayName || je.name || "Component", vt = g(dt), Bt = R({}, st, { getDisplayName: g, methodName: x, renderCountProp: K, shouldHandleStateChanges: ie, storeKey: he, displayName: vt, wrappedComponentName: dt, WrappedComponent: je }), xt = st.pure, It = xt ? i.useMemo : function(it) { return it(); }; function St(it) { var xn = (0, i.useMemo)(function() { - var ir = it.reactReduxForwardedRef, Vo = U(it, fe); + var ir = it.reactReduxForwardedRef, Vo = F(it, fe); return [it.context, ir, Vo]; }, [it]), jn = xn[0], lo = xn[1], Wt = xn[2], Jt = (0, i.useMemo)(function() { - return jn && jn.Consumer && (0, pe.isContextConsumer)(i.createElement(jn.Consumer, null)) ? jn : $e; - }, [jn, $e]), en = (0, i.useContext)(Jt), qt = !!it.store && !!it.store.getState && !!it.store.dispatch; + return jn && jn.Consumer && (0, pe.isContextConsumer)(i.createElement(jn.Consumer, null)) ? jn : Be; + }, [jn, Be]), en = (0, i.useContext)(Jt), qt = !!it.store && !!it.store.getState && !!it.store.dispatch; en && en.store; var cn = qt ? it.store : en.store, Nt = (0, i.useMemo)(function() { return (function(ir) { - return l(ir.dispatch, $t); + return l(ir.dispatch, Bt); })(cn); - }, [cn]), Ut = (0, i.useMemo)(function() { + }, [cn]), Ft = (0, i.useMemo)(function() { if (!ie) return S; var ir = L(cn, qt ? null : en.subscription), Vo = ir.notifyNestedSubs.bind(ir); return [ir, Vo]; - }, [cn, qt, en]), un = Ut[0], or = Ut[1], Hi = (0, i.useMemo)(function() { + }, [cn, qt, en]), un = Ft[0], or = Ft[1], Hi = (0, i.useMemo)(function() { return qt ? en : R({}, en, { subscription: un }); - }, [qt, en, un]), Bi = (0, i.useReducer)(j, ge, Ee), tn = Bi[0][0], Ta = Bi[1]; + }, [qt, en, un]), $i = (0, i.useReducer)(j, ge, Ee), tn = $i[0][0], Ta = $i[1]; if (tn && tn.error) throw tn.error; - var Uo = (0, i.useRef)(), nn = (0, i.useRef)(Wt), Vr = (0, i.useRef)(), Fo = (0, i.useRef)(!1), wr = It(function() { + var Fo = (0, i.useRef)(), nn = (0, i.useRef)(Wt), Vr = (0, i.useRef)(), Uo = (0, i.useRef)(!1), wr = It(function() { return Vr.current && Wt === nn.current ? Vr.current : Nt(cn.getState(), Wt); }, [cn, tn, Wt]); - A(ae, [nn, Uo, Fo, Wt, wr, Vr, or]), A(G, [ie, cn, un, Nt, nn, Uo, Fo, Vr, or, Ta], [cn, un, Nt]); + A(ae, [nn, Fo, Uo, Wt, wr, Vr, or]), A(Z, [ie, cn, un, Nt, nn, Fo, Uo, Vr, or, Ta], [cn, un, Nt]); var co = (0, i.useMemo)(function() { return i.createElement(je, R({}, wr, { ref: lo })); }, [lo, je, wr]); @@ -8822,15 +8896,15 @@ ${k}`); return ne()(mt, je); }; } - function F(l, o) { + function U(l, o) { return l === o ? l !== 0 || o !== 0 || 1 / l == 1 / o : l != l && o != o; } - function X(l, o) { - if (F(l, o)) return !0; + function G(l, o) { + if (U(l, o)) return !0; if (typeof l != "object" || l === null || typeof o != "object" || o === null) return !1; var s = Object.keys(l), c = Object.keys(o); if (s.length !== c.length) return !1; - for (var g = 0; g < s.length; g++) if (!Object.prototype.hasOwnProperty.call(o, s[g]) || !F(l[s[g]], o[s[g]])) return !1; + for (var g = 0; g < s.length; g++) if (!Object.prototype.hasOwnProperty.call(o, s[g]) || !U(l[s[g]], o[s[g]])) return !1; return !0; } function le(l) { @@ -8848,13 +8922,13 @@ ${k}`); function ke(l, o) { return function(s, c) { c.displayName; - var g = function(b, x) { - return g.dependsOnOwnProps ? g.mapToProps(b, x) : g.mapToProps(b); + var g = function(y, x) { + return g.dependsOnOwnProps ? g.mapToProps(y, x) : g.mapToProps(y); }; - return g.dependsOnOwnProps = !0, g.mapToProps = function(b, x) { + return g.dependsOnOwnProps = !0, g.mapToProps = function(y, x) { g.mapToProps = l, g.dependsOnOwnProps = me(l); - var z = g(b, x); - return typeof z == "function" && (g.mapToProps = z, g.dependsOnOwnProps = me(z), z = g(b, x)), z; + var z = g(y, x); + return typeof z == "function" && (g.mapToProps = z, g.dependsOnOwnProps = me(z), z = g(y, x)), z; }, g; }; } @@ -8867,17 +8941,17 @@ ${k}`); }, function(l) { return l && typeof l == "object" ? le(function(o) { return (function(s, c) { - var g = {}, b = function(z) { + var g = {}, y = function(z) { var K = s[z]; typeof K == "function" && (g[z] = function() { return c(K.apply(void 0, arguments)); }); }; - for (var x in s) b(x); + for (var x in s) y(x); return g; })(l, o); }) : void 0; - }], Fe = [function(l) { + }], Ue = [function(l) { return typeof l == "function" ? ke(l) : void 0; }, function(l) { return l ? void 0 : le(function() { @@ -8891,10 +8965,10 @@ ${k}`); return typeof l == "function" ? /* @__PURE__ */ (function(o) { return function(s, c) { c.displayName; - var g, b = c.pure, x = c.areMergedPropsEqual, z = !1; + var g, y = c.pure, x = c.areMergedPropsEqual, z = !1; return function(K, Y, ie) { var ue = o(K, Y, ie); - return z ? b && x(ue, g) || (g = ue) : (z = !0, g = ue), g; + return z ? y && x(ue, g) || (g = ue) : (z = !0, g = ue), g; }; }; })(l) : void 0; @@ -8905,23 +8979,23 @@ ${k}`); }]; var Ke = ["initMapStateToProps", "initMapDispatchToProps", "initMergeProps"]; function Je(l, o, s, c) { - return function(g, b) { - return s(l(g, b), o(c, b), b); + return function(g, y) { + return s(l(g, y), o(c, y), y); }; } - function be(l, o, s, c, g) { - var b, x, z, K, Y, ie = g.areStatesEqual, ue = g.areOwnPropsEqual, he = g.areStatePropsEqual, de = !1; + function ye(l, o, s, c, g) { + var y, x, z, K, Y, ie = g.areStatesEqual, ue = g.areOwnPropsEqual, he = g.areStatePropsEqual, de = !1; function Oe(Ce, ze) { - var st, $e, je = !ue(ze, x), dt = !ie(Ce, b, ze, x); - return b = Ce, x = ze, je && dt ? (z = l(b, x), o.dependsOnOwnProps && (K = o(c, x)), Y = s(z, K, x)) : je ? (l.dependsOnOwnProps && (z = l(b, x)), o.dependsOnOwnProps && (K = o(c, x)), Y = s(z, K, x)) : (dt && (st = l(b, x), $e = !he(st, z), z = st, $e && (Y = s(z, K, x))), Y); + var st, Be, je = !ue(ze, x), dt = !ie(Ce, y, ze, x); + return y = Ce, x = ze, je && dt ? (z = l(y, x), o.dependsOnOwnProps && (K = o(c, x)), Y = s(z, K, x)) : je ? (l.dependsOnOwnProps && (z = l(y, x)), o.dependsOnOwnProps && (K = o(c, x)), Y = s(z, K, x)) : (dt && (st = l(y, x), Be = !he(st, z), z = st, Be && (Y = s(z, K, x))), Y); } return function(Ce, ze) { - return de ? Oe(Ce, ze) : (z = l(b = Ce, x = ze), K = o(c, x), Y = s(z, K, x), de = !0, Y); + return de ? Oe(Ce, ze) : (z = l(y = Ce, x = ze), K = o(c, x), Y = s(z, K, x), de = !0, Y); }; } function P(l, o) { - var s = o.initMapStateToProps, c = o.initMapDispatchToProps, g = o.initMergeProps, b = U(o, Ke), x = s(l, b), z = c(l, b), K = g(l, b); - return (b.pure ? be : Je)(x, z, K, l, b); + var s = o.initMapStateToProps, c = o.initMapDispatchToProps, g = o.initMergeProps, y = F(o, Ke), x = s(l, y), z = c(l, y), K = g(l, y); + return (y.pure ? ye : Je)(x, z, K, l, y); } var te = ["pure", "areStatesEqual", "areOwnPropsEqual", "areStatePropsEqual", "areMergedPropsEqual"]; function we(l, o, s) { @@ -8929,7 +9003,7 @@ ${k}`); var g = o[c](l); if (g) return g; } - return function(b, x) { + return function(y, x) { throw new Error("Invalid value of type " + typeof l + " for " + s + " argument when connecting component " + x.wrappedComponentName + "."); }; } @@ -8937,13 +9011,13 @@ ${k}`); return l === o; } function Pe(l) { - var o = {}, s = o.connectHOC, c = s === void 0 ? J : s, g = o.mapStateToPropsFactories, b = g === void 0 ? Fe : g, x = o.mapDispatchToPropsFactories, z = x === void 0 ? Ne : x, K = o.mergePropsFactories, Y = K === void 0 ? Le : K, ie = o.selectorFactory, ue = ie === void 0 ? P : ie; + var o = {}, s = o.connectHOC, c = s === void 0 ? J : s, g = o.mapStateToPropsFactories, y = g === void 0 ? Ue : g, x = o.mapDispatchToPropsFactories, z = x === void 0 ? Ne : x, K = o.mergePropsFactories, Y = K === void 0 ? Le : K, ie = o.selectorFactory, ue = ie === void 0 ? P : ie; return function(he, de, Oe, Ce) { Ce === void 0 && (Ce = {}); - var ze = Ce, st = ze.pure, $e = st === void 0 || st, je = ze.areStatesEqual, dt = je === void 0 ? Se : je, vt = ze.areOwnPropsEqual, $t = vt === void 0 ? X : vt, xt = ze.areStatePropsEqual, It = xt === void 0 ? X : xt, St = ze.areMergedPropsEqual, mt = St === void 0 ? X : St, En = U(ze, te), it = we(he, b, "mapStateToProps"), xn = we(de, z, "mapDispatchToProps"), jn = we(Oe, Y, "mergeProps"); + var ze = Ce, st = ze.pure, Be = st === void 0 || st, je = ze.areStatesEqual, dt = je === void 0 ? Se : je, vt = ze.areOwnPropsEqual, Bt = vt === void 0 ? G : vt, xt = ze.areStatePropsEqual, It = xt === void 0 ? G : xt, St = ze.areMergedPropsEqual, mt = St === void 0 ? G : St, En = F(ze, te), it = we(he, y, "mapStateToProps"), xn = we(de, z, "mapDispatchToProps"), jn = we(Oe, Y, "mergeProps"); return c(ue, R({ methodName: "connect", getDisplayName: function(lo) { return "Connect(" + lo + ")"; - }, shouldHandleStateChanges: !!he, initMapStateToProps: it, initMapDispatchToProps: xn, initMergeProps: jn, pure: $e, areStatesEqual: dt, areOwnPropsEqual: $t, areStatePropsEqual: It, areMergedPropsEqual: mt }, En)); + }, shouldHandleStateChanges: !!he, initMapStateToProps: it, initMapDispatchToProps: xn, initMergeProps: jn, pure: Be, areStatesEqual: dt, areOwnPropsEqual: Bt, areStatePropsEqual: It, areMergedPropsEqual: mt }, En)); }; } const _e = Pe(); @@ -8956,7 +9030,7 @@ ${k}`); function Nn() { return { type: Gt }; } - const wo = "TOGGLE_IS_COLLAPSED", Bn = "SET_HEIGHT", $n = "SET_SIDE_PANE_WIDTH", an = "SET_EDITORS", pn = "SET_CURRENT_EDITOR_NAME", sr = "UPDATE_CURRENT_EDITOR_IS_READ_ONLY", Ht = "SET_ACTIVE_INSPECTOR_TAB"; + const wo = "TOGGLE_IS_COLLAPSED", $n = "SET_HEIGHT", Bn = "SET_SIDE_PANE_WIDTH", an = "SET_EDITORS", pn = "SET_CURRENT_EDITOR_NAME", sr = "UPDATE_CURRENT_EDITOR_IS_READ_ONLY", Ht = "SET_ACTIVE_INSPECTOR_TAB"; function Wr() { return { type: wo }; } @@ -9045,21 +9119,21 @@ ${k}`); s.attributes[c] = { value: g }; }), s.properties = pt(s.properties), s.attributes = pt(s.attributes); for (const c in s.attributes) { - const g = {}, b = l.model.schema.getAttributeProperties(c); - for (const x in b) g[x] = { value: b[x] }; + const g = {}, y = l.model.schema.getAttributeProperties(c); + for (const x in y) g[x] = { value: y[x] }; s.attributes[c].subProperties = pt(g); } return s; } function In(l, o) { const s = {}, { startOffset: c, endOffset: g } = l; - return Object.assign(s, { startOffset: c, endOffset: g, node: l, path: l.getPath(), positionsBefore: [], positionsAfter: [] }), xo(l) ? (function(b, x) { - const z = b.node; - Object.assign(b, { type: "element", name: z.name, children: [], maxOffset: z.maxOffset, positions: [] }); - for (const K of z.getChildren()) b.children.push(In(K, x)); + return Object.assign(s, { startOffset: c, endOffset: g, node: l, path: l.getPath(), positionsBefore: [], positionsAfter: [] }), xo(l) ? (function(y, x) { + const z = y.node; + Object.assign(y, { type: "element", name: z.name, children: [], maxOffset: z.maxOffset, positions: [] }); + for (const K of z.getChildren()) y.children.push(In(K, x)); (function(K, Y) { for (const ie of Y) { - const ue = yi(K, ie); + const ue = bi(K, ie); for (const he of ue) { const de = he.offset; if (de === 0) { @@ -9076,8 +9150,8 @@ ${k}`); break; } if (Ce.endOffset === de) { - const ze = K.children[Oe + 1], st = Ce.type === "text" && ze && ze.type === "element", $e = Ce.type === "element" && ze && ze.type === "text", je = Ce.type === "text" && ze && ze.type === "text"; - he.isEnd && (st || $e || je) ? ze.positionsBefore.push(he) : Ce.positionsAfter.push(he); + const ze = K.children[Oe + 1], st = Ce.type === "text" && ze && ze.type === "element", Be = Ce.type === "element" && ze && ze.type === "text", je = Ce.type === "text" && ze && ze.type === "text"; + he.isEnd && (st || Be || je) ? ze.positionsBefore.push(he) : Ce.positionsAfter.push(he); break; } if (Ce.startOffset < de && Ce.endOffset > de) { @@ -9089,10 +9163,10 @@ ${k}`); } } } - })(b, x), b.attributes = Co(z); - })(s, o) : (function(b) { - const x = b.node; - Object.assign(b, { type: "text", text: x.data, positions: [], presentation: { dontRenderAttributeValue: !0 } }), b.attributes = Co(x); + })(y, x), y.attributes = Co(z); + })(s, o) : (function(y) { + const x = y.node; + Object.assign(y, { type: "text", text: x.data, positions: [], presentation: { dontRenderAttributeValue: !0 } }), y.attributes = Co(x); })(s), s; } function Co(l) { @@ -9102,9 +9176,9 @@ ${k}`); function hn(l) { return [...l.getAttributes()].sort(([o], [s]) => o < s ? -1 : 1); } - function yi(l, o) { - const s = l.path, c = o.start.path, g = o.end.path, b = []; - return mn(s, c) && b.push({ offset: c[c.length - 1], isEnd: !1, presentation: o.presentation || null, type: o.type, name: o.name || null }), mn(s, g) && b.push({ offset: g[g.length - 1], isEnd: !0, presentation: o.presentation || null, type: o.type, name: o.name || null }), b; + function bi(l, o) { + const s = l.path, c = o.start.path, g = o.end.path, y = []; + return mn(s, c) && y.push({ offset: c[c.length - 1], isEnd: !1, presentation: o.presentation || null, type: o.type, name: o.name || null }), mn(s, g) && y.push({ offset: g[g.length - 1], isEnd: !0, presentation: o.presentation || null, type: o.type, name: o.name || null }), y; } function mn(l, o) { return l.length === o.length - 1 && Kr(l, o) === "prefix"; @@ -9133,34 +9207,34 @@ ${k}`); } const Dr = "active-model-tab-name", Kn = "model-show-markers", cr = "model-compact-text"; function Qn(l, o, s) { - const c = (function(g, b, x) { - if (g.ui.activeTab !== "Model") return b; - if (!b) return Rn(g, b); + const c = (function(g, y, x) { + if (g.ui.activeTab !== "Model") return y; + if (!y) return Rn(g, y); switch (x.type) { case Qe: return (function(z, K, Y) { const ie = Y.currentRootName; return { ...K, ...Ir(z, K, { currentRootName: ie }), currentNode: null, currentNodeDefinition: null, currentRootName: ie }; - })(g, b, x); + })(g, y, x); case et: - return { ...b, currentNode: x.currentNode, currentNodeDefinition: lr(gn(g), x.currentNode) }; + return { ...y, currentNode: x.currentNode, currentNodeDefinition: lr(gn(g), x.currentNode) }; case Ht: case Gt: - return { ...b, ...Ir(g, b) }; + return { ...y, ...Ir(g, y) }; case an: case pn: - return Rn(g, b); + return Rn(g, y); default: - return b; + return y; } })(l, o, s); - return c && (c.ui = (function(g, b) { + return c && (c.ui = (function(g, y) { if (!g) return { activeTab: ct.get(Dr) || "Inspect", showMarkers: ct.get(Kn) === "true", showCompactText: ct.get(cr) === "true" }; - switch (b.type) { + switch (y.type) { case Pt: return (function(x, z) { return ct.set(Dr, z.tabName), { ...x, activeTab: z.tabName }; - })(g, b); + })(g, y); case ko: return (function(x) { const z = !x.showMarkers; @@ -9183,27 +9257,27 @@ ${k}`); return { ...o, ...Ir(l, o, { currentRootName: c }), currentRootName: c, currentNode: null, currentNodeDefinition: null }; } function Ir(l, o, s) { - const c = gn(l), g = { ...o, ...s }, b = g.currentRootName, x = (function(ue, he) { + const c = gn(l), g = { ...o, ...s }, y = g.currentRootName, x = (function(ue, he) { if (!ue) return []; const de = [], Oe = ue.model; for (const Ce of Oe.document.selection.getRanges()) Ce.root.rootName === he && de.push({ type: "selection", start: zt(Ce.start), end: zt(Ce.end) }); return de; - })(c, b), z = (function(ue, he) { + })(c, y), z = (function(ue, he) { if (!ue) return []; const de = [], Oe = ue.model; let Ce = 0; for (const ze of Oe.markers) { - const { name: st, affectsData: $e, managedUsingOperations: je } = ze, dt = ze.getStart(), vt = ze.getEnd(); - dt.root.rootName === he && de.push({ type: "marker", marker: ze, name: st, affectsData: $e, managedUsingOperations: je, presentation: { color: Dn[Ce++ % (Dn.length - 1)] }, start: zt(dt), end: zt(vt) }); + const { name: st, affectsData: Be, managedUsingOperations: je } = ze, dt = ze.getStart(), vt = ze.getEnd(); + dt.root.rootName === he && de.push({ type: "marker", marker: ze, name: st, affectsData: Be, managedUsingOperations: je, presentation: { color: Dn[Ce++ % (Dn.length - 1)] }, start: zt(dt), end: zt(vt) }); } return de; - })(c, b), K = (function({ currentEditor: ue, currentRootName: he, ranges: de, markers: Oe }) { + })(c, y), K = (function({ currentEditor: ue, currentRootName: he, ranges: de, markers: Oe }) { return ue ? [In(ue.model.document.getRoot(he), [...de, ...Oe])] : []; })({ currentEditor: c, currentRootName: g.currentRootName, ranges: x, markers: z }); let Y = g.currentNode, ie = g.currentNodeDefinition; - return Y ? Y.root.rootName !== b || !Wn(Y) && !Y.parent ? (Y = null, ie = null) : ie = lr(c, Y) : ie = null, { treeDefinition: K, currentNode: Y, currentNodeDefinition: ie, ranges: x, markers: z }; + return Y ? Y.root.rootName !== y || !Wn(Y) && !Y.parent ? (Y = null, ie = null) : ie = lr(c, Y) : ie = null, { treeDefinition: K, currentNode: Y, currentNodeDefinition: ie, ranges: x, markers: z }; } - const Rr = "SET_VIEW_CURRENT_ROOT_NAME", M = "SET_VIEW_CURRENT_NODE", Q = "SET_VIEW_ACTIVE_TAB", ye = "TOGGLE_VIEW_SHOW_ELEMENT_TYPES", De = "UPDATE_VIEW_STATE"; + const Rr = "SET_VIEW_CURRENT_ROOT_NAME", M = "SET_VIEW_CURRENT_NODE", Q = "SET_VIEW_ACTIVE_TAB", be = "TOGGLE_VIEW_SHOW_ELEMENT_TYPES", De = "UPDATE_VIEW_STATE"; function tt(l) { return { type: Q, tabName: l }; } @@ -9229,33 +9303,33 @@ ${k}`); return l && l.is("rootElement"); } function jt(l) { - return { path: [...l.parent.getPath(), l.offset], offset: l.offset, isAtEnd: l.isAtEnd, isAtStart: l.isAtStart, parent: bt(l.parent) }; + return { path: [...l.parent.getPath(), l.offset], offset: l.offset, isAtEnd: l.isAtEnd, isAtStart: l.isAtStart, parent: yt(l.parent) }; } - function bt(l) { + function yt(l) { return Ge(l) ? rt(l) ? "attribute:" + l.name : kt(l) ? "root:" + l.name : "container:" + l.name : l.data; } - const yt = "https://ckeditor.com/docs/ckeditor5/latest/api/module_engine_view", bn = `<!--The View UI element content has been skipped. Find out why. -->`, ur = `<!--The View raw element content has been skipped. Find out why. -->`; + const bt = "https://ckeditor.com/docs/ckeditor5/latest/api/module_engine_view", yn = `<!--The View UI element content has been skipped. Find out why. -->`, ur = `<!--The View raw element content has been skipped. Find out why. -->`; function Mn(l) { return l ? [...l.editing.view.document.roots] : []; } - function yn(l) { + function bn(l) { const o = { editorNode: l, properties: {}, attributes: {}, customProperties: {} }; if (Ge(l)) { - kt(l) ? (o.type = "RootEditableElement", o.name = l.rootName, o.url = `${yt}_rooteditableelement-RootEditableElement.html`) : (o.name = l.name, rt(l) ? (o.type = "AttributeElement", o.url = `${yt}_attributeelement-AttributeElement.html`) : At(l) ? (o.type = "EmptyElement", o.url = `${yt}_emptyelement-EmptyElement.html`) : ft(l) ? (o.type = "UIElement", o.url = `${yt}_uielement-UIElement.html`) : ht(l) ? (o.type = "RawElement", o.url = `${yt}_rawelement-RawElement.html`) : (function(s) { + kt(l) ? (o.type = "RootEditableElement", o.name = l.rootName, o.url = `${bt}_rooteditableelement-RootEditableElement.html`) : (o.name = l.name, rt(l) ? (o.type = "AttributeElement", o.url = `${bt}_attributeelement-AttributeElement.html`) : At(l) ? (o.type = "EmptyElement", o.url = `${bt}_emptyelement-EmptyElement.html`) : ft(l) ? (o.type = "UIElement", o.url = `${bt}_uielement-UIElement.html`) : ht(l) ? (o.type = "RawElement", o.url = `${bt}_rawelement-RawElement.html`) : (function(s) { return s && Ge(s) && s.is("editableElement"); - })(l) ? (o.type = "EditableElement", o.url = `${yt}_editableelement-EditableElement.html`) : (o.type = "ContainerElement", o.url = `${yt}_containerelement-ContainerElement.html`)), nt(l).forEach(([s, c]) => { + })(l) ? (o.type = "EditableElement", o.url = `${bt}_editableelement-EditableElement.html`) : (o.type = "ContainerElement", o.url = `${bt}_containerelement-ContainerElement.html`)), nt(l).forEach(([s, c]) => { o.attributes[s] = { value: c }; }), o.properties = { index: { value: l.index }, isEmpty: { value: l.isEmpty }, childCount: { value: l.childCount } }; for (let [s, c] of l.getCustomProperties()) typeof s == "symbol" && (s = s.toString()), o.customProperties[s] = { value: c }; - } else o.name = l.data, o.type = "Text", o.url = `${yt}_text-Text.html`, o.properties = { index: { value: l.index } }; + } else o.name = l.data, o.type = "Text", o.url = `${bt}_text-Text.html`, o.properties = { index: { value: l.index } }; return o.properties = pt(o.properties), o.customProperties = pt(o.customProperties), o.attributes = pt(o.attributes), o; } function Xr(l, o) { const s = {}; return Object.assign(s, { index: l.index, path: l.getPath(), node: l, positionsBefore: [], positionsAfter: [] }), Ge(l) ? (function(c, g) { - const b = c.node; - Object.assign(c, { type: "element", children: [], positions: [] }), c.name = b.name, rt(b) ? c.elementType = "attribute" : kt(b) ? c.elementType = "root" : At(b) ? c.elementType = "empty" : ft(b) ? c.elementType = "ui" : ht(b) ? c.elementType = "raw" : c.elementType = "container", At(b) ? c.presentation = { isEmpty: !0 } : ft(b) ? c.children.push({ type: "comment", text: bn }) : ht(b) && c.children.push({ type: "comment", text: ur }); - for (const x of b.getChildren()) c.children.push(Xr(x, g)); + const y = c.node; + Object.assign(c, { type: "element", children: [], positions: [] }), c.name = y.name, rt(y) ? c.elementType = "attribute" : kt(y) ? c.elementType = "root" : At(y) ? c.elementType = "empty" : ft(y) ? c.elementType = "ui" : ht(y) ? c.elementType = "raw" : c.elementType = "container", At(y) ? c.presentation = { isEmpty: !0 } : ft(y) ? c.children.push({ type: "comment", text: yn }) : ht(y) && c.children.push({ type: "comment", text: ur }); + for (const x of y.getChildren()) c.children.push(Xr(x, g)); (function(x, z) { for (const K of z) { const Y = To(x, K); @@ -9286,18 +9360,18 @@ ${k}`); })(c, g), c.attributes = (function(x) { const z = nt(x).map(([K, Y]) => [K, fn(Y, !1)]); return new Map(z); - })(b); + })(y); })(s, o) : (function(c, g) { Object.assign(c, { type: "text", startOffset: 0, text: c.node.data, positions: [] }); - for (const b of g) { - const x = To(c, b); + for (const y of g) { + const x = To(c, y); c.positions.push(...x); } })(s, o), s; } function To(l, o) { - const s = l.path, c = o.start.path, g = o.end.path, b = []; - return Oo(s, c) && b.push({ offset: c[c.length - 1], isEnd: !1, presentation: o.presentation || null, type: o.type, name: o.name || null }), Oo(s, g) && b.push({ offset: g[g.length - 1], isEnd: !0, presentation: o.presentation || null, type: o.type, name: o.name || null }), b; + const s = l.path, c = o.start.path, g = o.end.path, y = []; + return Oo(s, c) && y.push({ offset: c[c.length - 1], isEnd: !1, presentation: o.presentation || null, type: o.type, name: o.name || null }), Oo(s, g) && y.push({ offset: g[g.length - 1], isEnd: !0, presentation: o.presentation || null, type: o.type, name: o.name || null }), y; } function Oo(l, o) { return l.length === o.length - 1 && Kr(l, o) === "prefix"; @@ -9307,41 +9381,41 @@ ${k}`); } const Ze = "active-view-tab-name", Yn = "view-element-types"; function vn(l, o, s) { - const c = (function(g, b, x) { - if (g.ui.activeTab !== "View") return b; - if (!b) return dr(g, b); + const c = (function(g, y, x) { + if (g.ui.activeTab !== "View") return y; + if (!y) return dr(g, y); switch (x.type) { case Rr: return (function(z, K, Y) { const ie = Y.currentRootName; return { ...K, ...ut(z, K, { currentRootName: ie }), currentNode: null, currentNodeDefinition: null, currentRootName: ie }; - })(g, b, x); + })(g, y, x); case M: - return { ...b, currentNode: x.currentNode, currentNodeDefinition: yn(x.currentNode) }; + return { ...y, currentNode: x.currentNode, currentNodeDefinition: bn(x.currentNode) }; case Ht: case De: - return { ...b, ...ut(g, b) }; + return { ...y, ...ut(g, y) }; case an: case pn: - return dr(g, b); + return dr(g, y); default: - return b; + return y; } })(l, o, s); - return c && (c.ui = (function(g, b, x) { - if (!b) return { activeTab: ct.get(Ze) || "Inspect", showElementTypes: ct.get(Yn) === "true" }; + return c && (c.ui = (function(g, y, x) { + if (!y) return { activeTab: ct.get(Ze) || "Inspect", showElementTypes: ct.get(Yn) === "true" }; switch (x.type) { case Q: return (function(z, K) { return ct.set(Ze, K.tabName), { ...z, activeTab: K.tabName }; - })(b, x); - case ye: + })(y, x); + case be: return (function(z, K) { const Y = !K.showElementTypes; return ct.set(Yn, Y), { ...K, showElementTypes: Y }; - })(0, b); + })(0, y); default: - return b; + return y; } })(0, c.ui, s)), c; } @@ -9350,16 +9424,16 @@ ${k}`); return { ...o, ...ut(l, o, { currentRootName: c }), currentRootName: c, currentNode: null, currentNodeDefinition: null }; } function ut(l, o, s) { - const c = { ...o, ...s }, g = c.currentRootName, b = (function(Y, ie) { + const c = { ...o, ...s }, g = c.currentRootName, y = (function(Y, ie) { if (!Y) return []; const ue = [], he = Y.editing.view.document.selection; for (const de of he.getRanges()) de.root.rootName === ie && ue.push({ type: "selection", start: jt(de.start), end: jt(de.end) }); return ue; })(gn(l), g), x = (function({ currentEditor: Y, currentRootName: ie, ranges: ue }) { return Y && ie ? [Xr(Y.editing.view.document.getRoot(ie), [...ue])] : null; - })({ currentEditor: gn(l), currentRootName: g, ranges: b }); + })({ currentEditor: gn(l), currentRootName: g, ranges: y }); let z = c.currentNode, K = c.currentNodeDefinition; - return z ? z.root.rootName !== g || !kt(z) && !z.parent ? (z = null, K = null) : K = yn(z) : K = null, { treeDefinition: x, currentNode: z, currentNodeDefinition: K, ranges: b }; + return z ? z.root.rootName !== g || !kt(z) && !z.parent ? (z = null, K = null) : K = bn(z) : K = null, { treeDefinition: x, currentNode: z, currentNodeDefinition: K, ranges: y }; } const wt = "SET_COMMANDS_CURRENT_COMMAND_NAME", Tt = "UPDATE_COMMANDS_STATE"; function Lt() { @@ -9374,8 +9448,8 @@ ${k}`); if (!l.get(o)) return []; const s = []; for (const [c, g] of l.get(o).commands) { - const b = []; - g.value !== void 0 && b.push(["value", fn(g.value, !1)]), s.push({ name: c, type: "element", children: [], node: c, attributes: b, presentation: { isEmpty: !0, cssClass: ["ck-inspector-tree-node_tagless", g.isEnabled ? "" : "ck-inspector-tree-node_disabled"].join(" ") } }); + const y = []; + g.value !== void 0 && y.push(["value", fn(g.value, !1)]), s.push({ name: c, type: "element", children: [], node: c, attributes: y, presentation: { isEmpty: !0, cssClass: ["ck-inspector-tree-node_tagless", g.isEnabled ? "" : "ck-inspector-tree-node_disabled"].join(" ") } }); } return s.sort((c, g) => c.name > g.name ? 1 : -1); } @@ -9389,9 +9463,9 @@ ${k}`); const pr = ["isBlock", "isInline", "isObject", "isContent", "isLimit", "isSelectable"], Xn = "https://ckeditor.com/docs/ckeditor5/latest/api/"; function _n({ editors: l, currentEditorName: o }, s) { if (!s) return null; - const c = l.get(o).model.schema, g = c.getDefinitions()[s], b = {}, x = {}, z = {}; + const c = l.get(o).model.schema, g = c.getDefinitions()[s], y = {}, x = {}, z = {}; let K = {}; - for (const Y of pr) g[Y] && (b[Y] = { value: g[Y] }); + for (const Y of pr) g[Y] && (y[Y] = { value: g[Y] }); for (const Y of g.allowChildren.sort()) x[Y] = { value: !0, title: `Click to see the definition of ${Y}` }; for (const Y of g.allowIn.sort()) z[Y] = { value: !0, title: `Click to see the definition of ${Y}` }; for (const Y of g.allowAttributes.sort()) K[Y] = { value: !0 }; @@ -9401,13 +9475,13 @@ ${k}`); for (const he in ie) ue[he] = { value: ie[he] }; K[Y].subProperties = pt(ue); } - return { currentSchemaDefinitionName: s, type: "SchemaCompiledItemDefinition", urls: { general: Xn + "module_engine_model_schema-SchemaCompiledItemDefinition.html", allowAttributes: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowAttributes", allowChildren: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowChildren", allowIn: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowIn" }, properties: pt(b), allowChildren: pt(x), allowIn: pt(z), allowAttributes: K, definition: g }; + return { currentSchemaDefinitionName: s, type: "SchemaCompiledItemDefinition", urls: { general: Xn + "module_engine_model_schema-SchemaCompiledItemDefinition.html", allowAttributes: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowAttributes", allowChildren: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowChildren", allowIn: Xn + "module_engine_model_schema-SchemaItemDefinition.html#member-allowIn" }, properties: pt(y), allowChildren: pt(x), allowIn: pt(z), allowAttributes: K, definition: g }; } function Mr({ editors: l, currentEditorName: o }) { if (!l.get(o)) return []; const s = [], c = l.get(o).model.schema.getDefinitions(); for (const g in c) s.push({ name: g, type: "element", children: [], node: g, attributes: [], presentation: { isEmpty: !0, cssClass: "ck-inspector-tree-node_tagless" } }); - return s.sort((g, b) => g.name > b.name ? 1 : -1); + return s.sort((g, y) => g.name > y.name ? 1 : -1); } function fr(l, o = {}) { return { ...o, currentSchemaDefinitionName: null, currentSchemaDefinition: null, treeDefinition: Mr(l) }; @@ -9417,20 +9491,20 @@ ${k}`); const s = (function(c, g) { switch (g.type) { case an: - return (function(b, x) { + return (function(y, x) { const z = { editors: new Map(x.editors) }; - return x.editors.size ? x.editors.has(b.currentEditorName) || (z.currentEditorName = sn(x.editors)) : z.currentEditorName = null, { ...b, ...z }; + return x.editors.size ? x.editors.has(y.currentEditorName) || (z.currentEditorName = sn(x.editors)) : z.currentEditorName = null, { ...y, ...z }; })(c, g); case pn: - return (function(b, x) { - return { ...b, currentEditorName: x.editorName }; + return (function(y, x) { + return { ...y, currentEditorName: x.editorName }; })(c, g); default: return c; } })(l, o); - return s.currentEditorGlobals = (function(c, g, b) { - switch (b.type) { + return s.currentEditorGlobals = (function(c, g, y) { + switch (y.type) { case an: case pn: return { ...ki(c, {}) }; @@ -9441,36 +9515,36 @@ ${k}`); } })(s, s.currentEditorGlobals, o), s.ui = (function(c, g) { if (!c.activeTab) { - let b; - return b = c.isCollapsed !== void 0 ? c.isCollapsed : ct.get(zr) === "true", { ...c, isCollapsed: b, activeTab: ct.get(hr) || "Model", height: ct.get(Zr) || "400px", sidePaneWidth: ct.get(vi) || "500px" }; + let y; + return y = c.isCollapsed !== void 0 ? c.isCollapsed : ct.get(zr) === "true", { ...c, isCollapsed: y, activeTab: ct.get(hr) || "Model", height: ct.get(Zr) || "400px", sidePaneWidth: ct.get(vi) || "500px" }; } switch (g.type) { case wo: - return (function(b) { - const x = !b.isCollapsed; - return ct.set(zr, x), { ...b, isCollapsed: x }; + return (function(y) { + const x = !y.isCollapsed; + return ct.set(zr, x), { ...y, isCollapsed: x }; })(c); - case Bn: - return (function(b, x) { - return ct.set(Zr, x.newHeight), { ...b, height: x.newHeight }; - })(c, g); case $n: - return (function(b, x) { - return ct.set(vi, x.newWidth), { ...b, sidePaneWidth: x.newWidth }; + return (function(y, x) { + return ct.set(Zr, x.newHeight), { ...y, height: x.newHeight }; + })(c, g); + case Bn: + return (function(y, x) { + return ct.set(vi, x.newWidth), { ...y, sidePaneWidth: x.newWidth }; })(c, g); case Ht: - return (function(b, x) { - return ct.set(hr, x.tabName), { ...b, activeTab: x.tabName }; + return (function(y, x) { + return ct.set(hr, x.tabName), { ...y, activeTab: x.tabName }; })(c, g); default: return c; } - })(s.ui, o), s.model = Qn(s, s.model, o), s.view = vn(s, s.view, o), s.commands = (function(c, g, b) { + })(s.ui, o), s.model = Qn(s, s.model, o), s.view = vn(s, s.view, o), s.commands = (function(c, g, y) { if (c.ui.activeTab !== "Commands") return g; if (!g) return wn(c, g); - switch (b.type) { + switch (y.type) { case wt: - return { ...g, currentCommandDefinition: kn(c, b.currentCommandName), currentCommandName: b.currentCommandName }; + return { ...g, currentCommandDefinition: kn(c, y.currentCommandName), currentCommandName: y.currentCommandName }; case Ht: case Tt: return { ...g, currentCommandDefinition: kn(c, g.currentCommandName), treeDefinition: zn(c) }; @@ -9480,12 +9554,12 @@ ${k}`); default: return g; } - })(s, s.commands, o), s.schema = (function(c, g, b) { + })(s, s.commands, o), s.schema = (function(c, g, y) { if (c.ui.activeTab !== "Schema") return g; if (!g) return fr(c, g); - switch (b.type) { + switch (y.type) { case ln: - return { ...g, currentSchemaDefinition: _n(c, b.currentSchemaDefinitionName), currentSchemaDefinitionName: b.currentSchemaDefinitionName }; + return { ...g, currentSchemaDefinition: _n(c, y.currentSchemaDefinitionName), currentSchemaDefinitionName: y.currentSchemaDefinitionName }; case Ht: return { ...g, currentSchemaDefinition: _n(c, g.currentSchemaDefinitionName), treeDefinition: Mr(c) }; case an: @@ -9505,7 +9579,7 @@ ${k}`); return l = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(c, g) { c.__proto__ = g; } || function(c, g) { - for (var b in g) g.hasOwnProperty(b) && (c[b] = g[b]); + for (var y in g) g.hasOwnProperty(y) && (c[y] = g[y]); }, l(o, s); }; return function(o, s) { @@ -9536,7 +9610,7 @@ ${k}`); return l = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(c, g) { c.__proto__ = g; } || function(c, g) { - for (var b in g) g.hasOwnProperty(b) && (c[b] = g[b]); + for (var y in g) g.hasOwnProperty(y) && (c[y] = g[y]); }, l(o, s); }; return function(o, s) { @@ -9560,8 +9634,8 @@ ${k}`); return !!(l.touches && l.touches.length); }, ia = An()(function(l, o, s) { s === void 0 && (s = 0); - var c = o.reduce(function(b, x, z) { - return Math.abs(x - l) < Math.abs(o[b] - l) ? z : b; + var c = o.reduce(function(y, x, z) { + return Math.abs(x - l) < Math.abs(o[y] - l) ? z : y; }, 0), g = Math.abs(o[c] - l); return s === 0 || g < s ? o[c] : l; }), _t = An()(function(l, o) { @@ -9576,8 +9650,8 @@ ${k}`); if (_t(l, "vh")) return c * (Number(l.replace("vh", "")) / 100); } return l; - }, xi = An()(function(l, o, s, c, g, b, x) { - return c = ti(c, l.width, o, s), g = ti(g, l.height, o, s), b = ti(b, l.width, o, s), x = ti(x, l.height, o, s), { maxWidth: c === void 0 ? void 0 : Number(c), maxHeight: g === void 0 ? void 0 : Number(g), minWidth: b === void 0 ? void 0 : Number(b), minHeight: x === void 0 ? void 0 : Number(x) }; + }, xi = An()(function(l, o, s, c, g, y, x) { + return c = ti(c, l.width, o, s), g = ti(g, l.height, o, s), y = ti(y, l.width, o, s), x = ti(x, l.height, o, s), { maxWidth: c === void 0 ? void 0 : Number(c), maxHeight: g === void 0 ? void 0 : Number(g), minWidth: y === void 0 ? void 0 : Number(y), minHeight: x === void 0 ? void 0 : Number(x) }; }), Si = ["as", "style", "className", "grid", "snap", "bounds", "boundsByDirection", "size", "defaultSize", "minWidth", "minHeight", "maxWidth", "maxHeight", "lockAspectRatio", "lockAspectRatioExtraWidth", "lockAspectRatioExtraHeight", "enable", "handleStyles", "handleClasses", "handleWrapperStyle", "handleWrapperClass", "children", "onResizeStart", "onResize", "onResizeStop", "handleComponent", "scale", "resizeRatio", "snapGap"], Ci = "__resizable_base__", Gn = (function(l) { function o(s) { var c = l.call(this, s) || this; @@ -9585,11 +9659,11 @@ ${k}`); if (!c.resizable || !c.window) return null; var g = c.parentNode; if (!g) return null; - var b = c.window.document.createElement("div"); - return b.style.width = "100%", b.style.height = "100%", b.style.position = "absolute", b.style.transform = "scale(0, 0)", b.style.left = "0", b.style.flex = "0", b.classList ? b.classList.add(Ci) : b.className += Ci, g.appendChild(b), b; + var y = c.window.document.createElement("div"); + return y.style.width = "100%", y.style.height = "100%", y.style.position = "absolute", y.style.transform = "scale(0, 0)", y.style.left = "0", y.style.flex = "0", y.classList ? y.classList.add(Ci) : y.className += Ci, g.appendChild(y), y; }, c.removeBase = function(g) { - var b = c.parentNode; - b && b.removeChild(g); + var y = c.parentNode; + y && y.removeChild(g); }, c.ref = function(g) { g && (c.resizable = g); }, c.state = { isResizing: !1, width: (c.propsSize && c.propsSize.width) === void 0 ? "auto" : c.propsSize && c.propsSize.width, height: (c.propsSize && c.propsSize.height) === void 0 ? "auto" : c.propsSize && c.propsSize.height, direction: "right", original: { x: 0, y: 0, width: 0, height: 0 }, backgroundStyle: { height: "100%", width: "100%", backgroundColor: "rgba(0,0,0,0)", cursor: "auto", opacity: 0, position: "fixed", zIndex: 9999, top: "0", left: "0", bottom: "0", right: "0" }, flexBasis: void 0 }, c.onResizeStart = c.onResizeStart.bind(c), c.onMouseMove = c.onMouseMove.bind(c), c.onMouseUp = c.onMouseUp.bind(c), c; @@ -9603,19 +9677,19 @@ ${k}`); }, enumerable: !1, configurable: !0 }), Object.defineProperty(o.prototype, "size", { get: function() { var s = 0, c = 0; if (this.resizable && this.window) { - var g = this.resizable.offsetWidth, b = this.resizable.offsetHeight, x = this.resizable.style.position; - x !== "relative" && (this.resizable.style.position = "relative"), s = this.resizable.style.width !== "auto" ? this.resizable.offsetWidth : g, c = this.resizable.style.height !== "auto" ? this.resizable.offsetHeight : b, this.resizable.style.position = x; + var g = this.resizable.offsetWidth, y = this.resizable.offsetHeight, x = this.resizable.style.position; + x !== "relative" && (this.resizable.style.position = "relative"), s = this.resizable.style.width !== "auto" ? this.resizable.offsetWidth : g, c = this.resizable.style.height !== "auto" ? this.resizable.offsetHeight : y, this.resizable.style.position = x; } return { width: s, height: c }; }, enumerable: !1, configurable: !0 }), Object.defineProperty(o.prototype, "sizeStyle", { get: function() { - var s = this, c = this.props.size, g = function(b) { - if (s.state[b] === void 0 || s.state[b] === "auto") return "auto"; - if (s.propsSize && s.propsSize[b] && _t(s.propsSize[b].toString(), "%")) { - if (_t(s.state[b].toString(), "%")) return s.state[b].toString(); + var s = this, c = this.props.size, g = function(y) { + if (s.state[y] === void 0 || s.state[y] === "auto") return "auto"; + if (s.propsSize && s.propsSize[y] && _t(s.propsSize[y].toString(), "%")) { + if (_t(s.state[y].toString(), "%")) return s.state[y].toString(); var x = s.getParentSize(); - return Number(s.state[b].toString().replace("px", "")) / x[b] * 100 + "%"; + return Number(s.state[y].toString().replace("px", "")) / x[y] * 100 + "%"; } - return ei(s.state[b]); + return ei(s.state[y]); }; return { width: c && c.width !== void 0 && !this.state.isResizing ? ei(c.width) : g("width"), height: c && c.height !== void 0 && !this.state.isResizing ? ei(c.height) : g("height") }; }, enumerable: !1, configurable: !0 }), o.prototype.getParentSize = function() { @@ -9624,8 +9698,8 @@ ${k}`); if (!s) return { width: 0, height: 0 }; var c = !1, g = this.parentNode.style.flexWrap; g !== "wrap" && (c = !0, this.parentNode.style.flexWrap = "wrap"), s.style.position = "relative", s.style.minWidth = "100%"; - var b = { width: s.offsetWidth, height: s.offsetHeight }; - return c && (this.parentNode.style.flexWrap = g), this.removeBase(s), b; + var y = { width: s.offsetWidth, height: s.offsetHeight }; + return c && (this.parentNode.style.flexWrap = g), this.removeBase(s), y; }, o.prototype.bindEvents = function() { this.window && (this.window.addEventListener("mouseup", this.onMouseUp), this.window.addEventListener("mousemove", this.onMouseMove), this.window.addEventListener("mouseleave", this.onMouseUp), this.window.addEventListener("touchmove", this.onMouseMove, { capture: !0, passive: !1 }), this.window.addEventListener("touchend", this.onMouseUp)); }, o.prototype.unbindEvents = function() { @@ -9641,20 +9715,20 @@ ${k}`); var g = this.propsSize && this.propsSize[c]; return this.state[c] !== "auto" || this.state.original[c] !== s || g !== void 0 && g !== "auto" ? s : "auto"; }, o.prototype.calculateNewMaxFromBoundary = function(s, c) { - var g, b, x = this.props.boundsByDirection, z = this.state.direction, K = x && mr("left", z), Y = x && mr("top", z); + var g, y, x = this.props.boundsByDirection, z = this.state.direction, K = x && mr("left", z), Y = x && mr("top", z); if (this.props.bounds === "parent") { var ie = this.parentNode; - ie && (g = K ? this.resizableRight - this.parentLeft : ie.offsetWidth + (this.parentLeft - this.resizableLeft), b = Y ? this.resizableBottom - this.parentTop : ie.offsetHeight + (this.parentTop - this.resizableTop)); - } else this.props.bounds === "window" ? this.window && (g = K ? this.resizableRight : this.window.innerWidth - this.resizableLeft, b = Y ? this.resizableBottom : this.window.innerHeight - this.resizableTop) : this.props.bounds && (g = K ? this.resizableRight - this.targetLeft : this.props.bounds.offsetWidth + (this.targetLeft - this.resizableLeft), b = Y ? this.resizableBottom - this.targetTop : this.props.bounds.offsetHeight + (this.targetTop - this.resizableTop)); - return g && Number.isFinite(g) && (s = s && s < g ? s : g), b && Number.isFinite(b) && (c = c && c < b ? c : b), { maxWidth: s, maxHeight: c }; + ie && (g = K ? this.resizableRight - this.parentLeft : ie.offsetWidth + (this.parentLeft - this.resizableLeft), y = Y ? this.resizableBottom - this.parentTop : ie.offsetHeight + (this.parentTop - this.resizableTop)); + } else this.props.bounds === "window" ? this.window && (g = K ? this.resizableRight : this.window.innerWidth - this.resizableLeft, y = Y ? this.resizableBottom : this.window.innerHeight - this.resizableTop) : this.props.bounds && (g = K ? this.resizableRight - this.targetLeft : this.props.bounds.offsetWidth + (this.targetLeft - this.resizableLeft), y = Y ? this.resizableBottom - this.targetTop : this.props.bounds.offsetHeight + (this.targetTop - this.resizableTop)); + return g && Number.isFinite(g) && (s = s && s < g ? s : g), y && Number.isFinite(y) && (c = c && c < y ? c : y), { maxWidth: s, maxHeight: c }; }, o.prototype.calculateNewSizeFromDirection = function(s, c) { - var g = this.props.scale || 1, b = this.props.resizeRatio || 1, x = this.state, z = x.direction, K = x.original, Y = this.props, ie = Y.lockAspectRatio, ue = Y.lockAspectRatioExtraHeight, he = Y.lockAspectRatioExtraWidth, de = K.width, Oe = K.height, Ce = ue || 0, ze = he || 0; - return mr("right", z) && (de = K.width + (s - K.x) * b / g, ie && (Oe = (de - ze) / this.ratio + Ce)), mr("left", z) && (de = K.width - (s - K.x) * b / g, ie && (Oe = (de - ze) / this.ratio + Ce)), mr("bottom", z) && (Oe = K.height + (c - K.y) * b / g, ie && (de = (Oe - Ce) * this.ratio + ze)), mr("top", z) && (Oe = K.height - (c - K.y) * b / g, ie && (de = (Oe - Ce) * this.ratio + ze)), { newWidth: de, newHeight: Oe }; - }, o.prototype.calculateNewSizeFromAspectRatio = function(s, c, g, b) { - var x = this.props, z = x.lockAspectRatio, K = x.lockAspectRatioExtraHeight, Y = x.lockAspectRatioExtraWidth, ie = b.width === void 0 ? 10 : b.width, ue = g.width === void 0 || g.width < 0 ? s : g.width, he = b.height === void 0 ? 10 : b.height, de = g.height === void 0 || g.height < 0 ? c : g.height, Oe = K || 0, Ce = Y || 0; + var g = this.props.scale || 1, y = this.props.resizeRatio || 1, x = this.state, z = x.direction, K = x.original, Y = this.props, ie = Y.lockAspectRatio, ue = Y.lockAspectRatioExtraHeight, he = Y.lockAspectRatioExtraWidth, de = K.width, Oe = K.height, Ce = ue || 0, ze = he || 0; + return mr("right", z) && (de = K.width + (s - K.x) * y / g, ie && (Oe = (de - ze) / this.ratio + Ce)), mr("left", z) && (de = K.width - (s - K.x) * y / g, ie && (Oe = (de - ze) / this.ratio + Ce)), mr("bottom", z) && (Oe = K.height + (c - K.y) * y / g, ie && (de = (Oe - Ce) * this.ratio + ze)), mr("top", z) && (Oe = K.height - (c - K.y) * y / g, ie && (de = (Oe - Ce) * this.ratio + ze)), { newWidth: de, newHeight: Oe }; + }, o.prototype.calculateNewSizeFromAspectRatio = function(s, c, g, y) { + var x = this.props, z = x.lockAspectRatio, K = x.lockAspectRatioExtraHeight, Y = x.lockAspectRatioExtraWidth, ie = y.width === void 0 ? 10 : y.width, ue = g.width === void 0 || g.width < 0 ? s : g.width, he = y.height === void 0 ? 10 : y.height, de = g.height === void 0 || g.height < 0 ? c : g.height, Oe = K || 0, Ce = Y || 0; if (z) { - var ze = (he - Oe) * this.ratio + Ce, st = (de - Oe) * this.ratio + Ce, $e = (ie - Ce) / this.ratio + Oe, je = (ue - Ce) / this.ratio + Oe, dt = Math.max(ie, ze), vt = Math.min(ue, st), $t = Math.max(he, $e), xt = Math.min(de, je); - s = Jo(s, dt, vt), c = Jo(c, $t, xt); + var ze = (he - Oe) * this.ratio + Ce, st = (de - Oe) * this.ratio + Ce, Be = (ie - Ce) / this.ratio + Oe, je = (ue - Ce) / this.ratio + Oe, dt = Math.max(ie, ze), vt = Math.min(ue, st), Bt = Math.max(he, Be), xt = Math.min(de, je); + s = Jo(s, dt, vt), c = Jo(c, Bt, xt); } else s = Jo(s, ie, ue), c = Jo(c, he, de); return { newWidth: s, newHeight: c }; }, o.prototype.setBoundingClientRect = function() { @@ -9670,17 +9744,17 @@ ${k}`); this.targetLeft = g.left, this.targetTop = g.top; } if (this.resizable) { - var b = this.resizable.getBoundingClientRect(), x = b.left, z = b.top, K = b.right, Y = b.bottom; + var y = this.resizable.getBoundingClientRect(), x = y.left, z = y.top, K = y.right, Y = y.bottom; this.resizableLeft = x, this.resizableRight = K, this.resizableTop = z, this.resizableBottom = Y; } }, o.prototype.onResizeStart = function(s, c) { if (this.resizable && this.window) { - var g, b = 0, x = 0; + var g, y = 0, x = 0; if (s.nativeEvent && (function(ue) { return !!((ue.clientX || ue.clientX === 0) && (ue.clientY || ue.clientY === 0)); })(s.nativeEvent)) { - if (b = s.nativeEvent.clientX, x = s.nativeEvent.clientY, s.nativeEvent.which === 3) return; - } else s.nativeEvent && gr(s.nativeEvent) && (b = s.nativeEvent.touches[0].clientX, x = s.nativeEvent.touches[0].clientY); + if (y = s.nativeEvent.clientX, x = s.nativeEvent.clientY, s.nativeEvent.which === 3) return; + } else s.nativeEvent && gr(s.nativeEvent) && (y = s.nativeEvent.touches[0].clientX, x = s.nativeEvent.touches[0].clientY); if (this.props.onResizeStart && this.resizable && this.props.onResizeStart(s, c, this.resizable) === !1) return; this.props.size && (this.props.size.height !== void 0 && this.props.size.height !== this.state.height && this.setState({ height: this.props.size.height }), this.props.size.width !== void 0 && this.props.size.width !== this.state.width && this.setState({ width: this.props.size.width })), this.ratio = typeof this.props.lockAspectRatio == "number" ? this.props.lockAspectRatio : this.size.width / this.size.height; var z = this.window.getComputedStyle(this.resizable); @@ -9692,7 +9766,7 @@ ${k}`); } } this.setBoundingClientRect(), this.bindEvents(); - var ie = { original: { x: b, y: x, width: this.size.width, height: this.size.height }, isResizing: !0, backgroundStyle: Qt(Qt({}, this.state.backgroundStyle), { cursor: this.window.getComputedStyle(s.target).cursor || "auto" }), direction: c, flexBasis: g }; + var ie = { original: { x: y, y: x, width: this.size.width, height: this.size.height }, isResizing: !0, backgroundStyle: Qt(Qt({}, this.state.backgroundStyle), { cursor: this.window.getComputedStyle(s.target).cursor || "auto" }), direction: c, flexBasis: g }; this.setState(ie); } }, o.prototype.onMouseMove = function(s) { @@ -9701,32 +9775,32 @@ ${k}`); s.preventDefault(), s.stopPropagation(); } catch { } - var c = this.props, g = c.maxWidth, b = c.maxHeight, x = c.minWidth, z = c.minHeight, K = gr(s) ? s.touches[0].clientX : s.clientX, Y = gr(s) ? s.touches[0].clientY : s.clientY, ie = this.state, ue = ie.direction, he = ie.original, de = ie.width, Oe = ie.height, Ce = this.getParentSize(), ze = xi(Ce, this.window.innerWidth, this.window.innerHeight, g, b, x, z); - g = ze.maxWidth, b = ze.maxHeight, x = ze.minWidth, z = ze.minHeight; - var st = this.calculateNewSizeFromDirection(K, Y), $e = st.newHeight, je = st.newWidth, dt = this.calculateNewMaxFromBoundary(g, b), vt = this.calculateNewSizeFromAspectRatio(je, $e, { width: dt.maxWidth, height: dt.maxHeight }, { width: x, height: z }); - if (je = vt.newWidth, $e = vt.newHeight, this.props.grid) { - var $t = Po(je, this.props.grid[0]), xt = Po($e, this.props.grid[1]), It = this.props.snapGap || 0; - je = It === 0 || Math.abs($t - je) <= It ? $t : je, $e = It === 0 || Math.abs(xt - $e) <= It ? xt : $e; + var c = this.props, g = c.maxWidth, y = c.maxHeight, x = c.minWidth, z = c.minHeight, K = gr(s) ? s.touches[0].clientX : s.clientX, Y = gr(s) ? s.touches[0].clientY : s.clientY, ie = this.state, ue = ie.direction, he = ie.original, de = ie.width, Oe = ie.height, Ce = this.getParentSize(), ze = xi(Ce, this.window.innerWidth, this.window.innerHeight, g, y, x, z); + g = ze.maxWidth, y = ze.maxHeight, x = ze.minWidth, z = ze.minHeight; + var st = this.calculateNewSizeFromDirection(K, Y), Be = st.newHeight, je = st.newWidth, dt = this.calculateNewMaxFromBoundary(g, y), vt = this.calculateNewSizeFromAspectRatio(je, Be, { width: dt.maxWidth, height: dt.maxHeight }, { width: x, height: z }); + if (je = vt.newWidth, Be = vt.newHeight, this.props.grid) { + var Bt = Po(je, this.props.grid[0]), xt = Po(Be, this.props.grid[1]), It = this.props.snapGap || 0; + je = It === 0 || Math.abs(Bt - je) <= It ? Bt : je, Be = It === 0 || Math.abs(xt - Be) <= It ? xt : Be; } - this.props.snap && this.props.snap.x && (je = ia(je, this.props.snap.x, this.props.snapGap)), this.props.snap && this.props.snap.y && ($e = ia($e, this.props.snap.y, this.props.snapGap)); - var St = { width: je - he.width, height: $e - he.height }; - de && typeof de == "string" && (_t(de, "%") ? je = je / Ce.width * 100 + "%" : _t(de, "vw") ? je = je / this.window.innerWidth * 100 + "vw" : _t(de, "vh") && (je = je / this.window.innerHeight * 100 + "vh")), Oe && typeof Oe == "string" && (_t(Oe, "%") ? $e = $e / Ce.height * 100 + "%" : _t(Oe, "vw") ? $e = $e / this.window.innerWidth * 100 + "vw" : _t(Oe, "vh") && ($e = $e / this.window.innerHeight * 100 + "vh")); - var mt = { width: this.createSizeForCssProperty(je, "width"), height: this.createSizeForCssProperty($e, "height") }; + this.props.snap && this.props.snap.x && (je = ia(je, this.props.snap.x, this.props.snapGap)), this.props.snap && this.props.snap.y && (Be = ia(Be, this.props.snap.y, this.props.snapGap)); + var St = { width: je - he.width, height: Be - he.height }; + de && typeof de == "string" && (_t(de, "%") ? je = je / Ce.width * 100 + "%" : _t(de, "vw") ? je = je / this.window.innerWidth * 100 + "vw" : _t(de, "vh") && (je = je / this.window.innerHeight * 100 + "vh")), Oe && typeof Oe == "string" && (_t(Oe, "%") ? Be = Be / Ce.height * 100 + "%" : _t(Oe, "vw") ? Be = Be / this.window.innerWidth * 100 + "vw" : _t(Oe, "vh") && (Be = Be / this.window.innerHeight * 100 + "vh")); + var mt = { width: this.createSizeForCssProperty(je, "width"), height: this.createSizeForCssProperty(Be, "height") }; this.flexDir === "row" ? mt.flexBasis = mt.width : this.flexDir === "column" && (mt.flexBasis = mt.height), this.setState(mt), this.props.onResize && this.props.onResize(s, ue, this.resizable, St); } }, o.prototype.onMouseUp = function(s) { - var c = this.state, g = c.isResizing, b = c.direction, x = c.original; + var c = this.state, g = c.isResizing, y = c.direction, x = c.original; if (g && this.resizable) { var z = { width: this.size.width - x.width, height: this.size.height - x.height }; - this.props.onResizeStop && this.props.onResizeStop(s, b, this.resizable, z), this.props.size && this.setState(this.props.size), this.unbindEvents(), this.setState({ isResizing: !1, backgroundStyle: Qt(Qt({}, this.state.backgroundStyle), { cursor: "auto" }) }); + this.props.onResizeStop && this.props.onResizeStop(s, y, this.resizable, z), this.props.size && this.setState(this.props.size), this.unbindEvents(), this.setState({ isResizing: !1, backgroundStyle: Qt(Qt({}, this.state.backgroundStyle), { cursor: "auto" }) }); } }, o.prototype.updateSize = function(s) { this.setState({ width: s.width, height: s.height }); }, o.prototype.renderResizer = function() { - var s = this, c = this.props, g = c.enable, b = c.handleStyles, x = c.handleClasses, z = c.handleWrapperStyle, K = c.handleWrapperClass, Y = c.handleComponent; + var s = this, c = this.props, g = c.enable, y = c.handleStyles, x = c.handleClasses, z = c.handleWrapperStyle, K = c.handleWrapperClass, Y = c.handleComponent; if (!g) return null; var ie = Object.keys(g).map(function(ue) { - return g[ue] !== !1 ? i.createElement(as, { key: ue, direction: ue, onResizeStart: s.onResizeStart, replaceStyles: b && b[ue], className: x && x[ue] }, Y && Y[ue] ? Y[ue] : null) : null; + return g[ue] !== !1 ? i.createElement(as, { key: ue, direction: ue, onResizeStart: s.onResizeStart, replaceStyles: y && y[ue], className: x && x[ue] }, Y && Y[ue] ? Y[ue] : null) : null; }); return i.createElement("div", { className: K, style: z }, ie); }, o.prototype.render = function() { @@ -9734,8 +9808,8 @@ ${k}`); return Si.indexOf(z) !== -1 || (x[z] = s.props[z]), x; }, {}), g = Qt(Qt(Qt({ position: "relative", userSelect: this.state.isResizing ? "none" : "auto" }, this.props.style), this.sizeStyle), { maxWidth: this.props.maxWidth, maxHeight: this.props.maxHeight, minWidth: this.props.minWidth, minHeight: this.props.minHeight, boxSizing: "border-box", flexShrink: 0 }); this.state.flexBasis && (g.flexBasis = this.state.flexBasis); - var b = this.props.as || "div"; - return i.createElement(b, Qt({ ref: this.ref, style: g, className: this.props.className }, c), this.state.isResizing && i.createElement("div", { style: this.state.backgroundStyle }), this.props.children, this.renderResizer()); + var y = this.props.as || "div"; + return i.createElement(y, Qt({ ref: this.ref, style: g, className: this.props.className }, c), this.state.isResizing && i.createElement("div", { style: this.state.backgroundStyle }), this.props.children, this.renderResizer()); }, o.defaultProps = { as: "div", onResizeStart: function() { }, onResize: function() { }, onResizeStop: function() { @@ -9767,7 +9841,7 @@ ${k}`); Jr(s, c), s.prototype = c === null ? Object.create(c) : (g.prototype = c.prototype, new g()); })(o, l), o.prototype.componentDidMount = function() { this.updateOffsetFromParent(); - var s = this.offsetFromParent, c = s.left, g = s.top, b = this.getDraggablePosition(), x = b.x, z = b.y; + var s = this.offsetFromParent, c = s.left, g = s.top, y = this.getDraggablePosition(), x = y.x, z = y.y; this.draggable.setState({ x: x - c, y: z - g }), this.forceUpdate(); }, o.prototype.getDraggablePosition = function() { var s = this.draggable.state; @@ -9802,22 +9876,22 @@ ${k}`); } }, o.prototype.onDragStart = function(s, c) { if (this.props.onDragStart && this.props.onDragStart(s, c), this.props.bounds) { - var g, b = this.getParent(), x = this.props.scale; - if (this.props.bounds === "parent") g = b; + var g, y = this.getParent(), x = this.props.scale; + if (this.props.bounds === "parent") g = y; else { if (this.props.bounds === "body") { - var z = b.getBoundingClientRect(), K = z.left, Y = z.top, ie = document.body.getBoundingClientRect(), ue = -(K - b.offsetLeft * x - ie.left) / x, he = -(Y - b.offsetTop * x - ie.top) / x, de = (document.body.offsetWidth - this.resizable.size.width * x) / x + ue, Oe = (document.body.offsetHeight - this.resizable.size.height * x) / x + he; + var z = y.getBoundingClientRect(), K = z.left, Y = z.top, ie = document.body.getBoundingClientRect(), ue = -(K - y.offsetLeft * x - ie.left) / x, he = -(Y - y.offsetTop * x - ie.top) / x, de = (document.body.offsetWidth - this.resizable.size.width * x) / x + ue, Oe = (document.body.offsetHeight - this.resizable.size.height * x) / x + he; return this.setState({ bounds: { top: he, right: de, bottom: Oe, left: ue } }); } if (this.props.bounds === "window") { if (!this.resizable) return; - var Ce = b.getBoundingClientRect(), ze = Ce.left, st = Ce.top, $e = -(ze - b.offsetLeft * x) / x, je = -(st - b.offsetTop * x) / x; - return de = (window.innerWidth - this.resizable.size.width * x) / x + $e, Oe = (window.innerHeight - this.resizable.size.height * x) / x + je, this.setState({ bounds: { top: je, right: de, bottom: Oe, left: $e } }); + var Ce = y.getBoundingClientRect(), ze = Ce.left, st = Ce.top, Be = -(ze - y.offsetLeft * x) / x, je = -(st - y.offsetTop * x) / x; + return de = (window.innerWidth - this.resizable.size.width * x) / x + Be, Oe = (window.innerHeight - this.resizable.size.height * x) / x + je, this.setState({ bounds: { top: je, right: de, bottom: Oe, left: Be } }); } g = document.querySelector(this.props.bounds); } - if (g instanceof HTMLElement && b instanceof HTMLElement) { - var dt = g.getBoundingClientRect(), vt = dt.left, $t = dt.top, xt = b.getBoundingClientRect(), It = (vt - xt.left) / x, St = $t - xt.top; + if (g instanceof HTMLElement && y instanceof HTMLElement) { + var dt = g.getBoundingClientRect(), vt = dt.left, Bt = dt.top, xt = y.getBoundingClientRect(), It = (vt - xt.left) / x, St = Bt - xt.top; if (this.resizable) { this.updateOffsetFromParent(); var mt = this.offsetFromParent; @@ -9832,12 +9906,12 @@ ${k}`); } }, o.prototype.onDragStop = function(s, c) { if (this.props.onDragStop) { - var g = this.offsetFromParent, b = g.left, x = g.top; - return this.props.onDragStop(s, Zt(Zt({}, c), { x: c.x + b, y: c.y + x })); + var g = this.offsetFromParent, y = g.left, x = g.top; + return this.props.onDragStop(s, Zt(Zt({}, c), { x: c.x + y, y: c.y + x })); } }, o.prototype.onResizeStart = function(s, c, g) { s.stopPropagation(), this.resizing = !0; - var b = this.props.scale, x = this.offsetFromParent, z = this.getDraggablePosition(); + var y = this.props.scale, x = this.offsetFromParent, z = this.getDraggablePosition(); if (this.resizingPosition = { x: z.x + x.left, y: z.y + x.top }, this.setState({ original: z }), this.props.bounds) { var K = this.getParent(), Y = void 0; Y = this.props.bounds === "parent" ? K : this.props.bounds === "body" ? document.body : this.props.bounds === "window" ? window : document.querySelector(this.props.bounds); @@ -9849,24 +9923,24 @@ ${k}`); he = Oe.width * Ce; } else he.endsWith("px") && (he = Number(he.replace("px", ""))); de && typeof de == "string" && (de.endsWith("%") ? (Ce = Number(de.replace("%", "")) / 100, de = Oe.width * Ce) : de.endsWith("px") && (de = Number(de.replace("px", "")))); - var ze = ie.getBoundingClientRect(), st = ze.left, $e = ze.top, je = this.props.bounds === "window" ? { left: 0, top: 0 } : Y.getBoundingClientRect(), dt = je.left, vt = je.top, $t = this.getOffsetWidth(Y), xt = this.getOffsetHeight(Y), It = c.toLowerCase().endsWith("left"), St = c.toLowerCase().endsWith("right"), mt = c.startsWith("top"), En = c.startsWith("bottom"); + var ze = ie.getBoundingClientRect(), st = ze.left, Be = ze.top, je = this.props.bounds === "window" ? { left: 0, top: 0 } : Y.getBoundingClientRect(), dt = je.left, vt = je.top, Bt = this.getOffsetWidth(Y), xt = this.getOffsetHeight(Y), It = c.toLowerCase().endsWith("left"), St = c.toLowerCase().endsWith("right"), mt = c.startsWith("top"), En = c.startsWith("bottom"); if (It && this.resizable) { - var it = (st - dt) / b + this.resizable.size.width; + var it = (st - dt) / y + this.resizable.size.width; this.setState({ maxWidth: it > Number(he) ? he : it }); } - (St || this.props.lockAspectRatio && !It) && (it = $t + (dt - st) / b, this.setState({ maxWidth: it > Number(he) ? he : it })), mt && this.resizable && (it = ($e - vt) / b + this.resizable.size.height, this.setState({ maxHeight: it > Number(de) ? de : it })), (En || this.props.lockAspectRatio && !mt) && (it = xt + (vt - $e) / b, this.setState({ maxHeight: it > Number(de) ? de : it })); + (St || this.props.lockAspectRatio && !It) && (it = Bt + (dt - st) / y, this.setState({ maxWidth: it > Number(he) ? he : it })), mt && this.resizable && (it = (Be - vt) / y + this.resizable.size.height, this.setState({ maxHeight: it > Number(de) ? de : it })), (En || this.props.lockAspectRatio && !mt) && (it = xt + (vt - Be) / y, this.setState({ maxHeight: it > Number(de) ? de : it })); } } else this.setState({ maxWidth: this.props.maxWidth, maxHeight: this.props.maxHeight }); this.props.onResizeStart && this.props.onResizeStart(s, c, g); - }, o.prototype.onResize = function(s, c, g, b) { - var x = { x: this.state.original.x, y: this.state.original.y }, z = -b.width, K = -b.height; + }, o.prototype.onResize = function(s, c, g, y) { + var x = { x: this.state.original.x, y: this.state.original.y }, z = -y.width, K = -y.height; ["top", "left", "topLeft", "bottomLeft", "topRight"].indexOf(c) !== -1 && (c === "bottomLeft" ? x.x += z : (c === "topRight" || (x.x += z), x.y += K)), x.x === this.draggable.state.x && x.y === this.draggable.state.y || this.draggable.setState(x), this.updateOffsetFromParent(); var Y = this.offsetFromParent, ie = this.getDraggablePosition().x + Y.left, ue = this.getDraggablePosition().y + Y.top; - this.resizingPosition = { x: ie, y: ue }, this.props.onResize && this.props.onResize(s, c, g, b, { x: ie, y: ue }); - }, o.prototype.onResizeStop = function(s, c, g, b) { + this.resizingPosition = { x: ie, y: ue }, this.props.onResize && this.props.onResize(s, c, g, y, { x: ie, y: ue }); + }, o.prototype.onResizeStop = function(s, c, g, y) { this.resizing = !1; var x = this.getMaxSizesFromProps(), z = x.maxWidth, K = x.maxHeight; - this.setState({ maxWidth: z, maxHeight: K }), this.props.onResizeStop && this.props.onResizeStop(s, c, g, b, this.resizingPosition); + this.setState({ maxWidth: z, maxHeight: K }), this.props.onResizeStop && this.props.onResizeStop(s, c, g, y, this.resizingPosition); }, o.prototype.updateSize = function(s) { this.resizable && this.resizable.updateSize({ width: s.width, height: s.height }); }, o.prototype.updatePosition = function(s) { @@ -9874,23 +9948,23 @@ ${k}`); }, o.prototype.updateOffsetFromParent = function() { var s = this.props.scale, c = this.getParent(), g = this.getSelfElement(); if (!c || g === null) return { top: 0, left: 0 }; - var b = c.getBoundingClientRect(), x = b.left, z = b.top, K = g.getBoundingClientRect(), Y = this.getDraggablePosition(); + var y = c.getBoundingClientRect(), x = y.left, z = y.top, K = g.getBoundingClientRect(), Y = this.getDraggablePosition(); this.offsetFromParent = { left: K.left - x - Y.x * s, top: K.top - z - Y.y * s }; }, o.prototype.render = function() { - var s = this.props, c = s.disableDragging, g = s.style, b = s.dragHandleClassName, x = s.position, z = s.onMouseDown, K = s.onMouseUp, Y = s.dragAxis, ie = s.dragGrid, ue = s.bounds, he = s.enableUserSelectHack, de = s.cancel, Oe = s.children, Ce = (s.onResizeStart, s.onResize, s.onResizeStop, s.onDragStart, s.onDrag, s.onDragStop, s.resizeHandleStyles), ze = s.resizeHandleClasses, st = s.resizeHandleComponent, $e = s.enableResizing, je = s.resizeGrid, dt = s.resizeHandleWrapperClass, vt = s.resizeHandleWrapperStyle, $t = s.scale, xt = s.allowAnyClick, It = (function(qt, cn) { + var s = this.props, c = s.disableDragging, g = s.style, y = s.dragHandleClassName, x = s.position, z = s.onMouseDown, K = s.onMouseUp, Y = s.dragAxis, ie = s.dragGrid, ue = s.bounds, he = s.enableUserSelectHack, de = s.cancel, Oe = s.children, Ce = (s.onResizeStart, s.onResize, s.onResizeStop, s.onDragStart, s.onDrag, s.onDragStop, s.resizeHandleStyles), ze = s.resizeHandleClasses, st = s.resizeHandleComponent, Be = s.enableResizing, je = s.resizeGrid, dt = s.resizeHandleWrapperClass, vt = s.resizeHandleWrapperStyle, Bt = s.scale, xt = s.allowAnyClick, It = (function(qt, cn) { var Nt = {}; - for (var Ut in qt) Object.prototype.hasOwnProperty.call(qt, Ut) && cn.indexOf(Ut) < 0 && (Nt[Ut] = qt[Ut]); + for (var Ft in qt) Object.prototype.hasOwnProperty.call(qt, Ft) && cn.indexOf(Ft) < 0 && (Nt[Ft] = qt[Ft]); if (qt != null && typeof Object.getOwnPropertySymbols == "function") { var un = 0; - for (Ut = Object.getOwnPropertySymbols(qt); un < Ut.length; un++) cn.indexOf(Ut[un]) < 0 && Object.prototype.propertyIsEnumerable.call(qt, Ut[un]) && (Nt[Ut[un]] = qt[Ut[un]]); + for (Ft = Object.getOwnPropertySymbols(qt); un < Ft.length; un++) cn.indexOf(Ft[un]) < 0 && Object.prototype.propertyIsEnumerable.call(qt, Ft[un]) && (Nt[Ft[un]] = qt[Ft[un]]); } return Nt; })(s, ["disableDragging", "style", "dragHandleClassName", "position", "onMouseDown", "onMouseUp", "dragAxis", "dragGrid", "bounds", "enableUserSelectHack", "cancel", "children", "onResizeStart", "onResize", "onResizeStop", "onDragStart", "onDrag", "onDragStop", "resizeHandleStyles", "resizeHandleClasses", "resizeHandleComponent", "enableResizing", "resizeGrid", "resizeHandleWrapperClass", "resizeHandleWrapperStyle", "scale", "allowAnyClick"]), St = this.props.default ? Zt({}, this.props.default) : void 0; delete It.default; - var mt, En = c || b ? { cursor: "auto" } : { cursor: "move" }, it = Zt(Zt(Zt({}, sa), En), g), xn = this.offsetFromParent, jn = xn.left, lo = xn.top; + var mt, En = c || y ? { cursor: "auto" } : { cursor: "move" }, it = Zt(Zt(Zt({}, sa), En), g), xn = this.offsetFromParent, jn = xn.left, lo = xn.top; x && (mt = { x: x.x - jn, y: x.y - lo }); var Wt, Jt = this.resizing ? void 0 : mt, en = this.resizing ? "both" : Y; - return (0, i.createElement)(aa, { ref: this.refDraggable, handle: b ? "." + b : void 0, defaultPosition: St, onMouseDown: z, onMouseUp: K, onStart: this.onDragStart, onDrag: this.onDrag, onStop: this.onDragStop, axis: en, disabled: c, grid: ie, bounds: ue ? this.state.bounds : void 0, position: Jt, enableUserSelectHack: he, cancel: de, scale: $t, allowAnyClick: xt, nodeRef: this.resizableElement }, (0, i.createElement)(Gn, Zt({}, It, { ref: this.refResizable, defaultSize: St, size: this.props.size, enable: typeof $e == "boolean" ? (Wt = $e, { bottom: Wt, bottomLeft: Wt, bottomRight: Wt, left: Wt, right: Wt, top: Wt, topLeft: Wt, topRight: Wt }) : $e, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: it, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.resizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.resizing ? this.state.maxHeight : this.props.maxHeight, grid: je, handleWrapperClass: dt, handleWrapperStyle: vt, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: Ce, handleClasses: ze, handleComponent: st, scale: this.props.scale }), Oe)); + return (0, i.createElement)(aa, { ref: this.refDraggable, handle: y ? "." + y : void 0, defaultPosition: St, onMouseDown: z, onMouseUp: K, onStart: this.onDragStart, onDrag: this.onDrag, onStop: this.onDragStop, axis: en, disabled: c, grid: ie, bounds: ue ? this.state.bounds : void 0, position: Jt, enableUserSelectHack: he, cancel: de, scale: Bt, allowAnyClick: xt, nodeRef: this.resizableElement }, (0, i.createElement)(Gn, Zt({}, It, { ref: this.refResizable, defaultSize: St, size: this.props.size, enable: typeof Be == "boolean" ? (Wt = Be, { bottom: Wt, bottomLeft: Wt, bottomRight: Wt, left: Wt, right: Wt, top: Wt, topLeft: Wt, topRight: Wt }) : Be, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: it, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.resizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.resizing ? this.state.maxHeight : this.props.maxHeight, grid: je, handleWrapperClass: dt, handleWrapperStyle: vt, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: Ce, handleClasses: ze, handleComponent: st, scale: this.props.scale }), Oe)); }, o.defaultProps = { maxWidth: Number.MAX_SAFE_INTEGER, maxHeight: Number.MAX_SAFE_INTEGER, scale: 1, onResizeStart: function() { }, onResize: function() { }, onResizeStop: function() { @@ -9937,13 +10011,13 @@ ${k}`); return i.createElement(eo, null, [this.props.contentBefore, i.createElement(la, { key: "navigation", definitions: o.map((s) => s.props.label), activeTab: this.props.activeTab, onClick: this.handleTabClick }), this.props.contentAfter], o.filter((s) => s.props.label === this.props.activeTab)); } } - var Ni = T(8142), br = T.n(Ni); + var Ni = T(8142), yr = T.n(Ni); class Do extends i.Component { render() { return [i.createElement("label", { htmlFor: this.props.id, key: "label" }, this.props.label, ":"), i.createElement("select", { id: this.props.id, value: this.props.value, onChange: this.props.onChange, key: "select" }, this.props.options.map((o) => i.createElement("option", { value: o, key: o }, o)))]; } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } T(5627); @@ -9971,7 +10045,7 @@ ${k}`); } } const ni = _e(({ ui: { sidePaneWidth: l } }) => ({ sidePaneWidth: l }), { setSidePaneWidth: function(l) { - return { type: $n, newWidth: l }; + return { type: Bn, newWidth: l }; } })(Di); class Ar extends i.Component { constructor(o) { @@ -9993,7 +10067,7 @@ ${k}`); return this.definition.node === this.globalTreeProps.activeNode; } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } class Ii extends i.PureComponent { @@ -10003,27 +10077,27 @@ ${k}`); return this.props.dontRenderValue || (o = i.createElement("span", { className: "ck-inspector-tree-node__attribute__value" }, s)), i.createElement("span", { className: "ck-inspector-tree-node__attribute" }, i.createElement("span", { className: "ck-inspector-tree-node__attribute__name", title: s }, this.props.name), o); } } - class yr extends i.Component { + class br extends i.Component { render() { const o = this.props.definition, s = { className: ["ck-inspector-tree__position", o.type === "selection" ? "ck-inspector-tree__position_selection" : "", o.type === "marker" ? "ck-inspector-tree__position_marker" : "", o.isEnd ? "ck-inspector-tree__position_end" : ""].join(" "), style: {} }; return o.presentation && o.presentation.color && (s.style["--ck-inspector-color-tree-position"] = o.presentation.color), o.type === "marker" && (s["data-marker-name"] = o.name), i.createElement("span", s, "​"); } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } class vr extends Ar { render() { - const o = this.definition, s = o.presentation, c = s && s.isEmpty, g = s && s.cssClass, b = this.getChildren(), x = ["ck-inspector-code", "ck-inspector-tree-node", this.isActive ? "ck-inspector-tree-node_active" : "", c ? "ck-inspector-tree-node_empty" : "", g], z = [], K = []; + const o = this.definition, s = o.presentation, c = s && s.isEmpty, g = s && s.cssClass, y = this.getChildren(), x = ["ck-inspector-code", "ck-inspector-tree-node", this.isActive ? "ck-inspector-tree-node_active" : "", c ? "ck-inspector-tree-node_empty" : "", g], z = [], K = []; o.positionsBefore && o.positionsBefore.forEach((ie, ue) => { - z.push(i.createElement(yr, { key: "position-before:" + ue, definition: ie })); + z.push(i.createElement(br, { key: "position-before:" + ue, definition: ie })); }), o.positionsAfter && o.positionsAfter.forEach((ie, ue) => { - K.push(i.createElement(yr, { key: "position-after:" + ue, definition: ie })); + K.push(i.createElement(br, { key: "position-after:" + ue, definition: ie })); }), o.positions && o.positions.forEach((ie, ue) => { - b.push(i.createElement(yr, { key: "position" + ue, definition: ie })); + y.push(i.createElement(br, { key: "position" + ue, definition: ie })); }); let Y = o.name; - return this.globalTreeProps.showElementTypes && (Y = o.elementType + ":" + Y), i.createElement("div", { className: x.join(" "), onClick: this.handleClick }, z, i.createElement("span", { className: "ck-inspector-tree-node__name" }, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_open" }), Y, this.getAttributes(), c ? "" : i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_close" })), i.createElement("div", { className: "ck-inspector-tree-node__content" }, b), c ? "" : i.createElement("span", { className: "ck-inspector-tree-node__name ck-inspector-tree-node__name_close" }, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_open" }), "/", Y, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_close" }), K)); + return this.globalTreeProps.showElementTypes && (Y = o.elementType + ":" + Y), i.createElement("div", { className: x.join(" "), onClick: this.handleClick }, z, i.createElement("span", { className: "ck-inspector-tree-node__name" }, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_open" }), Y, this.getAttributes(), c ? "" : i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_close" })), i.createElement("div", { className: "ck-inspector-tree-node__content" }, y), c ? "" : i.createElement("span", { className: "ck-inspector-tree-node__name ck-inspector-tree-node__name_close" }, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_open" }), "/", Y, i.createElement("span", { className: "ck-inspector-tree-node__name__bracket ck-inspector-tree-node__name__bracket_close" }), K)); } getAttributes() { const o = [], s = this.definition; @@ -10031,30 +10105,30 @@ ${k}`); return o; } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } class ri extends Ar { render() { const o = this.definition, s = ["ck-inspector-tree-text", this.isActive ? "ck-inspector-tree-node_active" : ""].join(" "); let c = this.definition.text; - o.positions && o.positions.length && (c = c.split(""), Array.from(o.positions).sort((b, x) => b.offset < x.offset ? -1 : b.offset === x.offset ? 0 : 1).reverse().forEach((b, x) => { - c.splice(b.offset - o.startOffset, 0, i.createElement(yr, { key: "position" + x, definition: b })); + o.positions && o.positions.length && (c = c.split(""), Array.from(o.positions).sort((y, x) => y.offset < x.offset ? -1 : y.offset === x.offset ? 0 : 1).reverse().forEach((y, x) => { + c.splice(y.offset - o.startOffset, 0, i.createElement(br, { key: "position" + x, definition: y })); })); const g = [c]; - return o.positionsBefore && o.positionsBefore.length && o.positionsBefore.forEach((b, x) => { - g.unshift(i.createElement(yr, { key: "position-before:" + x, definition: b })); - }), o.positionsAfter && o.positionsAfter.length && o.positionsAfter.forEach((b, x) => { - g.push(i.createElement(yr, { key: "position-after:" + x, definition: b })); + return o.positionsBefore && o.positionsBefore.length && o.positionsBefore.forEach((y, x) => { + g.unshift(i.createElement(br, { key: "position-before:" + x, definition: y })); + }), o.positionsAfter && o.positionsAfter.length && o.positionsAfter.forEach((y, x) => { + g.push(i.createElement(br, { key: "position-after:" + x, definition: y })); }), i.createElement("span", { className: s, onClick: this.handleClick }, i.createElement("span", { className: "ck-inspector-tree-node__content" }, this.globalTreeProps.showCompactText ? "" : this.getAttributes(), this.globalTreeProps.showCompactText ? "" : '"', g, this.globalTreeProps.showCompactText ? "" : '"')); } getAttributes() { const o = [], s = this.definition, c = s.presentation, g = c && c.dontRenderAttributeValue; - for (const [b, x] of s.attributes) o.push(i.createElement(Ii, { key: b, name: b, value: x, dontRenderValue: g })); + for (const [y, x] of s.attributes) o.push(i.createElement(Ii, { key: y, name: y, value: x, dontRenderValue: g })); return i.createElement("span", { className: "ck-inspector-tree-text__attributes" }, o); } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } class Io extends i.Component { @@ -10093,7 +10167,7 @@ ${k}`); return i.createElement(eo, null, [i.createElement("div", { className: "ck-inspector-tree__config", key: "root-cfg" }, i.createElement(Do, { id: "view-root-select", label: "Root", value: this.props.currentRootName, options: Pr(o).map((s) => s.rootName), onChange: this.handleRootChange })), i.createElement("span", { className: "ck-inspector-separator", key: "separator" }), i.createElement("div", { className: "ck-inspector-tree__config", key: "text-cfg" }, i.createElement(Zn, { label: "Compact text", id: "model-compact-text", isChecked: this.props.showCompactText, onChange: this.props.toggleModelShowCompactText }), i.createElement(Zn, { label: "Show markers", id: "model-show-markers", isChecked: this.props.showMarkers, onChange: this.props.toggleModelShowMarkers }))], i.createElement(kr, { className: [this.props.showMarkers ? "" : "ck-inspector-model-tree__hide-markers"], definition: this.props.treeDefinition, textDirection: o.locale.contentLanguageDirection, onClick: this.handleTreeClick, showCompactText: this.props.showCompactText, activeNode: this.props.currentNode })); } } - const Jn = _e(({ editors: l, currentEditorName: o, model: { treeDefinition: s, currentRootName: c, currentNode: g, ui: { showMarkers: b, showCompactText: x } } }) => ({ treeDefinition: s, editors: l, currentEditorName: o, currentRootName: c, currentNode: g, showMarkers: b, showCompactText: x }), { toggleModelShowCompactText: function() { + const Jn = _e(({ editors: l, currentEditorName: o, model: { treeDefinition: s, currentRootName: c, currentNode: g, ui: { showMarkers: y, showCompactText: x } } }) => ({ treeDefinition: s, editors: l, currentEditorName: o, currentRootName: c, currentNode: g, showMarkers: y, showCompactText: x }), { toggleModelShowCompactText: function() { return { type: Dt }; }, setModelCurrentRootName: function(l) { return { type: Qe, currentRootName: l }; @@ -10107,13 +10181,13 @@ ${k}`); render() { const o = this.props.presentation && this.props.presentation.expandCollapsibles, s = []; for (const c in this.props.itemDefinitions) { - const g = this.props.itemDefinitions[c], { subProperties: b, presentation: x = {} } = g, z = b && Object.keys(b).length, K = Qr(String(g.value), 2e3), Y = [i.createElement(ca, { key: `${this.props.name}-${c}-name`, name: c, listUid: this.props.name, canCollapse: z, colorBox: x.colorBox, expandCollapsibles: o, onClick: this.props.onPropertyTitleClick, title: g.title }), i.createElement("dd", { key: `${this.props.name}-${c}-value` }, i.createElement("input", { id: `${this.props.name}-${c}-value-input`, type: "text", value: K, readOnly: !0 }))]; - z && Y.push(i.createElement(oi, { name: `${this.props.name}-${c}`, key: `${this.props.name}-${c}`, itemDefinitions: b, presentation: this.props.presentation })), s.push(Y); + const g = this.props.itemDefinitions[c], { subProperties: y, presentation: x = {} } = g, z = y && Object.keys(y).length, K = Qr(String(g.value), 2e3), Y = [i.createElement(ca, { key: `${this.props.name}-${c}-name`, name: c, listUid: this.props.name, canCollapse: z, colorBox: x.colorBox, expandCollapsibles: o, onClick: this.props.onPropertyTitleClick, title: g.title }), i.createElement("dd", { key: `${this.props.name}-${c}-value` }, i.createElement("input", { id: `${this.props.name}-${c}-value-input`, type: "text", value: K, readOnly: !0 }))]; + z && Y.push(i.createElement(oi, { name: `${this.props.name}-${c}`, key: `${this.props.name}-${c}`, itemDefinitions: y, presentation: this.props.presentation })), s.push(Y); } return i.createElement("dl", { className: "ck-inspector-property-list ck-inspector-code" }, s); } shouldComponentUpdate(o) { - return !br()(this.props, o); + return !yr()(this.props, o); } } class ca extends i.PureComponent { @@ -10155,7 +10229,7 @@ ${k}`); return l; }, zi.apply(null, arguments); } - const Bt = ({ styles: l = {}, ...o }) => i.createElement("svg", zi({ viewBox: "0 0 19 19", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { d: "M17 15.75a.75.75 0 01.102 1.493L17 17.25H9a.75.75 0 01-.102-1.493L9 15.75h8zM2.156 2.947l.095.058 7.58 5.401a.75.75 0 01.084 1.152l-.083.069-7.58 5.425a.75.75 0 01-.958-1.148l.086-.071 6.724-4.815-6.723-4.792a.75.75 0 01-.233-.95l.057-.096a.75.75 0 01.951-.233z" })); + const $t = ({ styles: l = {}, ...o }) => i.createElement("svg", zi({ viewBox: "0 0 19 19", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { d: "M17 15.75a.75.75 0 01.102 1.493L17 17.25H9a.75.75 0 01-.102-1.493L9 15.75h8zM2.156 2.947l.095.058 7.58 5.401a.75.75 0 01.084 1.152l-.083.069-7.58 5.425a.75.75 0 01-.958-1.148l.086-.071 6.724-4.815-6.723-4.792a.75.75 0 01-.233-.95l.057-.096a.75.75 0 01.951-.233z" })); function tr() { return tr = Object.assign ? Object.assign.bind() : function(l) { for (var o = 1; o < arguments.length; o++) { @@ -10179,7 +10253,7 @@ ${k}`); } render() { const o = this.props.currentNodeDefinition; - return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type)), ":", o.type === "Text" ? i.createElement("em", null, o.name) : o.name), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: this.handleNodeLogButtonClick }), i.createElement(Et, { key: "schema", icon: i.createElement(Ai, null), text: "Show in schema", onClick: this.handleNodeSchemaButtonClick })], lists: [{ name: "Attributes", url: o.url, itemDefinitions: o.attributes }, { name: "Properties", url: o.url, itemDefinitions: o.properties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a node in the tree to inspect")); + return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type)), ":", o.type === "Text" ? i.createElement("em", null, o.name) : o.name), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: this.handleNodeLogButtonClick }), i.createElement(Et, { key: "schema", icon: i.createElement(Ai, null), text: "Show in schema", onClick: this.handleNodeSchemaButtonClick })], lists: [{ name: "Attributes", url: o.url, itemDefinitions: o.attributes }, { name: "Properties", url: o.url, itemDefinitions: o.properties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a node in the tree to inspect")); } } const ua = _e(({ editors: l, currentEditorName: o, model: { currentNodeDefinition: s } }) => ({ editors: l, currentEditorName: o, currentNodeDefinition: s }), { setActiveTab: Eo, setSchemaCurrentDefinitionName: Gr })(ii); @@ -10207,12 +10281,12 @@ ${k}`); } render() { const o = this.props.editor, s = this.props.info; - return i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: Ot, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Selection"))), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: this.handleSelectionLogButtonClick }), i.createElement(Et, { key: "scroll", icon: i.createElement(Ro, null), text: "Scroll to selection", onClick: this.handleScrollToSelectionButtonClick })], lists: [{ name: "Attributes", url: `${Ot}#function-getAttributes`, itemDefinitions: s.attributes }, { name: "Properties", url: `${Ot}`, itemDefinitions: s.properties }, { name: "Anchor", url: `${Ot}#member-anchor`, buttons: [{ icon: i.createElement(Bt, null), text: "Log in console", onClick: () => Ye.log(o.model.document.selection.anchor) }], itemDefinitions: s.anchor }, { name: "Focus", url: `${Ot}#member-focus`, buttons: [{ icon: i.createElement(Bt, null), text: "Log in console", onClick: () => Ye.log(o.model.document.selection.focus) }], itemDefinitions: s.focus }, { name: "Ranges", url: `${Ot}#function-getRanges`, buttons: [{ icon: i.createElement(Bt, null), text: "Log in console", onClick: () => Ye.log(...o.model.document.selection.getRanges()) }], itemDefinitions: s.ranges, presentation: { expandCollapsibles: !0 } }] }); + return i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: Ot, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Selection"))), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: this.handleSelectionLogButtonClick }), i.createElement(Et, { key: "scroll", icon: i.createElement(Ro, null), text: "Scroll to selection", onClick: this.handleScrollToSelectionButtonClick })], lists: [{ name: "Attributes", url: `${Ot}#function-getAttributes`, itemDefinitions: s.attributes }, { name: "Properties", url: `${Ot}`, itemDefinitions: s.properties }, { name: "Anchor", url: `${Ot}#member-anchor`, buttons: [{ icon: i.createElement($t, null), text: "Log in console", onClick: () => Ye.log(o.model.document.selection.anchor) }], itemDefinitions: s.anchor }, { name: "Focus", url: `${Ot}#member-focus`, buttons: [{ icon: i.createElement($t, null), text: "Log in console", onClick: () => Ye.log(o.model.document.selection.focus) }], itemDefinitions: s.focus }, { name: "Ranges", url: `${Ot}#function-getRanges`, buttons: [{ icon: i.createElement($t, null), text: "Log in console", onClick: () => Ye.log(...o.model.document.selection.getRanges()) }], itemDefinitions: s.ranges, presentation: { expandCollapsibles: !0 } }] }); } } const us = _e(({ editors: l, currentEditorName: o, model: { ranges: s } }) => { - const c = l.get(o), g = (function(b, x) { - const z = b.model.document.selection, K = z.anchor, Y = z.focus, ie = { properties: { isCollapsed: { value: z.isCollapsed }, isBackward: { value: z.isBackward }, isGravityOverridden: { value: z.isGravityOverridden }, rangeCount: { value: z.rangeCount } }, attributes: {}, anchor: Mo(zt(K)), focus: Mo(zt(Y)), ranges: {} }; + const c = l.get(o), g = (function(y, x) { + const z = y.model.document.selection, K = z.anchor, Y = z.focus, ie = { properties: { isCollapsed: { value: z.isCollapsed }, isBackward: { value: z.isBackward }, isGravityOverridden: { value: z.isGravityOverridden }, rangeCount: { value: z.rangeCount } }, attributes: {}, anchor: Mo(zt(K)), focus: Mo(zt(Y)), ranges: {} }; for (const [ue, he] of z.getAttributes()) ie.attributes[ue] = { value: he }; x.forEach((ue, he) => { ie.ranges[he] = { value: "", subProperties: { start: { value: "", subProperties: pt(Mo(ue.start)) }, end: { value: "", subProperties: pt(Mo(ue.end)) } } }; @@ -10222,24 +10296,24 @@ ${k}`); })(c, s); return { editor: c, currentEditorName: o, info: g }; }, {})(cs); - function Mo({ path: l, stickiness: o, index: s, isAtEnd: c, isAtStart: g, offset: b, textNode: x }) { - return { path: { value: l }, stickiness: { value: o }, index: { value: s }, isAtEnd: { value: c }, isAtStart: { value: g }, offset: { value: b }, textNode: { value: x } }; + function Mo({ path: l, stickiness: o, index: s, isAtEnd: c, isAtStart: g, offset: y, textNode: x }) { + return { path: { value: l }, stickiness: { value: o }, index: { value: s }, isAtEnd: { value: c }, isAtStart: { value: g }, offset: { value: y }, textNode: { value: x } }; } class ds extends i.Component { render() { const o = (function(g) { - const b = {}; + const y = {}; for (const x of g) { const z = x.name.split(":"); - let K = b; + let K = y; for (const Y of z) { const ie = Y === z[z.length - 1]; K = K[Y] ? K[Y] : K[Y] = ie ? x : {}; } } - return b; + return y; })(this.props.markers), s = da(o), c = this.props.editors.get(this.props.currentEditorName); - return Object.keys(o).length ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: "https://ckeditor.com/docs/ckeditor5/latest/api/module_engine_model_markercollection-Marker.html", target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Markers"))), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: () => Ye.log([...c.model.markers]) })], lists: [{ name: "Markers tree", itemDefinitions: s, presentation: { expandCollapsibles: !0 } }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "No markers in the document.")); + return Object.keys(o).length ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: "https://ckeditor.com/docs/ckeditor5/latest/api/module_engine_model_markercollection-Marker.html", target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Markers"))), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: () => Ye.log([...c.model.markers]) })], lists: [{ name: "Markers tree", itemDefinitions: s, presentation: { expandCollapsibles: !0 } }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "No markers in the document.")); } } const ps = _e(({ editors: l, currentEditorName: o, model: { markers: s } }) => ({ editors: l, currentEditorName: o, markers: s }), {})(ds); @@ -10282,10 +10356,10 @@ ${k}`); return i.createElement(eo, null, [i.createElement("div", { className: "ck-inspector-tree__config", key: "root-cfg" }, i.createElement(Do, { id: "view-root-select", label: "Root", value: this.props.currentRootName, options: Mn(o).map((s) => s.rootName), onChange: this.handleRootChange })), i.createElement("span", { className: "ck-inspector-separator", key: "separator" }), i.createElement("div", { className: "ck-inspector-tree__config", key: "types-cfg" }, i.createElement(Zn, { label: "Show element types", id: "view-show-types", isChecked: this.props.showElementTypes, onChange: this.props.toggleViewShowElementTypes }))], i.createElement(kr, { definition: this.props.treeDefinition, textDirection: o.locale.contentLanguageDirection, onClick: this.handleTreeClick, showCompactText: "true", showElementTypes: this.props.showElementTypes, activeNode: this.props.currentNode })); } } - const fa = _e(({ editors: l, currentEditorName: o, view: { treeDefinition: s, currentRootName: c, currentNode: g, ui: { showElementTypes: b } } }) => ({ treeDefinition: s, editors: l, currentEditorName: o, currentRootName: c, currentNode: g, showElementTypes: b }), { setViewCurrentRootName: function(l) { + const fa = _e(({ editors: l, currentEditorName: o, view: { treeDefinition: s, currentRootName: c, currentNode: g, ui: { showElementTypes: y } } }) => ({ treeDefinition: s, editors: l, currentEditorName: o, currentRootName: c, currentNode: g, showElementTypes: y }), { setViewCurrentRootName: function(l) { return { type: Rr, currentRootName: l }; }, toggleViewShowElementTypes: function() { - return { type: ye }; + return { type: be }; }, setViewCurrentNode: function(l) { return { type: M, currentNode: l }; }, setViewActiveTab: tt })(pa); @@ -10298,7 +10372,7 @@ ${k}`); } render() { const o = this.props.currentNodeDefinition; - return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type), ":"), o.type === "Text" ? i.createElement("em", null, o.name) : o.name), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: this.handleNodeLogButtonClick })], lists: [{ name: "Attributes", url: o.url, itemDefinitions: o.attributes }, { name: "Properties", url: o.url, itemDefinitions: o.properties }, { name: "Custom Properties", url: `${yt}_element-Element.html#function-getCustomProperty`, itemDefinitions: o.customProperties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a node in the tree to inspect")); + return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type), ":"), o.type === "Text" ? i.createElement("em", null, o.name) : o.name), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: this.handleNodeLogButtonClick })], lists: [{ name: "Attributes", url: o.url, itemDefinitions: o.attributes }, { name: "Properties", url: o.url, itemDefinitions: o.properties }, { name: "Custom Properties", url: `${bt}_element-Element.html#function-getCustomProperty`, itemDefinitions: o.customProperties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a node in the tree to inspect")); } } const ha = _e(({ view: { currentNodeDefinition: l } }) => ({ currentNodeDefinition: l }), {})(nr), oo = "https://ckeditor.com/docs/ckeditor5/latest/api/module_engine_view_selection-Selection.html"; @@ -10316,12 +10390,12 @@ ${k}`); } render() { const o = this.props.editor, s = this.props.info; - return i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: oo, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Selection"))), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: this.handleSelectionLogButtonClick }), i.createElement(Et, { key: "scroll", icon: i.createElement(Ro, null), text: "Scroll to selection", onClick: this.handleScrollToSelectionButtonClick })], lists: [{ name: "Properties", url: `${oo}`, itemDefinitions: s.properties }, { name: "Anchor", url: `${oo}#member-anchor`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(o.editing.view.document.selection.anchor) }], itemDefinitions: s.anchor }, { name: "Focus", url: `${oo}#member-focus`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(o.editing.view.document.selection.focus) }], itemDefinitions: s.focus }, { name: "Ranges", url: `${oo}#function-getRanges`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(...o.editing.view.document.selection.getRanges()) }], itemDefinitions: s.ranges, presentation: { expandCollapsibles: !0 } }] }); + return i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: oo, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, "Selection"))), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: this.handleSelectionLogButtonClick }), i.createElement(Et, { key: "scroll", icon: i.createElement(Ro, null), text: "Scroll to selection", onClick: this.handleScrollToSelectionButtonClick })], lists: [{ name: "Properties", url: `${oo}`, itemDefinitions: s.properties }, { name: "Anchor", url: `${oo}#member-anchor`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(o.editing.view.document.selection.anchor) }], itemDefinitions: s.anchor }, { name: "Focus", url: `${oo}#member-focus`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(o.editing.view.document.selection.focus) }], itemDefinitions: s.focus }, { name: "Ranges", url: `${oo}#function-getRanges`, buttons: [{ type: "log", text: "Log in console", onClick: () => Ye.log(...o.editing.view.document.selection.getRanges()) }], itemDefinitions: s.ranges, presentation: { expandCollapsibles: !0 } }] }); } } const io = _e(({ editors: l, currentEditorName: o, view: { ranges: s } }) => { - const c = l.get(o), g = (function(b, x) { - const z = b.editing.view.document.selection, K = { properties: { isCollapsed: { value: z.isCollapsed }, isBackward: { value: z.isBackward }, isFake: { value: z.isFake }, rangeCount: { value: z.rangeCount } }, anchor: ai(jt(z.anchor)), focus: ai(jt(z.focus)), ranges: {} }; + const c = l.get(o), g = (function(y, x) { + const z = y.editing.view.document.selection, K = { properties: { isCollapsed: { value: z.isCollapsed }, isBackward: { value: z.isBackward }, isFake: { value: z.isFake }, rangeCount: { value: z.rangeCount } }, anchor: ai(jt(z.anchor)), focus: ai(jt(z.focus)), ranges: {} }; x.forEach((Y, ie) => { K.ranges[ie] = { value: "", subProperties: { start: { value: "", subProperties: pt(ai(Y.start)) }, end: { value: "", subProperties: pt(ai(Y.end)) } } }; }); @@ -10339,7 +10413,7 @@ ${k}`); } } const ga = _e(({ currentEditorName: l, view: { ui: { activeTab: o } } }) => ({ currentEditorName: l, activeTab: o }), { setViewActiveTab: tt, updateViewState: He })(hs); - class ba extends i.Component { + class ya extends i.Component { constructor(o) { super(o), this.handleTreeClick = this.handleTreeClick.bind(this); } @@ -10350,9 +10424,9 @@ ${k}`); return i.createElement(eo, null, i.createElement(kr, { definition: this.props.treeDefinition, onClick: this.handleTreeClick, activeNode: this.props.currentCommandName })); } } - const ya = _e(({ commands: { treeDefinition: l, currentCommandName: o } }) => ({ treeDefinition: l, currentCommandName: o }), { setCommandsCurrentCommandName: function(l) { + const ba = _e(({ commands: { treeDefinition: l, currentCommandName: o } }) => ({ treeDefinition: l, currentCommandName: o }), { setCommandsCurrentCommandName: function(l) { return { type: wt, currentCommandName: l }; - } })(ba); + } })(ya); function ao() { return ao = Object.assign ? Object.assign.bind() : function(l) { for (var o = 1; o < arguments.length; o++) { @@ -10375,13 +10449,13 @@ ${k}`); } render() { const o = this.props.currentCommandDefinition; - return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type)), ":", this.props.currentCommandName), i.createElement(Et, { key: "exec", icon: i.createElement(Ao, null), text: "Execute command", onClick: this.handleCommandExecuteButtonClick }), i.createElement(Et, { key: "log", icon: i.createElement(Bt, null), text: "Log in console", onClick: this.handleCommandLogButtonClick })], lists: [{ name: "Properties", url: o.url, itemDefinitions: o.properties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a command to inspect")); + return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.url, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type)), ":", this.props.currentCommandName), i.createElement(Et, { key: "exec", icon: i.createElement(Ao, null), text: "Execute command", onClick: this.handleCommandExecuteButtonClick }), i.createElement(Et, { key: "log", icon: i.createElement($t, null), text: "Log in console", onClick: this.handleCommandLogButtonClick })], lists: [{ name: "Properties", url: o.url, itemDefinitions: o.properties }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a command to inspect")); } } const si = _e(({ editors: l, currentEditorName: o, commands: { currentCommandName: s, currentCommandDefinition: c } }) => ({ editors: l, currentEditorName: o, currentCommandName: s, currentCommandDefinition: c }), {})(ms); class gs extends i.Component { render() { - return this.props.currentEditorName ? i.createElement(Yt, { splitVertically: "true" }, i.createElement(ya, null), i.createElement(ni, null, i.createElement(to, { activeTab: "Inspect" }, i.createElement(si, { label: "Inspect" })))) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Nothing to show. Attach another editor instance to start inspecting.")); + return this.props.currentEditorName ? i.createElement(Yt, { splitVertically: "true" }, i.createElement(ba, null), i.createElement(ni, null, i.createElement(to, { activeTab: "Inspect" }, i.createElement(si, { label: "Inspect" })))) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Nothing to show. Attach another editor instance to start inspecting.")); } } const Li = _e(({ currentEditorName: l }) => ({ currentEditorName: l }), { updateCommandsState: Lt })(gs); @@ -10397,7 +10471,7 @@ ${k}`); } } const ka = _e(({ schema: { treeDefinition: l, currentSchemaDefinitionName: o } }) => ({ treeDefinition: l, currentSchemaDefinitionName: o }), { setSchemaCurrentDefinitionName: Gr })(va); - class bs extends i.Component { + class ys extends i.Component { render() { const o = this.props.currentSchemaDefinition; return o ? i.createElement(er, { header: [i.createElement("span", { key: "link" }, i.createElement("a", { href: o.urls.general, target: "_blank", rel: "noopener noreferrer" }, i.createElement("b", null, o.type)), ":", this.props.currentSchemaDefinitionName)], lists: [{ name: "Properties", url: o.urls.general, itemDefinitions: o.properties }, { name: "Allowed attributes", url: o.urls.allowAttributes, itemDefinitions: o.allowAttributes }, { name: "Allowed children", url: o.urls.allowChildren, itemDefinitions: o.allowChildren, onPropertyTitleClick: (s) => { @@ -10407,10 +10481,10 @@ ${k}`); } }] }) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Select a schema definition to inspect")); } } - const ys = _e(({ editors: l, currentEditorName: o, schema: { currentSchemaDefinitionName: s, currentSchemaDefinition: c } }) => ({ editors: l, currentEditorName: o, currentSchemaDefinitionName: s, currentSchemaDefinition: c }), { setSchemaCurrentDefinitionName: Gr })(bs); + const bs = _e(({ editors: l, currentEditorName: o, schema: { currentSchemaDefinitionName: s, currentSchemaDefinition: c } }) => ({ editors: l, currentEditorName: o, currentSchemaDefinitionName: s, currentSchemaDefinition: c }), { setSchemaCurrentDefinitionName: Gr })(ys); class vs extends i.Component { render() { - return this.props.currentEditorName ? i.createElement(Yt, { splitVertically: "true" }, i.createElement(ka, null), i.createElement(ni, null, i.createElement(to, { activeTab: "Inspect" }, i.createElement(ys, { label: "Inspect" })))) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Nothing to show. Attach another editor instance to start inspecting.")); + return this.props.currentEditorName ? i.createElement(Yt, { splitVertically: "true" }, i.createElement(ka, null), i.createElement(ni, null, i.createElement(to, { activeTab: "Inspect" }, i.createElement(bs, { label: "Inspect" })))) : i.createElement(Yt, { isEmpty: "true" }, i.createElement("p", null, "Nothing to show. Attach another editor instance to start inspecting.")); } } const ks = _e(({ currentEditorName: l }) => ({ currentEditorName: l }))(vs); @@ -10490,24 +10564,24 @@ ${k}`); }, rr.apply(null, arguments); } const Ss = ({ styles: l = {}, ...o }) => i.createElement("svg", rr({ viewBox: "0 0 20 20", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { d: "M2.284 2.498c-.239.266-.184.617-.184 1.002V4H2a.5.5 0 00-.492.41L1.5 4.5V17a1 1 0 00.883.993L2.5 18h10a1 1 0 00.97-.752l-.081-.062c.438.368.976.54 1.507.526a2.5 2.5 0 01-2.232 1.783l-.164.005h-10a2.5 2.5 0 01-2.495-2.336L0 17V4.5a2 2 0 011.85-1.995L2 2.5l.284-.002zm10.532 0L13 2.5a2 2 0 011.995 1.85L15 4.5v2.28a2.243 2.243 0 00-1.5.404V4.5a.5.5 0 00-.41-.492L13 4v-.5l-.007-.144c-.031-.329.032-.626-.177-.858z" }), i.createElement("path", { d: "M6 .49l-.144.006a1.75 1.75 0 00-1.41.94l-.029.058.083-.004c-.69 0-1.25.56-1.25 1.25v1c0 .69.56 1.25 1.25 1.25h6c.69 0 1.25-.56 1.25-1.25v-1l-.006-.128a1.25 1.25 0 00-1.116-1.116l-.046-.002-.027-.058A1.75 1.75 0 009 .49H6zm0 1.5h3a.25.25 0 01.25.25l.007.102A.75.75 0 0010 2.99h.25v.5h-5.5v-.5H5a.75.75 0 00.743-.648l.007-.102A.25.25 0 016 1.99zm9.374 6.55a.75.75 0 01-.093 1.056l-2.33 1.954h6.127a.75.75 0 010 1.501h-5.949l2.19 1.837a.75.75 0 11-.966 1.15l-3.788-3.18a.747.747 0 01-.21-.285.75.75 0 01.17-.945l3.792-3.182a.75.75 0 011.057.093z" })); - function Ur() { - return Ur = Object.assign ? Object.assign.bind() : function(l) { + function Fr() { + return Fr = Object.assign ? Object.assign.bind() : function(l) { for (var o = 1; o < arguments.length; o++) { var s = arguments[o]; for (var c in s) ({}).hasOwnProperty.call(s, c) && (l[c] = s[c]); } return l; - }, Ur.apply(null, arguments); + }, Fr.apply(null, arguments); } - const Cs = ({ styles: l = {}, ...o }) => i.createElement("svg", Ur({ viewBox: "0 0 20 20", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { fill: "#4fa800", d: "M6.972 16.615a.997.997 0 01-.744-.292l-4.596-4.596a1 1 0 111.414-1.414l3.926 3.926 9.937-9.937a1 1 0 011.414 1.415L7.717 16.323a.997.997 0 01-.745.292z" })); + const Cs = ({ styles: l = {}, ...o }) => i.createElement("svg", Fr({ viewBox: "0 0 20 20", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { fill: "#4fa800", d: "M6.972 16.615a.997.997 0 01-.744-.292l-4.596-4.596a1 1 0 111.414-1.414l3.926 3.926 9.937-9.937a1 1 0 011.414 1.415L7.717 16.323a.997.997 0 01-.745.292z" })); T(4343); - const Ui = "Lock from Inspector (@ckeditor/ckeditor5-inspector)"; + const Fi = "Lock from Inspector (@ckeditor/ckeditor5-inspector)"; class so extends i.Component { constructor(o) { super(o), this.state = { isShiftKeyPressed: !1, wasEditorDataJustCopied: !1 }, this._keyDownHandler = this._handleKeyDown.bind(this), this._keyUpHandler = this._handleKeyUp.bind(this), this._readOnlyHandler = this._handleReadOnly.bind(this), this._editorDataJustCopiedTimeout = null; } render() { - return i.createElement("div", { className: "ck-inspector-editor-quick-actions" }, i.createElement(Et, { text: "Log editor", icon: i.createElement(Bt, null), isEnabled: !!this.props.editor, onClick: () => console.log(this.props.editor) }), this._getLogButton(), i.createElement(_a, { editor: this.props.editor }), i.createElement(Et, { text: "Toggle read only", icon: i.createElement(xa, null), isOn: this.props.isReadOnly, isEnabled: !!this.props.editor, onClick: this._readOnlyHandler }), i.createElement(Et, { text: "Destroy editor", icon: i.createElement(xs, null), isEnabled: !!this.props.editor, onClick: () => { + return i.createElement("div", { className: "ck-inspector-editor-quick-actions" }, i.createElement(Et, { text: "Log editor", icon: i.createElement($t, null), isEnabled: !!this.props.editor, onClick: () => console.log(this.props.editor) }), this._getLogButton(), i.createElement(_a, { editor: this.props.editor }), i.createElement(Et, { text: "Toggle read only", icon: i.createElement(xa, null), isOn: this.props.isReadOnly, isEnabled: !!this.props.editor, onClick: this._readOnlyHandler }), i.createElement(Et, { text: "Destroy editor", icon: i.createElement(xs, null), isEnabled: !!this.props.editor, onClick: () => { this.props.editor.destroy(); } })); } @@ -10533,20 +10607,20 @@ ${k}`); this.setState({ isShiftKeyPressed: !1 }); } _handleReadOnly() { - this.props.editor.isReadOnly ? this.props.editor.disableReadOnlyMode(Ui) : this.props.editor.enableReadOnlyMode(Ui); + this.props.editor.isReadOnly ? this.props.editor.disableReadOnlyMode(Fi) : this.props.editor.enableReadOnlyMode(Fi); } } - const Fi = _e(({ editors: l, currentEditorName: o, currentEditorGlobals: { isReadOnly: s } }) => ({ editor: l.get(o), isReadOnly: s }), {})(so); - function Fr() { - return Fr = Object.assign ? Object.assign.bind() : function(l) { + const Ui = _e(({ editors: l, currentEditorName: o, currentEditorGlobals: { isReadOnly: s } }) => ({ editor: l.get(o), isReadOnly: s }), {})(so); + function Ur() { + return Ur = Object.assign ? Object.assign.bind() : function(l) { for (var o = 1; o < arguments.length; o++) { var s = arguments[o]; for (var c in s) ({}).hasOwnProperty.call(s, c) && (l[c] = s[c]); } return l; - }, Fr.apply(null, arguments); + }, Ur.apply(null, arguments); } - const Vi = ({ styles: l = {}, ...o }) => i.createElement("svg", Fr({ viewBox: "0 0 19 19", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { d: "M17.03 6.47a.75.75 0 01.073.976l-.072.084-6.984 7a.75.75 0 01-.977.073l-.084-.072-7.016-7a.75.75 0 01.976-1.134l.084.072 6.485 6.47 6.454-6.469a.75.75 0 01.977-.073l.084.072z" })); + const Vi = ({ styles: l = {}, ...o }) => i.createElement("svg", Ur({ viewBox: "0 0 19 19", xmlns: "http://www.w3.org/2000/svg" }, o), i.createElement("path", { d: "M17.03 6.47a.75.75 0 01.073.976l-.072.084-6.984 7a.75.75 0 01-.977.073l-.084-.072-7.016-7a.75.75 0 01.976-1.134l.084.072 6.485 6.47 6.454-6.469a.75.75 0 01.977-.073l.084.072z" })); T(9938); const Sa = { position: "fixed", bottom: "0", left: "0", right: "0", top: "auto" }; class Ts extends i.Component { @@ -10558,14 +10632,14 @@ ${k}`); this.props.setHeight(g), Ca(g); } render() { - return this.props.isCollapsed ? (document.body.classList.remove("ck-inspector-body-expanded"), document.body.classList.add("ck-inspector-body-collapsed")) : (document.body.classList.remove("ck-inspector-body-collapsed"), document.body.classList.add("ck-inspector-body-expanded")), i.createElement(Ti, { bounds: "window", enableResizing: { top: !this.props.isCollapsed }, disableDragging: !0, minHeight: "100", maxHeight: "100%", style: Sa, className: ["ck-inspector", this.props.isCollapsed ? "ck-inspector_collapsed" : ""].join(" "), position: { x: 0, y: "100%" }, size: { width: "100%", height: this.props.isCollapsed ? 30 : this.props.height }, onResizeStop: this.handleInspectorResize }, i.createElement(to, { onTabChange: this.props.setActiveTab, contentBefore: i.createElement(Ns, { key: "docs" }), activeTab: this.props.activeTab, contentAfter: [i.createElement(Is, { key: "selector" }), i.createElement("span", { className: "ck-inspector-separator", key: "separator-a" }), i.createElement(Fi, { key: "quick-actions" }), i.createElement("span", { className: "ck-inspector-separator", key: "separator-b" }), i.createElement(ci, { key: "inspector-toggle" })] }, i.createElement(fs, { label: "Model" }), i.createElement(ga, { label: "View" }), i.createElement(Li, { label: "Commands" }), i.createElement(ks, { label: "Schema" }))); + return this.props.isCollapsed ? (document.body.classList.remove("ck-inspector-body-expanded"), document.body.classList.add("ck-inspector-body-collapsed")) : (document.body.classList.remove("ck-inspector-body-collapsed"), document.body.classList.add("ck-inspector-body-expanded")), i.createElement(Ti, { bounds: "window", enableResizing: { top: !this.props.isCollapsed }, disableDragging: !0, minHeight: "100", maxHeight: "100%", style: Sa, className: ["ck-inspector", this.props.isCollapsed ? "ck-inspector_collapsed" : ""].join(" "), position: { x: 0, y: "100%" }, size: { width: "100%", height: this.props.isCollapsed ? 30 : this.props.height }, onResizeStop: this.handleInspectorResize }, i.createElement(to, { onTabChange: this.props.setActiveTab, contentBefore: i.createElement(Ns, { key: "docs" }), activeTab: this.props.activeTab, contentAfter: [i.createElement(Is, { key: "selector" }), i.createElement("span", { className: "ck-inspector-separator", key: "separator-a" }), i.createElement(Ui, { key: "quick-actions" }), i.createElement("span", { className: "ck-inspector-separator", key: "separator-b" }), i.createElement(ci, { key: "inspector-toggle" })] }, i.createElement(fs, { label: "Model" }), i.createElement(ga, { label: "View" }), i.createElement(Li, { label: "Commands" }), i.createElement(ks, { label: "Schema" }))); } componentWillUnmount() { document.body.classList.remove("ck-inspector-body-expanded"), document.body.classList.remove("ck-inspector-body-collapsed"); } } const Os = _e(({ editors: l, currentEditorName: o, ui: { isCollapsed: s, height: c, activeTab: g } }) => ({ isCollapsed: s, height: c, editors: l, currentEditorName: o, activeTab: g }), { toggleIsCollapsed: Wr, setHeight: function(l) { - return { type: Bn, newHeight: l }; + return { type: $n, newHeight: l }; }, setEditors: qr, setCurrentEditorName: _o, setActiveTab: Eo })(Ts); class Ns extends i.Component { render() { @@ -10602,83 +10676,83 @@ ${k}`); document.body.style.setProperty("--ck-inspector-height", l); } T(8704), window.CKEDITOR_INSPECTOR_VERSION = "5.0.0"; - class Be { + class $e { constructor() { Ye.warn("[CKEditorInspector] Whoops! Looks like you tried to create an instance of the CKEditorInspector class. To attach the inspector, use the static CKEditorInspector.attach( editor ) method instead. For the latest API, please refer to https://github.com/ckeditor/ckeditor5-inspector/blob/master/README.md. "); } static attach(...o) { const { CKEDITOR_VERSION: s } = window; if (s) { - const [b] = s.split(".").map(Number); - b < 34 && Ye.warn("[CKEditorInspector] The inspector requires using CKEditor 5 in version 34 or higher. If you cannot update CKEditor 5, consider downgrading the major version of the inspector to version 3."); + const [y] = s.split(".").map(Number); + y < 34 && Ye.warn("[CKEditorInspector] The inspector requires using CKEditor 5 in version 34 or higher. If you cannot update CKEditor 5, consider downgrading the major version of the inspector to version 3."); } else Ye.warn("[CKEditorInspector] Could not determine a version of CKEditor 5. Some of the functionalities may not work as expected."); const { editors: c, options: g } = qn(o); - for (const b in c) { - const x = c[b]; - Ye.group("%cAttached the inspector to a CKEditor 5 instance. To learn more, visit https://ckeditor.com/docs/ckeditor5.", "font-weight: bold;"), Ye.log(`Editor instance "${b}"`, x), Ye.groupEnd(), Be._editors.set(b, x), x.on("destroy", () => { - Be.detach(b); - }), Be._mount(g), Be._updateEditorsState(); + for (const y in c) { + const x = c[y]; + Ye.group("%cAttached the inspector to a CKEditor 5 instance. To learn more, visit https://ckeditor.com/docs/ckeditor5.", "font-weight: bold;"), Ye.log(`Editor instance "${y}"`, x), Ye.groupEnd(), $e._editors.set(y, x), x.on("destroy", () => { + $e.detach(y); + }), $e._mount(g), $e._updateEditorsState(); } return Object.keys(c); } static attachToAll(o) { const s = document.querySelectorAll(".ck.ck-content.ck-editor__editable"), c = []; for (const g of s) { - const b = g.ckeditorInstance; - b && !Be._isAttachedTo(b) && c.push(...Be.attach(b, o)); + const y = g.ckeditorInstance; + y && !$e._isAttachedTo(y) && c.push(...$e.attach(y, o)); } return c; } static detach(o) { - Be._wrapper && (Be._editors.delete(o), Be._updateEditorsState()); + $e._wrapper && ($e._editors.delete(o), $e._updateEditorsState()); } static destroy() { - if (!Be._wrapper) return; - u.unmountComponentAtNode(Be._wrapper), Be._editors.clear(), Be._wrapper.remove(); - const o = Be._store.getState(), s = o.editors.get(o.currentEditorName); - s && Be._editorListener.stopListening(s), Be._editorListener = null, Be._wrapper = null, Be._store = null; + if (!$e._wrapper) return; + u.unmountComponentAtNode($e._wrapper), $e._editors.clear(), $e._wrapper.remove(); + const o = $e._store.getState(), s = o.editors.get(o.currentEditorName); + s && $e._editorListener.stopListening(s), $e._editorListener = null, $e._wrapper = null, $e._store = null; } static _updateEditorsState() { - Be._store.dispatch(qr(Be._editors)); + $e._store.dispatch(qr($e._editors)); } static _mount(o) { - if (Be._wrapper) return; - const s = Be._wrapper = document.createElement("div"); + if ($e._wrapper) return; + const s = $e._wrapper = document.createElement("div"); let c, g; - s.className = "ck-inspector-wrapper", document.body.appendChild(s), Be._editorListener = new Yr({ onModelChange() { - const b = Be._store; - b.getState().ui.isCollapsed || (b.dispatch(Nn()), b.dispatch(Lt())); + s.className = "ck-inspector-wrapper", document.body.appendChild(s), $e._editorListener = new Yr({ onModelChange() { + const y = $e._store; + y.getState().ui.isCollapsed || (y.dispatch(Nn()), y.dispatch(Lt())); }, onViewRender() { - const b = Be._store; - b.getState().ui.isCollapsed || b.dispatch(He()); + const y = $e._store; + y.getState().ui.isCollapsed || y.dispatch(He()); }, onReadOnlyChange() { - Be._store.dispatch({ type: sr }); - } }), Be._store = y(oa, { editors: Be._editors, currentEditorName: sn(Be._editors), currentEditorGlobals: {}, ui: { isCollapsed: o.isCollapsed } }), Be._store.subscribe(() => { - const b = Be._store.getState(), x = b.editors.get(b.currentEditorName); - c !== x && (c && Be._editorListener.stopListening(c), x && Be._editorListener.startListening(x), c = x); - }), Be._store.subscribe(() => { - const b = Be._store, x = b.getState().ui.isCollapsed, z = g && !x; - g = x, z && (b.dispatch(Nn()), b.dispatch(Lt()), b.dispatch(He())); - }), u.render(i.createElement(ee, { store: Be._store }, i.createElement(Os, null)), s); + $e._store.dispatch({ type: sr }); + } }), $e._store = b(oa, { editors: $e._editors, currentEditorName: sn($e._editors), currentEditorGlobals: {}, ui: { isCollapsed: o.isCollapsed } }), $e._store.subscribe(() => { + const y = $e._store.getState(), x = y.editors.get(y.currentEditorName); + c !== x && (c && $e._editorListener.stopListening(c), x && $e._editorListener.startListening(x), c = x); + }), $e._store.subscribe(() => { + const y = $e._store, x = y.getState().ui.isCollapsed, z = g && !x; + g = x, z && (y.dispatch(Nn()), y.dispatch(Lt()), y.dispatch(He())); + }), u.render(i.createElement(ee, { store: $e._store }, i.createElement(Os, null)), s); } static _isAttachedTo(o) { - return [...Be._editors.values()].includes(o); + return [...$e._editors.values()].includes(o); } } - Be._editors = /* @__PURE__ */ new Map(), Be._wrapper = null; - })(), Z = Z.default; + $e._editors = /* @__PURE__ */ new Map(), $e._wrapper = null; + })(), X = X.default; })()); })(_l)), _l.exports; } -var $u = Bu(); -const Wu = /* @__PURE__ */ Hu($u); +var Bu = $u(); +const Wu = /* @__PURE__ */ Hu(Bu); /** * @link https://craftcms.com/ * @copyright Copyright (c) Pixel & Tonic, Inc. * @license GPL-3.0-or-later */ const qu = function(Te) { - const _ = Te.plugins.get(zc), E = $(Te.ui.view.element), O = $(Te.sourceElement), T = `ckeditor${Math.floor(Math.random() * 1e9)}`, Z = [ + const _ = Te.plugins.get(zc), E = $(Te.ui.view.element), O = $(Te.sourceElement), T = `ckeditor${Math.floor(Math.random() * 1e9)}`, X = [ "keypress", "keyup", "change", @@ -10694,7 +10768,7 @@ const qu = function(Te) { ); if (_.isSourceEditingMode) { let u = i.attr("data-value"); - i.on(Z, () => { + i.on(X, () => { u !== (u = i.attr("data-value")) && O.val(u); }); } else @@ -10726,17 +10800,17 @@ const qu = function(Te) { }, Qu = function(Te, _) { let E = null; const O = Te.editing.view.document, T = Te.plugins.get("ClipboardPipeline"); - O.on("clipboardOutput", (Z, i) => { + O.on("clipboardOutput", (X, i) => { E = Te.id; - }), O.on("clipboardInput", async (Z, i) => { + }), O.on("clipboardInput", async (X, i) => { let u = i.dataTransfer.getData("text/html"); if (u && u.includes(" H.value) : (Craft.cp.displayError( + if (!(E === Te.id && !R.test(b))) { + let F = null; + E !== Te.id && (_.includes(Au) ? F = Te.config.get("entryTypeOptions").map((H) => H.value) : (Craft.cp.displayError( Craft.t( "ckeditor", "This field doesn’t allow nested entries." @@ -10764,7 +10838,7 @@ const qu = function(Te) { data: { entryId: ee, siteId: d, - targetEntryTypeIds: U, + targetEntryTypeIds: F, targetOwnerId: C, targetLayoutElementUid: m } @@ -10791,10 +10865,10 @@ const qu = function(Te) { return Craft.showCkeditorInspector && Craft.userIsAdmin && Wu.attach(E), E.editing.view.change((O) => { const T = E.editing.view.document.getRoot(); if (typeof _.accessibleFieldName < "u" && _.accessibleFieldName.length) { - let Z = T.getAttribute("aria-label"); + let X = T.getAttribute("aria-label"); O.setAttribute( "aria-label", - _.accessibleFieldName + ", " + Z, + _.accessibleFieldName + ", " + X, T ); } diff --git a/src/web/assets/ckeditor/src/entries/entriescommand.js b/src/web/assets/ckeditor/src/entries/entriescommand.js index 17a5d66a..34685fed 100644 --- a/src/web/assets/ckeditor/src/entries/entriescommand.js +++ b/src/web/assets/ckeditor/src/entries/entriescommand.js @@ -4,6 +4,13 @@ export default class CraftEntriesCommand extends Command { execute(options) { const editor = this.editor; const selection = editor.model.document.selection; + const hasSelection = !selection.isCollapsed && selection.getFirstRange(); + if (hasSelection) { + const selectedElement = selection.getSelectedElement(); + editor.execute('insertParagraph', { + position: editor.model.createPositionAfter(selectedElement), + }); + } editor.model.change((writer) => { // Create a element with the `data-entry-id` attribute @@ -22,12 +29,6 @@ export default class CraftEntriesCommand extends Command { } refresh() { - const model = this.editor.model; - const selection = model.document.selection; - - // disable craftEntries button if a selection is made in the editor - const hasSelection = !selection.isCollapsed && selection.getFirstRange(); - - this.isEnabled = !hasSelection; + this.isEnabled = true; } } diff --git a/src/web/assets/ckeditor/src/image/imageinsert/imageinsertui.js b/src/web/assets/ckeditor/src/image/imageinsert/imageinsertui.js index ee5ca9af..bce9fc1c 100644 --- a/src/web/assets/ckeditor/src/image/imageinsert/imageinsertui.js +++ b/src/web/assets/ckeditor/src/image/imageinsert/imageinsertui.js @@ -21,13 +21,22 @@ export default class CraftImageInsertUI extends ImageInsertUI { init() { // Make sure there are linked volumes - if (!this._assetSources) { + if (!this._imageSources) { console.warn( 'Omitting the "image" CKEditor toolbar button, because there aren’t any permitted volumes.', ); return; } + if (this._imageMode === 'entries') { + if (!this._imageEntryTypeId || !this._imageFieldHandle) { + console.warn( + 'Omitting the "image" CKEditor toolbar button, because no image field was selected.', + ); + return; + } + } + // Register `insertImage` dropdown and add `imageInsert` dropdown as an alias for consistency with ImageInsertUI const componentFactory = this.editor.ui.componentFactory; const componentCreator = (locale) => { @@ -39,8 +48,36 @@ export default class CraftImageInsertUI extends ImageInsertUI { this._attachUploader(); } - get _assetSources() { - return this.editor.config.get('assetSources'); + get _imageMode() { + return this.editor.config.get('imageMode'); + } + + get _imageSources() { + return this.editor.config.get('imageSources'); + } + + get _imageModalSettings() { + return this.editor.config.get('imageModalSettings') ?? {}; + } + + get _imageEntryTypeId() { + return this.editor.config.get('imageEntryTypeId'); + } + + get _imageFieldHandle() { + return this.editor.config.get('imageFieldHandle'); + } + + /** + * Returns Craft.ElementEditor instance that the CKEditor field belongs to. + * + * @returns {*} + */ + get _elementEditor() { + const $editorContainer = $(this.editor.ui.view.element).closest( + 'form,.lp-editor-container', + ); + return $editorContainer.data('elementEditor'); } _createToolbarImageButton(locale) { @@ -58,7 +95,7 @@ export default class CraftImageInsertUI extends ImageInsertUI { } _showImageSelectModal() { - const sources = this._assetSources; + const sources = this._imageSources; const editor = this.editor; const config = editor.config; const criteria = Object.assign({}, config.get('assetSelectionCriteria'), { @@ -66,15 +103,16 @@ export default class CraftImageInsertUI extends ImageInsertUI { }); Craft.createElementSelectorModal('craft\\elements\\Asset', { + ...this._imageModalSettings, storageKey: `ckeditor:${this.pluginName}:'craft\\elements\\Asset'`, sources, criteria, defaultSiteId: config.get('elementSiteId'), transforms: config.get('transforms'), - multiSelect: true, autoFocusSearchBox: false, + multiSelect: true, onSelect: (assets, transform) => { - this._processAssetUrls(assets, transform).then(() => { + this._processSelectedAssets(assets, transform).then(() => { editor.editing.view.focus(); }); }, @@ -85,11 +123,18 @@ export default class CraftImageInsertUI extends ImageInsertUI { }); } - async _processAssetUrls(assets, transform) { + async _processSelectedAssets(assets, transform) { if (!assets.length) { return; } + if (this._imageMode === 'entries') { + for (const asset of assets) { + await this._createImageEntry(asset.id); + } + return; + } + const editor = this.editor; const defaultTransform = editor.config.get('defaultTransform'); const urls = []; @@ -114,6 +159,55 @@ export default class CraftImageInsertUI extends ImageInsertUI { editor.execute('insertImage', {source: urls}); } + async _createImageEntry(assetId) { + const editor = this.editor; + const elementEditor = this._elementEditor; + const baseInputName = $(editor.sourceElement).attr('name'); + + // mark as dirty + if (elementEditor && baseInputName) { + await elementEditor.setFormValue(baseInputName, '*'); + } + + const nestedElementAttributes = editor.config.get( + 'nestedElementAttributes', + ); + const params = { + ...nestedElementAttributes, + typeId: this._imageEntryTypeId, + }; + + if (elementEditor) { + await elementEditor.markDeltaNameAsModified(editor.sourceElement.name); + // replace the owner ID with the new one, maybe? + params.ownerId = elementEditor.getDraftElementId( + nestedElementAttributes.ownerId, + ); + } + + let response; + try { + response = await Craft.sendActionRequest( + 'POST', + 'ckeditor/ckeditor/create-image-entry', + { + data: { + ...params, + assetIds: [assetId], + }, + }, + ); + } catch (e) { + Craft.cp.displayError(); + throw e; + } + + editor.commands.execute('insertEntry', { + entryId: response.data.entryId, + siteId: response.data.siteId, + }); + } + _buildAssetUrl(assetId, assetUrl, transform) { return `${assetUrl}#asset:${assetId}:${ transform ? 'transform:' + transform : 'url' @@ -180,7 +274,7 @@ export default class CraftImageInsertUI extends ImageInsertUI { this.$fileInput = $('', { type: 'file', class: 'hidden', - multiple: false, + multiple: true, }).insertAfter(editor.sourceElement); this.uploader = Craft.createUploader(null, this.$container, { @@ -255,6 +349,12 @@ export default class CraftImageInsertUI extends ImageInsertUI { const asset = event instanceof CustomEvent ? event.detail : data.result; this.progressBar.hideProgressBar(); this.$container.removeClass('uploading'); + + if (this._imageMode === 'entries') { + await this._createImageEntry(asset.assetId); + return; + } + const defaultTransform = this.editor.config.get('defaultTransform'); const hasTransform = this._isTransformUrl(asset.url); let url; diff --git a/src/web/assets/fieldsettings/dist/fieldsettings.js b/src/web/assets/fieldsettings/dist/fieldsettings.js index 1bbdcb63..4d7fbf17 100644 --- a/src/web/assets/fieldsettings/dist/fieldsettings.js +++ b/src/web/assets/fieldsettings/dist/fieldsettings.js @@ -28,7 +28,7 @@ const ToolbarBuilder = Garnish.Base.extend({ const o = document.createElement("DIV"), r = document.createElement("DIV"); o.appendChild(r), create(r, { linkOptions: [{ elementType: "craft\\elements\\Asset" }], - assetSources: ["*"], + imageSources: ["*"], entryTypeOptions: [{ label: "fake", value: "fake" }], plugins: n }).then((a) => { diff --git a/src/web/assets/fieldsettings/dist/images/entries.svg b/src/web/assets/fieldsettings/dist/images/entries.svg new file mode 100644 index 00000000..7750593b --- /dev/null +++ b/src/web/assets/fieldsettings/dist/images/entries.svg @@ -0,0 +1,23 @@ + + + entries + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/web/assets/fieldsettings/dist/images/img.svg b/src/web/assets/fieldsettings/dist/images/img.svg new file mode 100644 index 00000000..8f75a851 --- /dev/null +++ b/src/web/assets/fieldsettings/dist/images/img.svg @@ -0,0 +1,25 @@ + + + img + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/web/assets/fieldsettings/src/ToolbarBuilder.js b/src/web/assets/fieldsettings/src/ToolbarBuilder.js index eead3bcc..be5174f5 100644 --- a/src/web/assets/fieldsettings/src/ToolbarBuilder.js +++ b/src/web/assets/fieldsettings/src/ToolbarBuilder.js @@ -42,7 +42,7 @@ export default Garnish.Base.extend({ create(editorElement, { linkOptions: [{elementType: 'craft\\elements\\Asset'}], - assetSources: ['*'], + imageSources: ['*'], entryTypeOptions: [{label: 'fake', value: 'fake'}], plugins, }) diff --git a/src/web/assets/fieldsettings/src/images/entries.svg b/src/web/assets/fieldsettings/src/images/entries.svg new file mode 100644 index 00000000..7750593b --- /dev/null +++ b/src/web/assets/fieldsettings/src/images/entries.svg @@ -0,0 +1,23 @@ + + + entries + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/web/assets/fieldsettings/src/images/img.svg b/src/web/assets/fieldsettings/src/images/img.svg new file mode 100644 index 00000000..8f75a851 --- /dev/null +++ b/src/web/assets/fieldsettings/src/images/img.svg @@ -0,0 +1,25 @@ + + + img + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/web/assets/fieldsettings/vite.config.js b/src/web/assets/fieldsettings/vite.config.js index 37080d93..fc02c1b0 100644 --- a/src/web/assets/fieldsettings/vite.config.js +++ b/src/web/assets/fieldsettings/vite.config.js @@ -1,5 +1,6 @@ import {defineConfig} from 'vite'; import {resolve} from 'path'; +import {viteStaticCopy} from 'vite-plugin-static-copy'; export default defineConfig({ build: { @@ -20,4 +21,14 @@ export default defineConfig({ }, }, }, + plugins: [ + viteStaticCopy({ + targets: [ + { + src: resolve(__dirname, 'src/images/*'), + dest: resolve(__dirname, 'dist/images/'), + }, + ], + }), + ], }); diff --git a/src/web/assets/fieldsettings/vite/ckeconfig.js b/src/web/assets/fieldsettings/vite/ckeconfig.js index e5207d41..825f1127 100644 --- a/src/web/assets/fieldsettings/vite/ckeconfig.js +++ b/src/web/assets/fieldsettings/vite/ckeconfig.js @@ -31,7 +31,7 @@ const ToolbarBuilder = Garnish.Base.extend({ (a.appendChild(c), create(c, { linkOptions: [{elementType: 'craft\\elements\\Asset'}], - assetSources: ['*'], + imageSources: ['*'], entryTypeOptions: [{label: 'fake', value: 'fake'}], }).then((h) => { const g = h.ui.componentFactory,