uview 滑動切換

2022-09-08 06:51:13 字數 4413 閱讀 5293

```html

<

template

>

<

view

class

="content"

>

<

u-swiper

:list

="list2"

keyname

="image"

showtitle :autoplay

="false"

circular

>

u-swiper

>

<

u-modal

:show

="show"

title

="test"

:confirmtext

="modalconfig.confirmtext"

:showcancelbutton

="modalconfig.showcancelbutton"

@confirm

="modalchange"

>

<

slot

>

<

u--input

v-model

="inputvalue"

border

="surround"

placeholder

="請輸入列數……"

type

="number"

>

u--input

>

slot

>

u-modal

>

<

u-row

justify

="flex-end"

>

<

u-col

:span

="3"

>

<

u-button

text

="設定"

type

="success"

class

="btnsize"

@click

="show = true"

>

u-button

>

u-col

>

u-row

>

<

u-grid

:border

="false"

:col

="gridcol"

>

<

u-grid-item

v-for

="item,index in 6"

>

<

u-icon

:customstyle

=""name

="order"

:size

="30"

color

="#909399"

>

u-icon

>

<

text

class

="grid-text"

>}

text

>

u-grid-item

>

u-grid

>

<

view

class

="home"

>

<

u-sticky

bgcolor

="#fff"

>

<

u-tabs

:list

="list1"

:current

="swiperconfig.swipercur"

@click

="click"

>

u-tabs

>

u-sticky

>

<

swiper

class

="swiper"

style

="flex: 1;"

:indicator-dots

="swiperconfig.indicatordots"

:autoplay

="swiperconfig.autoplay"

:interval

="swiperconfig.interval"

:duration

="swiperconfig.duration"

:current

="swiperconfig.swipercur"

@change

="swiperchange"

>

<

swiper-item

v-for

="item,index in list1"

:key

="index"

style

="height: 100%;"

>

<

scroll-view

scroll-y style

="height: 100%;width: 100%;"

>

<

view

class

="swiper-item-content"

>

豫章故郡,洪都新府。星分翼軫,地接衡廬。襟三江而帶五湖,控蠻荊而引甌越。物華天寶,龍光射牛鬥之墟;人傑地靈,徐孺下陳蕃之榻。雄州霧列,俊採星馳。臺隍枕夷夏之交,賓主盡東南之美。都督閻公之雅望,棨戟遙臨;宇文新州之懿範,襜帷暫駐。十旬休假,勝友如雲;千里逢迎,高朋滿座。騰蛟起鳳,孟學士之詞宗;紫電青霜,王將軍之武庫。家君作宰,路出名區;童子何知,躬逢勝餞。

時維九月,序屬三秋。潦水盡而寒潭清,煙光凝而暮山紫。儼驂騑於上路,訪風景於崇阿;臨帝子之長洲,得天人之舊館。層巒聳翠,上出重霄;飛閣流丹,下臨無地。鶴汀鳧渚,窮島嶼之縈迴;桂殿蘭宮,即岡巒之體勢。

披繡闥,俯雕甍,山原曠其盈視,川澤紆其駭矚。閭閻撲地,鐘鳴鼎食之家;舸艦彌津,青雀黃龍之舳。雲銷雨霽,彩徹區明。落霞與孤鶩齊飛,秋水共長天一色。漁舟唱晚,響窮彭蠡之濱;雁陣驚寒,聲斷衡陽之浦。

遙襟甫暢,逸興遄飛。爽籟發而清風生,纖歌凝而白雲遏。睢園綠竹,氣凌彭澤之樽;鄴水朱華,光照臨川之筆。四美具,二難並。窮睇眄於中天,極娛游於暇日。天高地迥,覺宇宙之無窮;興盡悲來,識盈虛之有數。望長安於日下,目吳會於雲間。地勢極而南溟深,天柱高而北辰遠。關山難越,誰悲失路之人?萍水相逢,盡是他鄉之客。懷帝閽而不見,奉宣室以何年?

嗟乎!時運不齊,命途多舛。馮唐易老,李廣難封。屈賈誼於長沙,非無聖主;竄梁鴻於海曲,豈乏明時?所賴君子見機,達人知命。老當益壯,寧移白首之心?窮且益堅,不墜青雲之志。酌貪泉而覺爽,處涸轍以猶歡。北海雖賒,扶搖可接;東隅已逝,桑榆非晚。孟嘗高潔,空餘報國之情;阮籍猖狂,豈效窮途之哭!

勃,三尺微命,一介書生。無路請纓,等終軍之弱冠;有懷投筆,慕宗愨之長風。舍簪笏於百齡,奉晨昏於萬里。非謝家之寶樹,接孟氏之芳鄰。他日趨庭,叨陪鯉對;今茲捧袂,喜託龍門。楊意不逢,撫凌雲而自惜;鍾期既遇,奏流水以何慚?

嗚乎!勝地不常,盛筵難再;蘭亭已矣,梓澤丘墟。臨別贈言,幸承恩於偉餞;登高作賦,是所望於群公。敢竭鄙懷,恭疏短引;一言均賦,四韻俱成。請灑潘江,各傾陸111111111111

view

>

scroll-view

>

swiper-item

>

swiper

>

view

>

view

>

template

>

<

script

>

export

default

, , , ],

//輪播圖配置

swiperconfig: ,

gridcol: 3,

inputvalue: "",

//模態框配置

滑動切換Activity

在dependencies中加入下面一句,就可以引入開源庫到當前專案 compile com.r0adkll slidableactivity 2.0.3 需要準備兩個activity,唯一需要注意的是activity的theme需要重寫下面的 name android windowistransl...

Android Fragment滑動切換

1,因為要進行滑動,所以中文在布局中就進行viewpager布局 android id id vp container android layout width match parent android layout height match parent android.support.v4.vi...

mui 滑動切換介面

mui中實現滑動切換的方式總的來說就只有兩種 singlepage模式 不同的介面或在同乙個html檔案中,放在不同的div標籤中,通過js指令碼來控制滑動 如swiper.js 這種方式適合於輪播,或者介面較為簡單的情況。優勢在於不同介面之間傳遞引數容易。多webview模式 這種情況下有多個we...