@blocklet/pages-kit-core 0.1.0 → 0.4.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/core.d.ts +2 -2
- package/lib/cjs/page.js +2 -1
- package/lib/cjs/tsconfig.tsbuildinfo +1 -1
- package/lib/esm/core.d.ts +2 -2
- package/lib/esm/page.js +2 -1
- package/lib/esm/tsconfig.tsbuildinfo +1 -1
- package/lib/types/core.d.ts +2 -2
- package/lib/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
package/lib/cjs/core.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Block, CoreConstructor, CoreOptions,
|
|
1
|
+
import { Block, CoreConstructor, CoreOptions, Page } from '@types';
|
|
2
2
|
import { Dataset } from './dataset';
|
|
3
|
-
export declare class Core<B extends Block = Block, D extends Dataset = Dataset, P extends Page = Page>
|
|
3
|
+
export declare class Core<B extends Block = Block, D extends Dataset = Dataset, P extends Page = Page> {
|
|
4
4
|
readonly blocks: Map<string, B>;
|
|
5
5
|
readonly datasets: Map<string, D>;
|
|
6
6
|
readonly pages: Map<string, P>;
|
package/lib/cjs/page.js
CHANGED
|
@@ -57,7 +57,8 @@ class Page {
|
|
|
57
57
|
}
|
|
58
58
|
// 合并配置传入 Block
|
|
59
59
|
const sectionProps = Object.assign(Object.assign({ key: section.id, id: section.id }, section.config), section.properties);
|
|
60
|
-
|
|
60
|
+
const result = yield block.render(sectionProps, options);
|
|
61
|
+
return result;
|
|
61
62
|
}
|
|
62
63
|
catch (error) {
|
|
63
64
|
console.error(`Failed to render section ${section.id}:`, error);
|