Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/js/ui/bottomsheet/dist/ |
Upload File : |
{"version":3,"file":"bottomsheet.bundle.js","sources":["../src/touchdraglistener.js","../src/bottomsheet.js"],"sourcesContent":["import { Type } from 'main.core';\n\nexport default class TouchDragListener\n{\n\tconstructor({\n\t\telement,\n\t\ttouchStartCallback,\n\t\ttouchEndCallback,\n\t\ttouchMoveCallback\n\t})\n\t{\n\t\tthis.element = Type.isDomNode(element) ? element : null;\n\t\tthis.touchStartCallback = touchStartCallback;\n\t\tthis.touchEndCallback = touchEndCallback;\n\t\tthis.touchMoveCallback = touchMoveCallback;\n\n\t\tthis.active = false;\n\t\tthis.currentY = null;\n\t\tthis.initialY = null;\n\t\tthis.yOffset = 0;\n\n\t\tthis.#bindEvents();\n\t}\n\n\t#bindEvents()\n\t{\n\t\tif (this.element)\n\t\t{\n\t\t\tthis.element.addEventListener('touchstart', this.#dragStart.bind(this));\n\t\t\tthis.element.addEventListener('touchend', this.#dragEnd.bind(this));\n\t\t\tthis.element.addEventListener('touchmove', this.#dragMove.bind(this));\n\t\t}\n\t}\n\n\t#dragStart(ev)\n\t{\n\t\tthis.active = true;\n\t\tthis.element.classList.add('--ondrag');\n\n\t\tif (ev.type === 'touchstart')\n\t\t{\n\t\t\tthis.initialY = ev.touches[0].clientY - this.yOffset;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tthis.initialY = ev.clientY - this.yOffset;\n\t\t}\n\n\t\tif (!this.touchStartCallback)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tthis.touchStartCallback({\n\t\t\telement: this.element,\n\t\t\tactive: this.active,\n\t\t\tcurrentY: this.currentY,\n\t\t\tinitialY: this.initialY,\n\t\t\tyOffset: this.offSetY\n\t\t});\n\t}\n\n\t#dragEnd(ev)\n\t{\n\t\tthis.active = true;\n\t\tthis.element.classList.remove('--ondrag');\n\n\t\tthis.yOffset = 0;\n\n\t\tthis.initialY = this.currentY;\n\n\t\tif (!this.touchEndCallback) return;\n\n\t\tthis.touchEndCallback({\n\t\t\telement: this.element,\n\t\t\tactive: this.active,\n\t\t\tcurrentY: this.currentY,\n\t\t\tinitialY: this.initialY,\n\t\t\tyOffset: this.offSetY\n\t\t});\n\t}\n\t\n\t#dragMove(ev)\n\t{\n\t\tif (!this.active)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tev.preventDefault();\n\n\t\tif (ev.type === 'touchmove')\n\t\t{\n\t\t\tthis.currentY = ev.touches[0].clientY - this.initialY;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tthis.currentY = ev.clientY - this.initialY;\n\t\t}\n\n\t\tthis.yOffset = this.currentX;\n\n\t\tif (!this.touchMoveCallback)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tthis.touchMoveCallback({\n\t\t\telement: this.element,\n\t\t\tactive: this.active,\n\t\t\tcurrentY: this.currentY,\n\t\t\tinitialY: this.initialY,\n\t\t\tyOffset: this.offSetY\n\t\t});\n\t}\n}","import { Type, Tag, Dom, Loc } from 'main.core';\nimport TouchDragListener from './touchdraglistener';\n\nimport 'ui.design-tokens';\nimport './style.css';\n\nexport default class BottomSheet\n{\n\tconstructor({\n\t\tcontent,\n\t\thelp,\n\t\tclassName,\n\t\tpadding\n\t})\n\t{\n\t\tthis.content = Type.isDomNode(content) ? content : null;\n\t\tthis.className = Type.isString(className) ? className : '';\n\t\tthis.padding = Type.isString(padding) || Type.isNumber(padding) ? padding : null;\n\n\t\tthis.help = null;\n\t\tswitch (true)\n\t\t{\n\t\t\tcase Type.isString(help):\n\t\t\t\tthis.help = help;\n\t\t\t\tbreak;\n\t\t\tcase Type.isFunction(help):\n\t\t\t\tthis.help = help;\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthis.layout = {\n\t\t\twrapper: null,\n\t\t\tcontainer: null,\n\t\t\tcontent: null,\n\t\t\toverlay: null,\n\t\t\tclose: null,\n\t\t\thelp: null\n\t\t};\n\n\t\tthis.halfOfHeight = 0;\n\t\tthis.currentHeight = null;\n\n\t\tthis.sheetListener = new TouchDragListener({\n\t\t\telement: this.#getPanel(),\n\t\t\ttouchStartCallback: ({element, active, initialY, currentY, yOffset}) => {\n\t\t\t\telement.style.setProperty('--translateY', 'translateY(0)');\n\t\t\t\telement.style.setProperty('transition', 'unset');\n\t\t\t},\n\t\t\ttouchEndCallback: ({element, active, initialY, currentY, yOffset}) => {\n\t\t\t\telement.style.setProperty(\n\t\t\t\t\t'transition',\n\t\t\t\t\t'transform .3s'\n\t\t\t\t);\n\t\t\t\telement.style.setProperty(\n\t\t\t\t\t'--translateY',\n\t\t\t\t\t'translateY(' + currentY + 'px)'\n\t\t\t\t);\n\n\t\t\t\tif (parseInt(currentY) > this.halfOfHeight)\n\t\t\t\t{\n\t\t\t\t\tthis.close();\n\t\t\t\t}\n\t\t\t},\n\t\t\ttouchMoveCallback: ({element, active, initialY, currentY, yOffset}) => {\n\t\t\t\t\n\t\t\t\tif (currentY <= 0)\n\t\t\t\t{\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tif (currentY <= -40)\n\t\t\t\t{\n\t\t\t\t\tcurrentY = -41 + currentY / 10;\n\t\t\t\t}\n\n\t\t\t\telement.style.setProperty(\n\t\t\t\t\t'--translateY',\n\t\t\t\t\t'translateY(' + currentY + 'px)'\n\t\t\t\t);\n\t\t\t}\n\t\t});\n\n\t\tif (this.content)\n\t\t{\n\t\t\tthis.setContent(this.content);\n\t\t}\n\t}\n\n\t#getOverlay()\n\t{\n\t\tif (!this.layout.overlay)\n\t\t{\n\t\t\tthis.layout.overlay = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet__overlay\"></div>\n\t\t\t`;\n\n\t\t\tthis.layout.overlay.addEventListener('click', this.close.bind(this));\n\t\t}\n\n\t\treturn this.layout.overlay;\n\t}\n\n\t#getHelp()\n\t{\n\t\tif (!this.layout.help)\n\t\t{\n\t\t\tif (Type.isString(this.help))\n\t\t\t{\n\t\t\t\tthis.layout.help = Tag.render`\n\t\t\t\t\t<a href=\"${this.help}\" class=\"ui-bottomsheet__panel-control--item --cursor-pointer\">\n\t\t\t\t\t\t<span class=\"ui-bottomsheet__panel-control--item-text\">${Loc.getMessage('UI_BOTTOMSHEET_HELP')}</span>\n\t\t\t\t\t</a>\n\t\t\t\t`;\n\t\t\t}\n\n\t\t\tif (Type.isFunction(this.help))\n\t\t\t{\n\t\t\t\tthis.layout.help = Tag.render`\n\t\t\t\t\t<div class=\"ui-bottomsheet__panel-control--item --cursor-pointer\">\n\t\t\t\t\t\t<div class=\"ui-bottomsheet__panel-control--item-text\">${Loc.getMessage('UI_BOTTOMSHEET_HELP')}</div>\n\t\t\t\t\t</div>\n\t\t\t\t`;\n\n\t\t\t\tthis.layout.help.addEventListener('click', ()=> {\n\t\t\t\t\tthis.help();\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\treturn this.layout.help;\n\t}\n\n\t#getClose()\n\t{\n\t\tif (!this.layout.close)\n\t\t{\n\t\t\tthis.layout.close = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet__panel-control--item --cursor-pointer --close\">\n\t\t\t\t\t<div class=\"ui-bottomsheet__panel-control--item-text\">${Loc.getMessage('UI_BOTTOMSHEET_CLOSE')}</div>\n\t\t\t\t</div>\n\t\t\t`;\n\n\t\t\tthis.layout.close.addEventListener('click', this.close.bind(this));\n\t\t}\n\n\t\treturn this.layout.close;\n\t}\n\n\t#getPanel()\n\t{\n\t\tif (!this.layout.container)\n\t\t{\n\t\t\tconst panelWrapper = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet__panel-wrapper\">\n\t\t\t\t\t${this.#getContent()}\n\t\t\t\t</div>\n\t\t\t`;\n\n\t\t\tif (this.padding || this.padding === 0)\n\t\t\t{\n\t\t\t\tlet padding;\n\n\t\t\t\tswitch(true)\n\t\t\t\t{\n\t\t\t\t\tcase Type.isString(this.padding):\n\t\t\t\t\t\tpadding = this.padding;\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase Type.isNumber(this.padding):\n\t\t\t\t\t\tpadding = this.padding + 'px';\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tpanelWrapper.style.setProperty(\n\t\t\t\t\t'padding',\n\t\t\t\t\tpadding\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tthis.layout.container = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet__panel\">\n\t\t\t\t\t<div class=\"ui-bottomsheet__panel-control\">\n\t\t\t\t\t\t${this.help ? this.#getHelp() : ''}\n\t\t\t\t\t\t<div class=\"ui-bottomsheet__panel-handler\"></div>\n\t\t\t\t\t\t${this.#getClose()}\n\t\t\t\t\t</div>\n\t\t\t\t\t${panelWrapper}\n\t\t\t\t</div>\n\t\t\t`;\n\t\t}\n\n\t\treturn this.layout.container;\n\t}\n\n\t#getContent()\n\t{\n\t\tif (!this.layout.content)\n\t\t{\n\t\t\tthis.layout.content = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet__panel-content\"></div>\n\t\t\t`;\n\t\t}\n\n\t\treturn this.layout.content;\n\t}\n\n\t#getWrapper()\n\t{\n\t\tif (!this.layout.wrapper)\n\t\t{\n\t\t\tthis.layout.wrapper = Tag.render`\n\t\t\t\t<div class=\"ui-bottomsheet ${this.className}\"></div>\n\t\t\t`;\n\t\t}\n\n\t\treturn this.layout.wrapper;\n\t}\n\t\n\tsetContent(content: HTMLElement)\n\t{\n\t\tif (Type.isDomNode(content))\n\t\t{\n\t\t\tDom.clean(this.#getContent());\n\t\t\tthis.#getContent().appendChild(content);\n\t\t}\n\n\t\tif (Type.isString(content))\n\t\t{\n\t\t\tDom.clean(this.#getContent());\n\t\t\tthis.#getContent().innerText = content;\n\t\t}\n\t}\n\n\tadjustPosition()\n\t{\n\n\t}\n\n\tadjustSize()\n\t{\n\t\tif (this.currentHeight !== this.#getPanel().offsetHeight)\n\t\t{\n\t\t\tlet currentHeight = this.currentHeight;\n\t\t\tlet newHeight = this.#getPanel().offsetHeight;\n\t\t\tthis.#getPanel().style.setProperty(\n\t\t\t\t'height',\n\t\t\t\tcurrentHeight + 'px'\n\t\t\t);\n\n\t\t\tsetTimeout(()=> {\n\t\t\t\tcurrentHeight = this.#getPanel().offsetHeight;\n\t\t\t\tthis.#getPanel().style.setProperty(\n\t\t\t\t\t'height',\n\t\t\t\t\tnewHeight + 'px'\n\t\t\t\t);\n\n\t\t\t\tconst adjustHeight = ()=> {\n\t\t\t\t\tthis.#getPanel().style.removeProperty(\n\t\t\t\t\t\t'height',\n\t\t\t\t\t\tnewHeight + 'px'\n\t\t\t\t\t);\n\t\t\t\t\tthis.#getPanel().removeEventListener('transitionend', adjustHeight)\n\t\t\t\t};\n\n\t\t\t\tthis.#getPanel().addEventListener('transitionend', adjustHeight);\n\n\t\t\t\tthis.currentHeight = newHeight;\n\t\t\t\tthis.halfOfHeight = this.currentHeight / 2;\n\t\t\t});\n\t\t}\n\t}\n\n\tclose()\n\t{\n\t\tif (this.#getWrapper().parentNode)\n\t\t{\n\t\t\tthis.#getPanel().classList.remove('--show');\n\t\t\tthis.#getOverlay().classList.remove('--show');\n\n\t\t\tconst animationProgress = () => {\n\t\t\t\tthis.#getWrapper().classList.remove('--show');\n\t\t\t\tthis.#getPanel().removeEventListener('transitionend', animationProgress);\n\t\t\t}\n\n\t\t\tthis.#getPanel().addEventListener('transitionend', animationProgress)\n\t\t}\n\t}\n\n\tshow()\n\t{\n\t\tif (!this.#getWrapper().parentNode)\n\t\t{\n\t\t\tthis.#getWrapper().appendChild(this.#getOverlay());\n\t\t\tthis.#getWrapper().appendChild(this.#getPanel());\n\t\t\tdocument.body.appendChild(this.#getWrapper());\n\t\t}\n\n\t\tthis.#getWrapper().classList.add('--show');\n\n\t\tsetTimeout(()=> {\n\t\t\tthis.currentHeight = this.#getPanel().offsetHeight;\n\t\t\tthis.halfOfHeight = this.currentHeight / 2;\n\t\t\tthis.#getPanel().classList.add('--show');\n\t\t\tthis.#getOverlay().classList.add('--show');\n\t\t});\n\t}\n}"],"names":["TouchDragListener","constructor","element","touchStartCallback","touchEndCallback","touchMoveCallback","Type","isDomNode","active","currentY","initialY","yOffset","addEventListener","bind","ev","classList","add","type","touches","clientY","offSetY","remove","preventDefault","currentX","BottomSheet","content","help","className","padding","isString","isNumber","isFunction","layout","wrapper","container","overlay","close","halfOfHeight","currentHeight","sheetListener","style","setProperty","parseInt","setContent","Dom","clean","appendChild","innerText","adjustPosition","adjustSize","offsetHeight","newHeight","setTimeout","adjustHeight","removeProperty","removeEventListener","parentNode","animationProgress","show","document","body","Tag","render","Loc","getMessage","panelWrapper"],"mappings":";;;;;CAAiC;CAAA;CAAA;CAAA;AAEjC,CAAe,MAAMA,iBAAiB,CACtC;GACCC,WAAW,CAAC;KACXC,OAAO;KACPC,kBAAkB;KAClBC,gBAAgB;KAChBC;IACA,EACD;KAAA;OAAA;;KAAA;OAAA;;KAAA;OAAA;;KAAA;OAAA;;KACC,IAAI,CAACH,OAAO,GAAGI,cAAI,CAACC,SAAS,CAACL,OAAO,CAAC,GAAGA,OAAO,GAAG,IAAI;KACvD,IAAI,CAACC,kBAAkB,GAAGA,kBAAkB;KAC5C,IAAI,CAACC,gBAAgB,GAAGA,gBAAgB;KACxC,IAAI,CAACC,iBAAiB,GAAGA,iBAAiB;KAE1C,IAAI,CAACG,MAAM,GAAG,KAAK;KACnB,IAAI,CAACC,QAAQ,GAAG,IAAI;KACpB,IAAI,CAACC,QAAQ,GAAG,IAAI;KACpB,IAAI,CAACC,OAAO,GAAG,CAAC;KAEhB,4CAAI;;CA8FN;CAAC,wBA1FA;GACC,IAAI,IAAI,CAACT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