Skip to content

Commit

Permalink
refactor(x-ios): uniPage 上的方法改为 framework 通过 prototype 实现
Browse files Browse the repository at this point in the history
  • Loading branch information
zhenyuWang committed Jan 13, 2025
1 parent 1dc4bd6 commit 9b8b456
Showing 1 changed file with 0 additions and 26 deletions.
26 changes: 0 additions & 26 deletions packages/uni-app-plus/src/x/framework/page/setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,32 +82,6 @@ export function setupXPage(
})
uniPage.vm = pageVm
uniPage.$vm = pageVm
uniPage.getParentPage = () => {
// @ts-expect-error
const parentPage = uniPage.getParentPageByJS()
return parentPage || null
}

uniPage.getPageStyle = (): UTSJSONObject => {
// @ts-expect-error
const pageStyle = uniPage.getPageStyleByJS()
return new UTSJSONObject(pageStyle)
}
uniPage.$getPageStyle = (): UTSJSONObject => {
return uniPage.getPageStyle()
}

uniPage.setPageStyle = (styles: UTSJSONObject) => {
// @ts-expect-error
uniPage.setPageStyleByJS(styles)
}
uniPage.$setPageStyle = (styles: UTSJSONObject) => {
uniPage.setPageStyle(styles)
}

uniPage.getAndroidView = () => null
uniPage.getIOSView = () => null
uniPage.getHTMLElement = () => null

if (getPage$BasePage(pageVm).openType !== OPEN_DIALOG_PAGE) {
addCurrentPageWithInitScope(
Expand Down

0 comments on commit 9b8b456

Please sign in to comment.