Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
jin0209 committed Dec 8, 2023
2 parents 6510ac5 + db6dfc2 commit 225ade8
Show file tree
Hide file tree
Showing 81 changed files with 2,573 additions and 1,934 deletions.
1 change: 1 addition & 0 deletions .github/issue-shoot.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
- 期望完成时间: {{ .deadline }}
- 开发难度: {{ .level }}
- 参与人数: 1
- 需求对接人: jeannehuang;anlyyao
- 验收标准: 实现期望改造效果,提 PR 并通过验收无误
- 备注: 最终激励以实际提交 `pull request` 并合并为准
18 changes: 18 additions & 0 deletions .github/workflows/tag-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,21 @@ jobs:
- if: steps.publish.outputs.type != 'none'
run: |
echo "Version changed: ${{ steps.publish.outputs.old-version }} => ${{ steps.publish.outputs.version }}"
UPDATE_OFFICIAL_WEBSITE:
runs-on: ubuntu-latest
if: github.event.ref_type == 'tag'
steps:
- uses: actions/checkout@v3
with:
ref: main
fetch-depth: 0
token: ${{ secrets.PERSONAL_TOKEN }}
submodules: recursive
- name: update official website
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git status
git fetch origin
git merge origin/develop
git push origin main
2 changes: 1 addition & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
npx lint-staged && log_emails=$(git config user.email) && if [[ ${log_emails} =~ '@tencent.com' ]];then echo 本地提交邮箱 $log_emails 校验非法,需要本地更改重新提交 && exit 2;else echo 邮箱 $log_emails 校验通过;fi
3,664 changes: 1,849 additions & 1,815 deletions CHANGELOG.md

Large diffs are not rendered by default.

60 changes: 60 additions & 0 deletions example/components/trd-privacy/privacy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
// components/privacy/privacy.js
Component({
/**
* 组件的属性列表
*/
properties: {
name: {
type: String,
value: '',
},
date: {
type: String,
value: '',
},
winStyle: {
type: Boolean,
value: false,
},
},

/**
* 组件的初始数据
*/
data: {
win: false,
privacy: false,
},

/**
* 组件的方法列表
*/
methods: {
showPrivacyDetail() {
this.setData({
win: false,
privacy: true,
});
},
privacyConfirm() {
this.setData({
privacy: false,
win: false,
});
wx.setStorageSync('TIMIShowPrivacy', true);
},
showPrivacyWin() {
this.setData({
win: true,
});
},
},
ready() {
const TIMIShowPrivacy = wx.getStorageSync('TIMIShowPrivacy');
if (!TIMIShowPrivacy) {
this.setData({
win: true,
});
}
},
});
6 changes: 6 additions & 0 deletions example/components/trd-privacy/privacy.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"component": true,
"usingComponents": {
"t-button": "tdesign-miniprogram/button/button"
}
}
39 changes: 39 additions & 0 deletions example/components/trd-privacy/privacy.wxml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<view wx:if="{{privacy}}" class="privacy_wrap">
<view class="privacy_safe_area">
<view class="privacy_top">
<view class="privacy_title">{{name}}服务声明</view>
<view class="privacy_right">发布日期:{{date}}</view>
<view class="privacy_right">生效日期:{{date}}</view>
</view>
<view class="privacy_content">
<text class="privacy_bold">引言</text>
<text decode="{{true}}" class="privacy_normal"
>{{name}}是由深圳市腾讯计算机系统有限公司(以下简称“我们”)提供的产品,我们的注册地为深圳市南山区粤海街道麻岭社区科技中一路腾讯大厦35层。</text
>
<text decode="{{true}}" class="privacy_bold"
>我们在此特别声明:\n1.本小程序产品功能的实现不涉及收集和处理用户(以下简称“您”)的任何个人信息。\n2.如果我们更新、改进或修改小程序产品功能,并因此导致我们需要处理您的个人信息的,我们将会依据适用法律的要求对本声明进行修订,并将修订后的内容通过弹框等形式通知您并获得您同意。</text
>
<text decode="{{true}}" class="privacy_normal">
3.如果您对本声明有任何疑问或建议,您可以通过以下方式与我们取得联系:\n(1)将问题发送至[email protected];\n(2)通过https://kf.qq.com/与我们联系;\n(3)将您的问题邮寄至下列地址:\n\n中国广东省深圳市南山区海天二路33号腾讯滨海大厦\n数据隐私保护部(收)\n邮编:518054\n\n我们将尽快审核所涉问题,并在15个工作日或法律法规规定的期限内予以反馈。
</text>
</view>
<view class="footer">
<t-button class="t-design-button" theme="primary" bindtap="privacyConfirm">我已知晓</t-button>
</view>
</view>
</view>
<view wx:if="{{win}}" class="privacy_tips_win">
<view class="privacy_win_content {{winStyle?'privacy_middle':''}}">
<view class="privacy_tips_content"
>我们将严格按照<text class="privacy_url" bindtap="showPrivacyDetail">《{{name}}服务声明》</text
>向您提供服务,不会收集和处理您的个人信息。</view
>
<view class="privacy_tips_content"
>如您对<text class="privacy_url" bindtap="showPrivacyDetail">《{{name}}服务声明》</text
>有任何疑问或建议,可以通过声明内的联系方式向我们反馈。</view
>
<view class="footer">
<t-button class="t-design-button" theme="primary" bindtap="privacyConfirm">我已知晓</t-button>
</view>
</view>
</view>
137 changes: 137 additions & 0 deletions example/components/trd-privacy/privacy.wxss
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
/* components/privacy/privacy.wxss */
.privacy_wrap {
width: 100vw;
height: 100vh;
position: fixed;
left: 0;
top: 0;
z-index: 99999;
background-color: #fff;
color: #222;
font-size: 24rpx;
}
.privacy_safe_area {
width: 750rpx;
height: 1180rpx;
position: absolute;
left: 0;
top: 50%;
transform: translate(0, -50%);
}
.privacy_top {
padding: 50rpx 40rpx;
position: relative;
overflow: hidden;
}
.privacy_btn_back::before {
content: '<<';
}
.privacy_title {
height: 100%;
font-size: 32rpx;
font-weight: 700;
text-align: center;
line-height: 60rpx;
}
.privacy_right {
height: 48rpx;
line-height: 48rpx;
text-align: right;
}
.privacy_content {
height: 790rpx;
padding: 0 40rpx;
overflow: auto;
line-height: 32rpx;
}
.privacy_bold {
font-weight: 700;
display: inline-block;
padding-bottom: 12rpx;
}
.privacy_normal {
text-indent: 2em;
display: inline-block;
padding-bottom: 12rpx;
}
.privacy_btn_confirm {
width: 150rpx;
height: 92rpx;
padding: 0 85rpx;
border-radius: 16rpx;
border: #ccc solid 2rpx;
background-color: #06c15f;
font-size: 32rpx;
text-align: center;
line-height: 92rpx;
color: #fff;
margin: 30rpx auto 0;
text-indent: 0;
}
.privacy_tips_win {
width: 100vw;
height: 100vh;
position: fixed;
left: 0;
top: 0;
z-index: 99999;
background: rgba(0, 0, 0, 0.75);
color: #222;
font-size: 28rpx;
}
.privacy_win_content {
width: 100vw;
box-sizing: border-box;
overflow: hidden;
position: absolute;
left: 0;
bottom: 0;
background: #fff;
border-radius: 24rpx 24rpx 0 0;
padding: 50rpx 40rpx;
text-indent: 2em;
animation: privacy_up 0.2s forwards;
transform: translateY(100%);
}
@keyframes privacy_up {
0% {
transform: translateY(100%);
}
100% {
transform: translateY(0);
}
}
.privacy_line {
display: inline-block;
vertical-align: middle;
}
.privacy_url {
color: #576b95;
text-indent: 0;
display: inline;
vertical-align: middle;
}
.privacy_tips_content {
line-height: 40rpx;
vertical-align: middle;
}
.privacy_middle {
width: 650rpx;
left: 50%;
bottom: 50%;
transform: translate(-50%, 50%);
border-radius: 24rpx;
animation: none;
}

.footer {
width: 100%;
margin-top: 30rpx;
display: flex;
justify-content: center;
align-items: center;
text-indent: 0;
}
.t-design-button {
width: 300rpx;
}
3 changes: 2 additions & 1 deletion example/pages/home/home.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"usingComponents": {
"pull-down-list": "../../components/pull-down-list/index"
"pull-down-list": "../../components/pull-down-list/index",
"t-footer": "tdesign-miniprogram/footer/footer"
},
"navigationBarTitleText": "TDesign UI",
"navigationBarBackgroundColor": "#f6f6f6",
Expand Down
9 changes: 7 additions & 2 deletions example/pages/home/home.less
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@ page {
padding-left: 16rpx * 2;
padding-right: 16rpx * 2;
padding-top: 24rpx * 2;
padding-bottom: 120rpx * 2;
padding-bottom: 24rpx * 2;
}

.footer {
padding: 16rpx 32rpx;
text-align: center;
}

.title-wrap {
Expand All @@ -25,7 +30,7 @@ page {
}

.desc {
color: rgba(0, 0, 0, .4);
color: rgba(0, 0, 0, 0.4);
margin-top: 16rpx * 2;
font-size: 14rpx * 2;
font-weight: 400;
Expand Down
1 change: 1 addition & 0 deletions example/pages/home/home.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import list from './data/index';
Page({
data: {
list,
currentYear: new Date().getFullYear(),
},
onLoad(options) {
const { path, q } = options;
Expand Down
3 changes: 3 additions & 0 deletions example/pages/home/home.wxml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,6 @@
bind:click="clickHandle"
/>
</view>
<view class="footer">
<t-footer text="Copyright © 1998 - {{currentYear}} Tencent. All Rights Reserved. 腾讯公司 版权所有"></t-footer>
</view>
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "tdesign-miniprogram",
"purename": "tdesign",
"version": "1.2.3",
"version": "1.2.5",
"description": "tdesign-miniprogram",
"title": "tdesign-ßminiprogram",
"main": "miniprogram_dist/index.js",
Expand Down Expand Up @@ -102,7 +102,7 @@
"stylelint": "^13.13.1",
"tdesign-icons-view": "^0.2.1",
"tdesign-publish-cli": "^0.0.12",
"tdesign-site-components": "^0.12.2",
"tdesign-site-components": "^0.13.10",
"typescript": "~4.7.2",
"vite": "^2.7.6",
"vite-plugin-tdoc": "^2.0.1",
Expand Down
13 changes: 9 additions & 4 deletions site/plugin-tdoc/component.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@
<img class="qrcode" :src="qrcode" />
<!-- <img class="qrcode" :src="`https://tdesign.gtimg.com/miniprogram/qrcode/${name}.png`" /> -->
</div>
<iframe :src="liveUrl" frameborder="0" width="100%" height="100%"
style="box-sizing: border-box; border-radius: 0 0 6px 6px; overflow: hidden; border-top: 8px solid #f8f8f8"></iframe>
<iframe
:src="liveUrl"
frameborder="0"
width="100%"
height="100%"
style="box-sizing: border-box; border-radius: 0 0 6px 6px; overflow: hidden; border-top: 8px solid #f8f8f8"
></iframe>
</td-doc-phone>
<td-contributors platform="miniprogram" framework="wx" :component-name="name"></td-contributors>
</div>
Expand Down Expand Up @@ -57,7 +62,7 @@ export default defineComponent({
return path.slice(path.lastIndexOf('/') + 1);
},
liveUrl() {
return `/miniprogram-live/m2w/program/miniprogram/#!pages/${this.name}/${this.name}.html`;
return `//tdesign.tencent.com/miniprogram-live/m2w/program/miniprogram/#!pages/${this.name}/${this.name}.html`;
},
qrcode() {
const { path } = this.$route;
Expand Down Expand Up @@ -108,7 +113,7 @@ export default defineComponent({
filter: unset;
}
div[name='DEMO'] &+pre {
div[name='DEMO'] & + pre {
margin-top: 0;
border-top-left-radius: 0;
border-top-right-radius: 0;
Expand Down
2 changes: 2 additions & 0 deletions src/back-top/README.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
name | type | default | description | required
-- | -- | -- | -- | --
external-classes | Array | - | `['t-class', 't-class-icon', 't-class-text']` | N
visibility-height | Number | 200 | \- | N
scroll-top | Number | 0 | \- | N
fixed | Boolean | true | \- | N
icon | String / Boolean / Object / Slot | - | \- | N
text | String | '' | \- | N
Expand Down
3 changes: 3 additions & 0 deletions src/back-top/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ isComponent: true

名称 | 类型 | 默认值 | 说明 | 必传
-- | -- | -- | -- | --
external-classes | Array | - | 组件类名,分别用于设置外层元素、图标、文本内容等元素类名。`['t-class', 't-class-icon', 't-class-text']` | N
visibility-height | Number | 200 | 滚动高度达到此参数值才出现 | N
scroll-top | Number | 0 | 页面滚动距离 | N
fixed | Boolean | true | 是否绝对定位固定到屏幕右下方 | N
icon | String / Boolean / Object / Slot | true | 图标。值为 `false` 表示不显示图标。不传表示使用默认图标 `'backtop'` | N
text | String | '' | 文案 | N
Expand Down
Loading

0 comments on commit 225ade8

Please sign in to comment.