Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
167 commits
Select commit Hold shift + click to select a range
d737f3d
feat: 初始化recycle list
Jan 20, 2025
7de08fb
feat: 初始化recycle list
Jan 21, 2025
78c6340
chore: 增强recycle
Jan 22, 2025
e93b931
chore: 增强recycle
Jan 22, 2025
db5ed91
fix: ali&web环境scrollTop初始化不生效问题
Jan 23, 2025
b67f4a0
chore: 适配rn
Feb 5, 2025
a76b2c3
feat: rn支持抽象节点
Feb 6, 2025
eaed9a0
fix: warning
Feb 6, 2025
f9c7722
chore: 删除web单独适配的recycle-list
Feb 10, 2025
a38b0f1
chore: 添加节流优化
Feb 10, 2025
5978c67
Merge branch 'master' into feat-recycle-list-web
Feb 10, 2025
3033c17
feat: 支持同时传递多个抽象节点
Feb 10, 2025
1243a2e
chore: 删除vuepress
Feb 10, 2025
042cccc
chore: 优化recycle-view组件
Feb 11, 2025
b13b4ac
chore: 优化recycle-view组件
Feb 11, 2025
dd88f94
feat: 编译时支持内置扩展组件
Feb 11, 2025
0731d04
feat: 新增小程序平台recycle-view全局组件注册
Feb 11, 2025
109e5dd
chore: 修改web,rn平台recycle-view全局组件注册
Feb 12, 2025
985aec0
feat: 新增web, 小程序环境支持跨平台组件编译配置
Feb 12, 2025
0df56f3
feat: item支持动态高度
Feb 13, 2025
fd38830
fix: lint error
Feb 13, 2025
09287cb
chore: 简化visibleCount逻辑
Feb 13, 2025
5b8bc99
fix: rn全局组件注册找不到
Feb 13, 2025
4877bc6
chore: 删除注释
Feb 13, 2025
1e7365a
chore: 修改itemSize定义
Feb 13, 2025
422f350
Merge branch 'master' into feat-recycle-list-web
Feb 13, 2025
c41daee
Merge branch 'fix-rn-global-component' into feat-recycle-list-web
Feb 13, 2025
753a575
Merge branch 'fix-rn-global-component' into feat-recycle-list-web
Feb 13, 2025
4ba6ccd
chore: visibleCount计算逻辑支持item宽高不一致情况
Feb 14, 2025
de3e8e8
chore: 修改visibleCount计算,支持宽高不一致情况
Feb 17, 2025
b24fcd4
fix: web误触发onScrollToLower事件
Feb 17, 2025
9578c47
chore: 调整listData数据更新逻辑
Feb 17, 2025
9b84441
Merge branch 'master' into feat-recycle-list-web
Feb 18, 2025
c244764
feat: 新增sticky-section组件
Feb 18, 2025
17b67f8
feat: 初始化sticky-header
Feb 20, 2025
57dfee4
fix: scrollView具备margin样式情况
Feb 20, 2025
d2f0999
feat: 添加跨平台配置
Feb 20, 2025
ff8d7ff
chore: 添加调试文件暂存
Feb 24, 2025
5440135
fix: sticky-header抖动问题
Feb 25, 2025
a906c68
feat: sticky-header方案调整
Feb 27, 2025
82c9710
chore: 补充header功能
Feb 27, 2025
0709497
fix: 非sticky组件scroll 报错
Feb 27, 2025
963747d
feat: web环境支持sticky-header
Feb 28, 2025
9ea1839
chore: 新增dom节点检查
Feb 28, 2025
6d22397
feat: add sticky-section 配置
Mar 3, 2025
156d402
Merge branch 'master' into feat-extend-sticky
Mar 3, 2025
4c7e647
chore: add sticky section config
Mar 4, 2025
5b1e320
fix: rn 吸顶逻辑计算
Mar 4, 2025
fe3dc93
feat: 支持padding属性
Mar 4, 2025
a325f03
fix: 导航条位置获取异常导致吸附位置不正确
Mar 5, 2025
93e0a07
feat: add sticky-section组件
Mar 5, 2025
63e6ea9
Merge branch 'master' into feat-recycle-list-web
Mar 5, 2025
a579c70
Merge branch 'master' into feat-extend-sticky
Mar 5, 2025
0d2484d
chore: 删除无用sticky组件
Mar 5, 2025
d7c7089
Merge branch 'master' into feat-extend-sticky
Mar 7, 2025
666202c
Merge branch 'master' into feat-recycle-list-web
Mar 7, 2025
438aed5
Merge branch 'feat-recycle-list-web' into feat-extend-sticky
Mar 7, 2025
09cc262
fix: add enableSticky 属性
Mar 7, 2025
3e89590
chore: del useless code
Mar 7, 2025
a4a9ba2
Merge branch 'feat-recycle-list-web' into feat-extend-sticky
Mar 7, 2025
a05fda4
fix: sticky-header
Mar 7, 2025
15dd08b
fix: AnimatedScrollView 生成时机
Mar 14, 2025
8f2b0a6
fix: AnimatedScrollView 生成时机
Mar 14, 2025
b3671e7
Merge branch 'master' into feat-extend-sticky
Mar 14, 2025
1f9ad4c
chore: 调整组件入参
Mar 14, 2025
371ccf8
fix: lint
Mar 14, 2025
ec78dde
Merge branch 'master' into feat-extend-sticky
Mar 18, 2025
9680227
fix: 外层做动画 android pageY 可能拿到不准问题
Mar 19, 2025
ae22a6c
Merge branch 'master' into feat-extend-sticky
Mar 21, 2025
c2eef9d
chore: 修改scroll触发逻辑
Mar 21, 2025
2ec66c0
chore: 修改scroll触发逻辑
Mar 21, 2025
4d7a2d2
chore: 修改 aboveCount 和 belowCount 计算逻辑
Mar 21, 2025
f311836
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 21, 2025
26d4413
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 21, 2025
730736d
chore: 调整组件重建时机
Mar 21, 2025
c29beeb
feat: 支持scrollTo方法
Mar 21, 2025
24e9183
chore: 新增支持props
Mar 21, 2025
c35d1a9
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 21, 2025
b178e62
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 21, 2025
15d84ee
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 24, 2025
d12815d
chore: add rn recyle
Mar 24, 2025
b9ce382
feat: 支持generic
Mar 24, 2025
b408c80
chore: 修改generic
Mar 25, 2025
0bd9f71
chore: 修改generic
Mar 25, 2025
d024f47
chore: 修改generic
Mar 25, 2025
7b87ad6
chore: 修改injectProperties注入时机
Mar 25, 2025
bf6d32f
fix: boundingClientRect 获取异常
Mar 25, 2025
a187e38
Merge branch 'feat-extend-sticky' into feat-generic-rn
Mar 25, 2025
acdefe2
chore: del
Mar 25, 2025
31d64fc
Merge branch 'feat-simple-view' into feat-extend-sticky
Mar 25, 2025
35b1fe3
Merge branch 'feat-generic-rn-new' into feat-extend-sticky
Mar 26, 2025
d64e552
Merge branch 'feat-extend-sticky' into feat-recycle-rn
Mar 26, 2025
a3f6a70
fix conflict
Mar 26, 2025
7d02911
Merge branch 'feat-extend-sticky' into feat-recycle-rn
Mar 26, 2025
6ec3a9c
chore: 增强recycle-view.
Mar 26, 2025
596026f
Merge branch 'feat-generic-rn-new' into feat-recycle-rn
Mar 26, 2025
0dc180b
Merge branch 'master' into feat-recycle-rn
Mar 30, 2025
5daf649
Merge branch 'feat-generic-rn-new' into feat-recycle-rn
Mar 30, 2025
5b51763
chore: 修改recycle逻辑
Mar 30, 2025
02fc308
Merge branch 'feat-generic-rn-new' into feat-recycle-rn
Mar 31, 2025
9ba79c9
Merge branch 'master' into feat-recycle-rn
Mar 31, 2025
28ed166
chore: 修改文件路径
Apr 1, 2025
83bb124
Merge branch 'feat-generic-rn-new' into feat-recycle-rn
Apr 1, 2025
ad11b1a
Merge branch 'master' into feat-recycle-rn
Apr 1, 2025
798a1cf
Merge branch 'master' into feat-recycle-rn
Apr 10, 2025
4f409dc
fix: lint;
Apr 11, 2025
f5fcefe
feat: 补充recycle能力
Apr 11, 2025
5148785
feat: 优化小程序 recycle-view
Apr 15, 2025
835368b
chore: 调整recycle目录
Apr 15, 2025
760dccd
Merge branch 'feat-sticky-rn' into feat-recycle-rn
Apr 15, 2025
0ce6847
feat: 支持 rn 环境recycle
Apr 16, 2025
c192ec0
chore: rn环境支持recycle-view
Apr 17, 2025
de646d4
chore: rn环境支持recycle-view
Apr 17, 2025
0ab5792
chore: 调试recycle
Apr 21, 2025
48a2364
chore: 调试recycle
Apr 21, 2025
d207cdd
chore: 调试getSectionItemLayout
Apr 23, 2025
1e764fa
chore: 调试getSectionItemLayout
Apr 24, 2025
c42ac70
chore: 调试getSectionItemLayout
Apr 25, 2025
fb36889
chore: 调试getSectionItemLayout
Apr 25, 2025
af7d0b6
chore: 兼容flatList
Apr 25, 2025
1e2f722
chore: 支持scrollToIndex
Apr 25, 2025
25263d7
chore: 支持反向索引映射
Apr 25, 2025
5f23489
Merge branch 'master' into feat-recycle-rn
Apr 27, 2025
cbd6b1b
feat: 优化小程序recycle
Apr 27, 2025
cd5100a
feat: 优化小程序recycle
Apr 27, 2025
18f8552
feat: 优化小程序recycle
Apr 28, 2025
be207ec
chore: 修改recycle注入逻辑
Apr 28, 2025
b8407da
chore: 修改rn组件注入条件
Apr 29, 2025
a7f38c6
chore: rn环境支持通过ref获取scrollToIndex方法
Apr 29, 2025
011f8e5
fix: wx recycle
Apr 29, 2025
3ee2cc6
chore: 调整wx组件结构
Apr 29, 2025
3a725d2
chore: del 无用md
Apr 30, 2025
bdfd315
Merge branch 'feat-sticky-rn' into feat-recycle-rn
Apr 30, 2025
2b04cc0
chore: 调整ali,web组件注入逻辑
Apr 30, 2025
68b60bf
Merge branch 'master' into feat-recycle-rn
May 7, 2025
51051ba
chore: 使用enableSticky作为标识
May 8, 2025
043752b
chore: 优化props类型
May 9, 2025
c366c40
chore: 优化props类型
May 9, 2025
169e428
chore: 调整mpx-recycle-view目录
May 9, 2025
8f60230
chore: 调整mpx-recycle-view目录
May 9, 2025
570667f
Merge branch 'feat-sticky-rn' into feat-recycle-rn
May 12, 2025
a937a57
feat: init sticky ali
May 13, 2025
b7468e9
feat: init sticky ali
May 13, 2025
b0211f0
Merge branch 'feat-sticky-rn' into feat-recycle-rn
May 21, 2025
4c8cb27
Merge branch 'feat-sticky-rn' into feat-sticky-ali
May 22, 2025
2505b65
feat: 切换sticky吸附判断条件
May 23, 2025
1386c9e
fix: offsetTop导致吸附位置错误问题
May 23, 2025
deb6e01
feat: ali环境支持sticky-section
May 26, 2025
f7d80fa
Merge branch 'feat-sticky-rn' into feat-recycle-rn
May 26, 2025
e8732eb
Merge branch 'feat-recycle-rn' into feat-sticky-ali
May 26, 2025
c633673
chore: ali 支持recycle-view
May 26, 2025
e59c1cd
chore: 优化recycle-view
May 27, 2025
02dfc1f
chore: 优化sticky
May 27, 2025
47807f1
Merge branch 'master' into feat-sticky-ali
May 27, 2025
ccc8ac5
chore: 优化recyle
May 28, 2025
9bea494
chore: 优化recyle
May 28, 2025
d104685
chore: 修改recycle-view ref 获取返回值
May 28, 2025
9e15b94
Merge branch 'feat-recycle-rn' into feat-sticky-ali
May 28, 2025
e75566a
chore: 补充ali环境EXTEND_COMPONENTS_LIST
May 28, 2025
d77cc56
chore: 补充ali环境EXTEND_COMPONENTS_LIST
May 28, 2025
3d32435
Merge branch 'feat-recycle-rn' into feat-sticky-ali
May 28, 2025
e423ba8
chore: 优化sticky-header
May 29, 2025
c9f2aad
chore: 添加轮询修正逻辑
May 29, 2025
bd54ba0
chore: 添加轮询修正逻辑
May 29, 2025
bc953eb
Merge branch 'master' into feat-sticky-ali-v2
Jun 20, 2025
69ea628
chore: 优化refresh逻辑
Jun 20, 2025
a178120
chore: 优化handleStickyStateChange逻辑
Jun 20, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/webpack-plugin/lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -742,6 +742,7 @@ class MpxWebpackPlugin {
// 若配置disableRequireAsync=true, 则全平台构建不支持异步分包
supportRequireAsync: !this.options.disableRequireAsync && (this.options.mode === 'wx' || this.options.mode === 'ali' || this.options.mode === 'tt' || isWeb(this.options.mode)),
partialCompileRules: this.options.partialCompileRules,
useExtendComponents: this.options.useExtendComponents,
collectDynamicEntryInfo: ({ resource, packageName, filename, entryType, hasAsync }) => {
const curInfo = mpx.dynamicEntryInfo[packageName] = mpx.dynamicEntryInfo[packageName] || {
hasPage: false,
Expand Down
17 changes: 16 additions & 1 deletion packages/webpack-plugin/lib/json-compiler/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const createHelpers = require('../helpers')
const createJSONHelper = require('./helper')
const RecordIndependentDependency = require('../dependencies/RecordIndependentDependency')
const RecordRuntimeInfoDependency = require('../dependencies/RecordRuntimeInfoDependency')
const { MPX_DISABLE_EXTRACTOR_CACHE, RESOLVE_IGNORED_ERR, JSON_JS_EXT } = require('../utils/const')
const { MPX_DISABLE_EXTRACTOR_CACHE, RESOLVE_IGNORED_ERR, JSON_JS_EXT, EXTEND_COMPONENTS_LIST } = require('../utils/const')
const resolve = require('../utils/resolve')
const resolveTabBarPath = require('../utils/resolve-tab-bar-path')
const normalize = require('../utils/normalize')
Expand Down Expand Up @@ -186,6 +186,21 @@ module.exports = function (content) {
json.usingComponents = json.usingComponents || {}
}

if (mode === 'wx' || mode === 'ali') {
const { useExtendComponents = {} } = mpx
if (isApp && useExtendComponents[mode]) {
const extendComponents = {}
useExtendComponents[mode].forEach((name) => {
if (EXTEND_COMPONENTS_LIST[mode]?.includes(name)) {
extendComponents[name] = normalize.lib(`runtime/components/${mode}/mpx-${name}.mpx`)
} else {
emitWarning(`extend component ${name} is not supported in ${mode} environment!`)
}
})
json.usingComponents = Object.assign({}, extendComponents, json.usingComponents)
}
}

// 快应用补全json配置,必填项
if (mode === 'qa' && isApp) {
const defaultConf = {
Expand Down
17 changes: 15 additions & 2 deletions packages/webpack-plugin/lib/react/processJSON.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const getJSONContent = require('../utils/get-json-content')
const resolve = require('../utils/resolve')
const createJSONHelper = require('../json-compiler/helper')
const getRulesRunner = require('../platform/index')
const { RESOLVE_IGNORED_ERR } = require('../utils/const')
const { RESOLVE_IGNORED_ERR, EXTEND_COMPONENTS_LIST } = require('../utils/const')
const RecordResourceMapDependency = require('../dependencies/RecordResourceMapDependency')
const RecordPageConfigsMapDependency = require('../dependencies/RecordPageConfigsMapDependency')

Expand All @@ -31,7 +31,8 @@ module.exports = function (jsonContent, {
mode,
srcMode,
env,
projectRoot
projectRoot,
useExtendComponents = {}
} = mpx

const context = loaderContext.context
Expand Down Expand Up @@ -101,6 +102,18 @@ module.exports = function (jsonContent, {

if (ctorType !== 'app') {
rulesRunnerOptions.mainKey = ctorType
} else {
if (useExtendComponents[mode]) {
const extendComponents = {}
useExtendComponents[mode].forEach((name) => {
if (EXTEND_COMPONENTS_LIST[mode]?.includes(name)) {
extendComponents[name] = require.resolve(`../runtime/components/react/dist/mpx-${name}.jsx`)
} else {
emitWarning(`extend component ${name} is not supported in ${mode} environment!`)
}
})
jsonObj.usingComponents = Object.assign({}, extendComponents, jsonObj.usingComponents)
}
}

const rulesRunner = getRulesRunner(rulesRunnerOptions)
Expand Down
1 change: 1 addition & 0 deletions packages/webpack-plugin/lib/react/processScript.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ import { getComponent } from ${stringifyRequest(loaderContext, optionProcessorPa

output += buildGlobalParams({ moduleId, scriptSrcMode, loaderContext, isProduction, ctorType, jsonConfig, componentsMap, outputPath, genericsInfo, componentGenerics })
output += getRequireScript({ ctorType, script, loaderContext })

output += `export default global.__mpxOptionsMap[${JSON.stringify(moduleId)}]\n`
}

Expand Down
1 change: 0 additions & 1 deletion packages/webpack-plugin/lib/react/script-helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ const createHelpers = require('../helpers')
const parseRequest = require('../utils/parse-request')
const shallowStringify = require('../utils/shallow-stringify')
const normalize = require('../utils/normalize')

function stringifyRequest (loaderContext, request) {
return loaderUtils.stringifyRequest(loaderContext, request)
}
Expand Down
Loading