提交 22edc0a2 编写于 作者: Y yurj26

feat: 组件示例去除scroll-view的条件编译

上级 134855f4
...@@ -46,9 +46,7 @@ ...@@ -46,9 +46,7 @@
{{ text }} {{ text }}
</button> </button>
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<boolean-data :defaultValue="false" title="按钮是否镂空,背景色透明" @change="change_plain_boolean"></boolean-data> <boolean-data :defaultValue="false" title="按钮是否镂空,背景色透明" @change="change_plain_boolean"></boolean-data>
<boolean-data :defaultValue="false" title="是否禁用" @change="change_disabled_boolean"></boolean-data> <boolean-data :defaultValue="false" title="是否禁用" @change="change_disabled_boolean"></boolean-data>
...@@ -57,9 +55,7 @@ ...@@ -57,9 +55,7 @@
<enum-data :items="type_enum" title="按钮的类型" @change="radio_change_type_enum"></enum-data> <enum-data :items="type_enum" title="按钮的类型" @change="radio_change_type_enum"></enum-data>
<input-data :defaultValue="text" title="按钮的文案" type="text" @confirm="confirm_text_input"></input-data> <input-data :defaultValue="text" title="按钮的文案" type="text" @confirm="confirm_text_input"></input-data>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
...@@ -81,4 +77,4 @@ ...@@ -81,4 +77,4 @@
background-color: #179b16; background-color: #179b16;
border-color: #179b16; border-color: #179b16;
} }
</style> </style>
\ No newline at end of file
...@@ -114,9 +114,7 @@ export default { ...@@ -114,9 +114,7 @@ export default {
> >
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<page-head title="组件属性"></page-head> <page-head title="组件属性"></page-head>
<boolean-data <boolean-data
...@@ -249,10 +247,7 @@ export default { ...@@ -249,10 +247,7 @@ export default {
</checkbox-group> </checkbox-group>
</view> </view>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
......
<template> <template>
<page-head title="拖拽图标测试相关事件"></page-head> <scroll-view style="flex: 1" :scroll-y="true">
<view class="container"> <page-head title="拖拽图标测试相关事件"></page-head>
<view class="view-box"> <view class="container">
<image class="icon" id="icon" src="../image/logo.png" @touchstart="onTouchStart" @touchcancel="onTouchCancel" @touchmove="onTouchMove" @touchend="onTouchEnd"></image> <view class="view-box">
</view> <image class="icon" id="icon" src="../image/logo.png" @touchstart="onTouchStart" @touchcancel="onTouchCancel" @touchmove="onTouchMove" @touchend="onTouchEnd"></image>
</view>
</view> </view>
<view v-if="touchEvent !== null"> <view v-if="touchEvent !== null">
<text class="title1">touches: </text> <text class="title1">touches: </text>
<template v-for="(touch, index) in touchEvent!.touches" :key="index"> <template v-for="(touch, index) in touchEvent!.touches" :key="index">
<text class="title2">touch[{{ index }}]:</text> <text class="title2">touch[{{ index }}]:</text>
<text>identifier: {{touch.identifier}}</text> <text>identifier: {{touch.identifier}}</text>
<text>pageX: {{ touch.pageX }}, pageY: {{ touch.pageY }}</text> <text>pageX: {{ touch.pageX }}, pageY: {{ touch.pageY }}</text>
<text>clientX: {{ touch.clientX }}, clientY: {{ touch.clientY }}</text> <text>clientX: {{ touch.clientX }}, clientY: {{ touch.clientY }}</text>
<text>screenX: {{ touch.screenX }}, screenY: {{ touch.screenY }}</text> <text>screenX: {{ touch.screenX }}, screenY: {{ touch.screenY }}</text>
</template> </template>
</view> </view>
</scroll-view>
</template> </template>
<script> <script>
......
...@@ -146,9 +146,7 @@ ...@@ -146,9 +146,7 @@
</list-view> </list-view>
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex:1" :scroll-y="true">
<scroll-view style="flex:1">
<!-- #endif -->
<view class="content"> <view class="content">
<boolean-data :defaultValue="false" title="设置当前下拉刷新状态,true 表示下拉刷新已经被触发,false 表示下拉刷新未被触发" <boolean-data :defaultValue="false" title="设置当前下拉刷新状态,true 表示下拉刷新已经被触发,false 表示下拉刷新未被触发"
@change="change_refresher_triggered_boolean"></boolean-data> @change="change_refresher_triggered_boolean"></boolean-data>
...@@ -177,9 +175,7 @@ ...@@ -177,9 +175,7 @@
</button> </button>
</navigator> </navigator>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
......
...@@ -73,9 +73,7 @@ export default { ...@@ -73,9 +73,7 @@ export default {
</progress> </progress>
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<page-head title="组件属性"></page-head> <page-head title="组件属性"></page-head>
<boolean-data <boolean-data
...@@ -173,9 +171,7 @@ export default { ...@@ -173,9 +171,7 @@ export default {
</view> </view>
</view> </view>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
......
...@@ -107,9 +107,7 @@ export default { ...@@ -107,9 +107,7 @@ export default {
</radio> </radio>
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<page-head title="组件属性"></page-head> <page-head title="组件属性"></page-head>
<boolean-data <boolean-data
...@@ -232,9 +230,7 @@ export default { ...@@ -232,9 +230,7 @@ export default {
</radio-group> </radio-group>
</view> </view>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
......
...@@ -97,9 +97,7 @@ ...@@ -97,9 +97,7 @@
@changing="slider_changing" style="width: 90%"><text>uni-app-x</text></slider> @changing="slider_changing" style="width: 90%"><text>uni-app-x</text></slider>
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<page-head title="组件属性"></page-head> <page-head title="组件属性"></page-head>
<boolean-data :defaultValue="false" title="是否显示当前 value" @change="change_show_value_boolean"></boolean-data> <boolean-data :defaultValue="false" title="是否显示当前 value" @change="change_show_value_boolean"></boolean-data>
...@@ -151,9 +149,7 @@ ...@@ -151,9 +149,7 @@
:block-size="sliderBlockSize" /> :block-size="sliderBlockSize" />
</view> </view>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
...@@ -174,4 +170,4 @@ ...@@ -174,4 +170,4 @@
.m-l-a { .m-l-a {
margin-left: auto; margin-left: auto;
} }
</style> </style>
\ No newline at end of file
...@@ -77,9 +77,7 @@ export default { ...@@ -77,9 +77,7 @@ export default {
/> />
</view> </view>
<!-- #ifdef APP --> <scroll-view style="flex: 1" :scroll-y="true">
<scroll-view style="flex: 1">
<!-- #endif -->
<view class="content"> <view class="content">
<boolean-data <boolean-data
:defaultValue="false" :defaultValue="false"
...@@ -96,7 +94,7 @@ export default { ...@@ -96,7 +94,7 @@ export default {
:defaultValue="false" :defaultValue="false"
title="如果 textarea 是在一个 position:fixed 的区域,需要显示指定属性 fixed 为 true" title="如果 textarea 是在一个 position:fixed 的区域,需要显示指定属性 fixed 为 true"
@change="change_fixed_boolean" @change="change_fixed_boolean"
></boolean-data> ></boolean-data>
<!-- #endif --> <!-- #endif -->
<boolean-data <boolean-data
:defaultValue="false" :defaultValue="false"
...@@ -129,9 +127,7 @@ export default { ...@@ -129,9 +127,7 @@ export default {
@change="radio_change_inputmode_enum" @change="radio_change_inputmode_enum"
></enum-data> ></enum-data>
</view> </view>
<!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif -->
</template> </template>
<style> <style>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册