{"version":3,"sources":["webpack:///./src/components/course_tree/node/LessonNode.vue?4ba9","webpack:///./src/components/course_tree/node/LessonNode.vue","webpack:///./src/components/course_tree/node/LessonNode.vue?539c"],"names":["_hoisted_1","key","class","_hoisted_2","_hoisted_3","_hoisted_4","_hoisted_5","style","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","_hoisted_11","_hoisted_12","_hoisted_13","_hoisted_14","_hoisted_15","xmlns","viewBox","_hoisted_16","d","_hoisted_17","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21","_hoisted_22","_hoisted_23","_hoisted_24","render","_ctx","_cache","$props","$setup","$data","$options","_component_router_link","_component_Timestamp","_component_Btn","_component_CopyToClipboard","node","state","LessonNodeState","DRAFT","isDraggable","PUBLISHED","to","name","params","nodeId","id","default","lessonTitle","_","creator","full_name","updatedOnDifferentDay","$t","value","modified","schedule_publish_at","canEdit","onClick","onEdit","variant","outline","tooltip","onDelete","permalink","comment_count","mixins","props","type","Object","required","data","emits","methods","this","$emit","computed","title","bodyPreview","body","Date","created","components","ProcessedTextFragment","Timestamp","Btn","CopyToClipboard","__exports__"],"mappings":"yIAEMA,EAAa,CACjBC,IAAK,EACLC,MAAO,oLAEHC,EAAa,CAAED,MAAO,kCACtBE,EAAa,CAAEF,MAAO,qBACtBG,EAAa,CAAEH,MAAO,0CACtBI,EAAa,CACjBC,MAAO,CAAC,cAAc,QACtBL,MAAO,2DAEHM,EAAa,CACjBD,MAAO,CAAC,cAAc,QACtBL,MAAO,qDAEHO,EAAa,CAAEP,MAAO,yBACtBQ,EAAa,CACjBT,IAAK,EACLC,MAAO,gBAEHS,EAAa,CACjBV,IAAK,EACLC,MAAO,qBACPK,MAAO,CAAC,eAAe,QAEnBK,EAAc,CAAEV,MAAO,0HACvBW,EAAc,CAClBZ,IAAK,EACLC,MAAO,mBAEHY,EAAc,CAClBb,IAAK,EACLC,MAAO,uCAEHa,EAAc,CAAEb,MAAO,mBACvBc,EAAc,CAAEd,M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CACLgC,KAAMC,OACNC,UAAU,IAER,QAGJC,KAX8B,WAY7B,MAAO,CACNjC,gBAAA,SAGFkC,MAAO,kBACH,QAEJC,QAAS,CACRd,OADQ,WAEPe,KAAKC,MAAM,WAAYD,KAAKtC,OAE7B2B,SAJQ,WAKPW,KAAKC,MAAM,aAAcD,KAAKtC,QAGhCwC,SAAU,CACT5B,YADS,WAER,OAAO0B,KAAKtC,KAAKyC,OAAS,eAAE,+BAE7BC,YAJS,WAKR,OAAOJ,KAAKtC,KAAK2C,MAElB3B,sBAPS,WAQR,OAAQ,qBAAQ,IAAI4B,KAAKN,KAAKtC,KAAK6C,SAAU,IAAID,KAAKN,KAAKtC,KAAKmB,aAIlE2B,WAAY,CAAEC,wBAAA,KAAuBC,YAAA,KAAWC,MAAA,KAAKC,kBAAA,Q,qBC7CtD,MAAMC,EAA2B,IAAgB,EAAQ,CAAC,CAAC,SAAS9D,KAErD","file":"js/chunk-2d0d69ad.39dc5677.js","sourcesContent":["import { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, resolveComponent as _resolveComponent, withCtx as _withCtx, createVNode as _createVNode, createBlock as _createBlock } from \"vue\"\n\nconst _hoisted_1 = {\n key: 0,\n class: \"opacity-0 group-hover:opacity-50 transition-opacity duration-100 ease absolute top-1/2 transform -translate-y-1/2 left-0 text-lg cursor-move drag-handle material-icons-outlined\"\n}\nconst _hoisted_2 = { class: \"flex flex-wrap md:items-center\" }\nconst _hoisted_3 = { class: \"flex items-center\" }\nconst _hoisted_4 = { class: \"flex flex-col -space-y-1 md:-space-y-2\" }\nconst _hoisted_5 = {\n style: {\"line-height\":\"0.95\"},\n class: \"md:block hidden mb-2 hover:text-primary hover:underline\"\n}\nconst _hoisted_6 = {\n style: {\"line-height\":\"0.95\"},\n class: \"mb-2 md:hidden hover:text-primary hover:underline\"\n}\nconst _hoisted_7 = { class: \"flex flex-wrap ml-0.5\" }\nconst _hoisted_8 = {\n key: 0,\n class: \"text-sm mr-2\"\n}\nconst _hoisted_9 = {\n key: 1,\n class: \"text-sm text-muted\",\n style: {\"margin-right\":\"3px\"}\n}\nconst _hoisted_10 = { class: \"group-hover:opacity-100 transition-opacity duration-100 ease opacity-50 ml-auto flex md:flex-row flex-col items-center\" }\nconst _hoisted_11 = {\n key: 0,\n class: \"text-muted mr-4\"\n}\nconst _hoisted_12 = {\n key: 0,\n class: \"flex items-center space-x-1 text-sm\"\n}\nconst _hoisted_13 = { class: \"md:block hidden\" }\nconst _hoisted_14 = { class: \"block md:hidden\" }\nconst _hoisted_15 = {\n style: {\"width\":\"20px\",\"fill\":\"currentColor\"},\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 24 24\"\n}\nconst _hoisted_16 = /*#__PURE__*/_createElementVNode(\"path\", { d: \"M15,13H16.5V15.82L18.94,17.23L18.19,18.53L15,16.69V13M19,8H5V19H9.67C9.24,18.09 9,17.07 9,16A7,7 0 0,1 16,9C17.07,9 18.09,9.24 19,9.67V8M5,21C3.89,21 3,20.1 3,19V5C3,3.89 3.89,3 5,3H6V1H8V3H16V1H18V3H19A2,2 0 0,1 21,5V11.1C22.24,12.36 23,14.09 23,16A7,7 0 0,1 16,23C14.09,23 12.36,22.24 11.1,21H5M16,11.15A4.85,4.85 0 0,0 11.15,16C11.15,18.68 13.32,20.85 16,20.85A4.85,4.85 0 0,0 20.85,16C20.85,13.32 18.68,11.15 16,11.15Z\" }, null, -1)\nconst _hoisted_17 = [\n _hoisted_16\n]\nconst _hoisted_18 = {\n key: 1,\n class: \"md:block hidden\"\n}\nconst _hoisted_19 = { class: \"flex\" }\nconst _hoisted_20 = /*#__PURE__*/_createElementVNode(\"span\", { class: \"text-xl material-icons\" }, \" edit \", -1)\nconst _hoisted_21 = /*#__PURE__*/_createElementVNode(\"span\", { class: \"text-xl material-icons\" }, \" delete \", -1)\nconst _hoisted_22 = {\n key: 1,\n class: \"ml-12 pl-1 mt-2 -mb-1\"\n}\nconst _hoisted_23 = /*#__PURE__*/_createElementVNode(\"span\", {\n class: \"material-icons-outlined text-muted\",\n style: {\"margin-bottom\":\"-1px\",\"font-size\":\"16px !important\",\"text-decoration\":\"none !important\"}\n}, \"question_answer\", -1)\nconst _hoisted_24 = { class: \"text-muted hover:underline\" }\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_router_link = _resolveComponent(\"router-link\")!\n const _component_Timestamp = _resolveComponent(\"Timestamp\")!\n const _component_Btn = _resolveComponent(\"Btn\")!\n const _component_CopyToClipboard = _resolveComponent(\"CopyToClipboard\")!\n\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([{ 'bg-light': _ctx.node.state === _ctx.LessonNodeState.DRAFT }, \"group card card-border card-hoverable hover-shadow-elevation hover:border-transparent relative\"])\n }, [\n (_ctx.isDraggable)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \" drag_indicator \"))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"flex rounded-full mr-3\", {\n\t\t\t\t\t\t'bg-gray-200': _ctx.node.state === _ctx.LessonNodeState.DRAFT,\n\t\t\t\t\t\t'bg-primary bg-opacity-15': _ctx.node.state === _ctx.LessonNodeState.PUBLISHED,\n\t\t\t\t\t}]),\n style: {\"min-width\":\"2.5rem\",\"max-width\":\"2.5rem\",\"min-height\":\"2.5rem\",\"max-height\":\"2.5rem\"}\n }, [\n _createElementVNode(\"span\", {\n style: {\"font-size\":\"28px !important\"},\n class: _normalizeClass([{\n\t\t\t\t\t\t\t'text-gray-500': _ctx.node.state === _ctx.LessonNodeState.DRAFT,\n\t\t\t\t\t\t\t'text-primary': _ctx.node.state === _ctx.LessonNodeState.PUBLISHED,\n\t\t\t\t\t\t}, \"m-auto material-icons-outlined\"])\n }, \"book\", 2)\n ], 2),\n _createElementVNode(\"div\", _hoisted_4, [\n _createVNode(_component_router_link, {\n to: { name: 'CourseTreeNodeDetailDispatcher', params: { nodeId: _ctx.node.id } }\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"h2\", _hoisted_5, _toDisplayString(_ctx.lessonTitle), 1),\n _createElementVNode(\"h3\", _hoisted_6, _toDisplayString(_ctx.lessonTitle), 1)\n ]),\n _: 1\n }, 8, [\"to\"]),\n _createElementVNode(\"div\", _hoisted_7, [\n (_ctx.node.creator)\n ? (_openBlock(), _createElementBlock(\"p\", _hoisted_8, _toDisplayString(_ctx.node.creator.full_name), 1))\n : _createCommentVNode(\"\", true),\n (_ctx.updatedOnDifferentDay)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_9, _toDisplayString(_ctx.$t(\"misc.updated_on\")), 1))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_Timestamp, {\n \"date-only\": true,\n class: \"text-sm text-muted\",\n value: _ctx.node.modified\n }, null, 8, [\"value\"])\n ])\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_10, [\n (_ctx.node.state === _ctx.LessonNodeState.DRAFT)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_11, [\n (_ctx.node.schedule_publish_at)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_12, [\n _createElementVNode(\"p\", _hoisted_13, _toDisplayString(_ctx.$t(\"course_tree.scheduled_for\")), 1),\n _createElementVNode(\"p\", _hoisted_14, [\n (_openBlock(), _createElementBlock(\"svg\", _hoisted_15, _hoisted_17))\n ]),\n _createVNode(_component_Timestamp, {\n value: _ctx.node.schedule_publish_at\n }, null, 8, [\"value\"])\n ]))\n : (_openBlock(), _createElementBlock(\"p\", _hoisted_18, _toDisplayString(_ctx.$t(\"course_tree.draft\")), 1))\n ]))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_19, [\n (_ctx.canEdit)\n ? (_openBlock(), _createBlock(_component_Btn, {\n key: 0,\n onClick: _ctx.onEdit,\n variant: 'icon',\n outline: true,\n class: \"icon-btn-primary\",\n tooltip: _ctx.$t('misc.edit')\n }, {\n default: _withCtx(() => [\n _hoisted_20\n ]),\n _: 1\n }, 8, [\"onClick\", \"tooltip\"]))\n : _createCommentVNode(\"\", true),\n (_ctx.canEdit)\n ? (_openBlock(), _createBlock(_component_Btn, {\n key: 1,\n class: \"mr-4\",\n onClick: _ctx.onDelete,\n variant: 'icon',\n outline: true,\n tooltip: _ctx.$t('misc.delete')\n }, {\n default: _withCtx(() => [\n _hoisted_21\n ]),\n _: 1\n }, 8, [\"onClick\", \"tooltip\"]))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_CopyToClipboard, {\n \"icon-only\": true,\n tooltip: _ctx.$t('exercise_solution.share'),\n value: _ctx.permalink\n }, null, 8, [\"tooltip\", \"value\"])\n ])\n ])\n ]),\n (_ctx.node.comment_count > 0)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_22, [\n _createVNode(_component_router_link, {\n class: \"flex items-center space-x-2 w-max\",\n to: { name: 'CourseTreeNodeDetailDispatcher', params: { nodeId: _ctx.node.id } }\n }, {\n default: _withCtx(() => [\n _hoisted_23,\n _createElementVNode(\"p\", _hoisted_24, _toDisplayString(_ctx.node.comment_count) + \" \" + _toDisplayString(_ctx.node.comment_count === 1\n\t\t\t\t\t\t\t? _ctx.$t(\"course_tree.node_comment_title\")\n\t\t\t\t\t\t\t: _ctx.$t(\"course_tree.node_comments_title\")), 1)\n ]),\n _: 1\n }, 8, [\"to\"])\n ]))\n : _createCommentVNode(\"\", true)\n ], 2))\n}","\nimport Btn from \"@/components/ui/Btn.vue\";\nimport CopyToClipboard from \"@/components/ui/CopyToClipboard.vue\";\nimport ProcessedTextFragment from \"@/components/ui/ProcessedTextFragment.vue\";\nimport Timestamp from \"@/components/ui/Timestamp.vue\";\nimport { getTranslatedString as _ } from \"@/i18n\";\nimport { courseIdMixin, nodeMixin } from \"@/mixins\";\nimport { LessonNode, LessonNodeState } from \"@/models\";\nimport { sameDay } from \"@/utils\";\nimport { defineComponent, PropType } from \"@vue/runtime-core\";\nimport { nodeEmits, nodeProps } from \"../shared\";\nexport default defineComponent({\n\tname: \"LessonNode\",\n\tmixins: [courseIdMixin, nodeMixin],\n\tprops: {\n\t\tnode: {\n\t\t\ttype: Object as PropType,\n\t\t\trequired: true,\n\t\t},\n\t\t...nodeProps,\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tLessonNodeState,\n\t\t};\n\t},\n\temits: {\n\t\t...nodeEmits,\n\t},\n\tmethods: {\n\t\tonEdit() {\n\t\t\tthis.$emit(\"editNode\", this.node);\n\t\t},\n\t\tonDelete() {\n\t\t\tthis.$emit(\"deleteNode\", this.node);\n\t\t},\n\t},\n\tcomputed: {\n\t\tlessonTitle() {\n\t\t\treturn this.node.title || _(\"course_tree.unnamed_lesson\");\n\t\t},\n\t\tbodyPreview() {\n\t\t\treturn this.node.body;\n\t\t},\n\t\tupdatedOnDifferentDay() {\n\t\t\treturn !sameDay(new Date(this.node.created), new Date(this.node.modified));\n\t\t},\n\t},\n\t// eslint-disable-next-line vue/no-unused-components\n\tcomponents: { ProcessedTextFragment, Timestamp, Btn, CopyToClipboard },\n});\n","import { render } from \"./LessonNode.vue?vue&type=template&id=4c6857fe&ts=true\"\nimport script from \"./LessonNode.vue?vue&type=script&lang=ts\"\nexport * from \"./LessonNode.vue?vue&type=script&lang=ts\"\n\nimport exportComponent from \"/tmp/build/node_modules/vue-loader-v16/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__"],"sourceRoot":""}