New:Microsoft Teams Notifications Are Now Available in Socket.Learn more
Get Started

mina-beautiful-paragraph

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mina-beautiful-paragraph

小程序纯文本段落排版美化。

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

mina-beautiful-paragraph

小程序纯文本段落排版美化。

  • 完美的两端对齐(中英文混杂,且存在长英文文本)
  • 标点不出现在行首

usage

install

npm install mina-beautiful-paragraph --save

page.json

{
  "usingComponents": {
    "BeautifulParagraph": "path/to/mina-beautiful-paragraph"
  }
}

page.wxml

<BeautifulParagraph
  custom-class="custom-paragraph-class"
  content="{{texts}}"
  selectable="{{true}}"
  padding="{{35}}"
  />

page.js

Page({
  data: {
    texts: '文本文本'
  }
})

page.wxss

/* 自定义样式 */
.custom-paragraph-class{

}

组件支持的属性

namerequiredtypedefaultdesc
custom-classfalsestring''
contenttruestring''要排版的文本
selectablefalsebooleantrue文本是否可选中
paddingfalsenumber35换行距离

FAQs

Package last updated on 03 Aug 2020

Related posts