UNPKG

tdesign-miniprogram

Version:
1 lines 931 B
import{__decorate}from"tslib";import{SuperComponent,wxComponent}from"../common/src/index";import config from"../common/config";import props from"./props";import usingConfig from"../mixins/using-config";const{prefix:prefix}=config,componentName="typography";let Paragraph=class extends SuperComponent{constructor(){super(...arguments),this.behaviors=[usingConfig({componentName:"typography"})],this.externalClasses=[`${prefix}-class`],this.options={multipleSlots:!0},this.properties=props,this.data={prefix:prefix,classPrefix:`${prefix}-typography`,isExpanded:!1},this.methods={onExpand(){this.setData({isExpanded:!0});const{ellipsis:e}=this.properties;"object"==typeof e&&this.triggerEvent("expand",{expanded:!0})},onCollapse(){this.setData({isExpanded:!1});const{ellipsis:e}=this.properties;"object"==typeof e&&this.triggerEvent("expand",{expanded:!1})}}}};Paragraph=__decorate([wxComponent()],Paragraph);export default Paragraph;