去除画布打印信息
This commit is contained in:
@@ -27,7 +27,7 @@ export class ThumbnailManager {
|
||||
const { layer } = findLayerRecursively(this.layers.value, layerId);
|
||||
|
||||
if (!fabricObjects || fabricObjects.length === 0) {
|
||||
console.warn("⚠️ 无法生成缩略图:没有可栅格化的对象 返回空缩略图");
|
||||
// console.warn("⚠️ 无法生成缩略图:没有可栅格化的对象 返回空缩略图");
|
||||
// 如果没有对象,返回默认缩略图
|
||||
if (layer) {
|
||||
layer.thumbnailUrl = this.defaultThumbnail; // 更新图层对象的缩略图
|
||||
@@ -123,7 +123,7 @@ export class ThumbnailManager {
|
||||
*/
|
||||
_collectLayersAndObjects(layerId) {
|
||||
if (!layerId) {
|
||||
console.warn("⚠️ 无效的图层ID,无法收集对象");
|
||||
// console.warn("⚠️ 无效的图层ID,无法收集对象");
|
||||
return [];
|
||||
}
|
||||
|
||||
@@ -199,17 +199,17 @@ export class ThumbnailManager {
|
||||
// 提取排序后的对象
|
||||
const objectsToRasterize = objectsWithZIndex.map((item) => item.object);
|
||||
|
||||
console.log(
|
||||
`📊 收集到 ${layersToRasterize.length} 个图层,${objectsToRasterize.length} 个对象进行栅格化`
|
||||
);
|
||||
console.log(
|
||||
"🔢 对象z-index顺序:",
|
||||
objectsWithZIndex.map((item) => ({
|
||||
id: item.object.id,
|
||||
type: item.object.type,
|
||||
zIndex: item.zIndex,
|
||||
}))
|
||||
);
|
||||
// console.log(
|
||||
// `📊 收集到 ${layersToRasterize.length} 个图层,${objectsToRasterize.length} 个对象进行栅格化`
|
||||
// );
|
||||
// console.log(
|
||||
// "🔢 对象z-index顺序:",
|
||||
// objectsWithZIndex.map((item) => ({
|
||||
// id: item.object.id,
|
||||
// type: item.object.type,
|
||||
// zIndex: item.zIndex,
|
||||
// }))
|
||||
// );
|
||||
|
||||
return objectsToRasterize;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user