@univerjs/core 0.17.0 → 0.18.0

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.
Files changed (128) hide show
  1. package/lib/cjs/facade.js +1 -1
  2. package/lib/cjs/index.js +9 -8
  3. package/lib/es/facade.js +1 -1479
  4. package/lib/es/index.js +9 -20335
  5. package/lib/facade.js +1 -1479
  6. package/lib/index.js +9 -20335
  7. package/lib/types/common/async.d.ts +16 -1
  8. package/lib/types/common/di.d.ts +18 -2
  9. package/lib/types/common/interceptor.d.ts +16 -1
  10. package/lib/types/common/invert-color/invert-hsl.d.ts +16 -1
  11. package/lib/types/common/invert-color/invert-rgb.d.ts +16 -1
  12. package/lib/types/common/unit.d.ts +17 -2
  13. package/lib/types/docs/data-model/document-data-model.d.ts +24 -9
  14. package/lib/types/docs/data-model/empty-snapshot.d.ts +16 -1
  15. package/lib/types/docs/data-model/json-x/json-x.d.ts +19 -4
  16. package/lib/types/docs/data-model/preset-list-type.d.ts +16 -1
  17. package/lib/types/docs/data-model/replacement.d.ts +16 -1
  18. package/lib/types/docs/data-model/rich-text-builder.d.ts +21 -5
  19. package/lib/types/docs/data-model/text-x/action-iterator.d.ts +17 -1
  20. package/lib/types/docs/data-model/text-x/action-types.d.ts +17 -2
  21. package/lib/types/docs/data-model/text-x/apply-utils/common.d.ts +16 -1
  22. package/lib/types/docs/data-model/text-x/apply-utils/delete-apply.d.ts +16 -1
  23. package/lib/types/docs/data-model/text-x/apply-utils/insert-apply.d.ts +16 -1
  24. package/lib/types/docs/data-model/text-x/apply-utils/update-apply.d.ts +16 -1
  25. package/lib/types/docs/data-model/text-x/apply.d.ts +17 -2
  26. package/lib/types/docs/data-model/text-x/build-utils/custom-decoration.d.ts +17 -2
  27. package/lib/types/docs/data-model/text-x/build-utils/custom-range.d.ts +17 -2
  28. package/lib/types/docs/data-model/text-x/build-utils/drawings.d.ts +19 -4
  29. package/lib/types/docs/data-model/text-x/build-utils/index.d.ts +24 -9
  30. package/lib/types/docs/data-model/text-x/build-utils/paragraph.d.ts +18 -3
  31. package/lib/types/docs/data-model/text-x/build-utils/parse.d.ts +16 -1
  32. package/lib/types/docs/data-model/text-x/build-utils/selection.d.ts +17 -2
  33. package/lib/types/docs/data-model/text-x/build-utils/text-x-utils.d.ts +23 -7
  34. package/lib/types/docs/data-model/text-x/text-x.d.ts +18 -3
  35. package/lib/types/docs/data-model/text-x/transform-utils.d.ts +17 -2
  36. package/lib/types/docs/data-model/text-x/utils.d.ts +34 -19
  37. package/lib/types/docs/data-model/utils.d.ts +16 -1
  38. package/lib/types/facade/f-base.d.ts +17 -1
  39. package/lib/types/facade/f-blob.d.ts +17 -1
  40. package/lib/types/facade/f-doc.d.ts +17 -1
  41. package/lib/types/facade/f-enum.d.ts +15 -0
  42. package/lib/types/facade/f-event-registry.d.ts +19 -3
  43. package/lib/types/facade/f-event.d.ts +17 -2
  44. package/lib/types/facade/f-hooks.d.ts +17 -1
  45. package/lib/types/facade/f-univer.d.ts +20 -3
  46. package/lib/types/facade/f-usermanager.d.ts +17 -1
  47. package/lib/types/facade/f-util.d.ts +15 -0
  48. package/lib/types/observer/observable.d.ts +17 -1
  49. package/lib/types/services/authz-io/authz-io-local.service.d.ts +17 -2
  50. package/lib/types/services/authz-io/type.d.ts +18 -3
  51. package/lib/types/services/command/command.service.d.ts +20 -4
  52. package/lib/types/services/config/config.service.d.ts +18 -3
  53. package/lib/types/services/confirm/confirm.service.d.ts +17 -2
  54. package/lib/types/services/context/context.service.d.ts +16 -1
  55. package/lib/types/services/error/error.service.d.ts +16 -1
  56. package/lib/types/services/image-io/image-io.service.d.ts +18 -3
  57. package/lib/types/services/image-io/url-image.service.d.ts +17 -2
  58. package/lib/types/services/instance/instance.service.d.ts +22 -5
  59. package/lib/types/services/lifecycle/lifecycle.service.d.ts +16 -1
  60. package/lib/types/services/local-storage/local-storage.service.d.ts +1 -1
  61. package/lib/types/services/locale/locale.service.d.ts +17 -2
  62. package/lib/types/services/log/log.service.d.ts +16 -1
  63. package/lib/types/services/mention-io/mention-io-local.service.d.ts +16 -1
  64. package/lib/types/services/mention-io/type.d.ts +18 -3
  65. package/lib/types/services/permission/permission.service.d.ts +18 -2
  66. package/lib/types/services/permission/type.d.ts +20 -5
  67. package/lib/types/services/plugin/plugin-override.d.ts +16 -1
  68. package/lib/types/services/plugin/plugin.service.d.ts +18 -2
  69. package/lib/types/services/resource-loader/resource-loader.service.d.ts +17 -2
  70. package/lib/types/services/resource-loader/type.d.ts +17 -2
  71. package/lib/types/services/resource-manager/resource-manager.service.d.ts +19 -4
  72. package/lib/types/services/resource-manager/type.d.ts +19 -4
  73. package/lib/types/services/theme/theme.service.d.ts +16 -1
  74. package/lib/types/services/undoredo/undoredo.service.d.ts +22 -5
  75. package/lib/types/services/user-manager/const.d.ts +17 -1
  76. package/lib/types/services/user-manager/user-manager.service.d.ts +17 -2
  77. package/lib/types/shared/after-init-apply.d.ts +16 -1
  78. package/lib/types/shared/cache/image-cache.d.ts +16 -1
  79. package/lib/types/shared/check-if-move.d.ts +17 -2
  80. package/lib/types/shared/common.d.ts +22 -7
  81. package/lib/types/shared/compare.d.ts +16 -1
  82. package/lib/types/shared/dayjs.d.ts +16 -1
  83. package/lib/types/shared/doc-tool.d.ts +16 -1
  84. package/lib/types/shared/generate.d.ts +17 -2
  85. package/lib/types/shared/lifecycle.d.ts +18 -2
  86. package/lib/types/shared/lru/lru-map.d.ts +16 -1
  87. package/lib/types/shared/object-matrix-query.d.ts +16 -1
  88. package/lib/types/shared/object-matrix.d.ts +17 -2
  89. package/lib/types/shared/r-tree.d.ts +18 -2
  90. package/lib/types/shared/range.d.ts +17 -2
  91. package/lib/types/shared/rectangle.d.ts +17 -2
  92. package/lib/types/shared/rxjs.d.ts +18 -2
  93. package/lib/types/shared/tools.d.ts +17 -23
  94. package/lib/types/sheets/clone.d.ts +17 -2
  95. package/lib/types/sheets/column-manager.d.ts +19 -4
  96. package/lib/types/sheets/empty-snapshot.d.ts +16 -1
  97. package/lib/types/sheets/range.d.ts +23 -6
  98. package/lib/types/sheets/row-manager.d.ts +20 -5
  99. package/lib/types/sheets/sheet-skeleton.d.ts +21 -5
  100. package/lib/types/sheets/sheet-snapshot-utils.d.ts +16 -1
  101. package/lib/types/sheets/span-model.d.ts +16 -1
  102. package/lib/types/sheets/styles.d.ts +18 -3
  103. package/lib/types/sheets/typedef.d.ts +23 -7
  104. package/lib/types/sheets/util.d.ts +20 -4
  105. package/lib/types/sheets/workbook.d.ts +19 -4
  106. package/lib/types/sheets/worksheet.d.ts +25 -7
  107. package/lib/types/skeleton.d.ts +16 -1
  108. package/lib/types/slides/slide-model.d.ts +22 -6
  109. package/lib/types/types/const/const.d.ts +18 -2
  110. package/lib/types/types/const/page-size.d.ts +16 -1
  111. package/lib/types/types/interfaces/i-cell-custom-render.d.ts +20 -5
  112. package/lib/types/types/interfaces/i-cell-validation-data.d.ts +17 -2
  113. package/lib/types/types/interfaces/i-data-validation.d.ts +21 -6
  114. package/lib/types/types/interfaces/i-document-data-interceptor.d.ts +16 -1
  115. package/lib/types/types/interfaces/i-document-data.d.ts +20 -5
  116. package/lib/types/types/interfaces/i-drawing.d.ts +56 -3
  117. package/lib/types/types/interfaces/i-mention.d.ts +16 -1
  118. package/lib/types/types/interfaces/i-need-check-disposable.d.ts +16 -1
  119. package/lib/types/types/interfaces/i-placeholder.d.ts +16 -1
  120. package/lib/types/types/interfaces/i-shape-properties.d.ts +17 -2
  121. package/lib/types/types/interfaces/i-slide-data.d.ts +26 -11
  122. package/lib/types/types/interfaces/i-style-data.d.ts +19 -4
  123. package/lib/types/univer.d.ts +26 -10
  124. package/lib/umd/facade.js +1 -1
  125. package/lib/umd/index.js +9 -8
  126. package/package.json +9 -9
  127. package/lib/types/docs/data-model/text-x/build-utils/__test__/custom-range.spec.d.ts +0 -16
  128. package/lib/types/docs/data-model/text-x/build-utils/__test__/selection.spec.d.ts +0 -16
@@ -1,10 +1,25 @@
1
- import { IDisposable } from '../../common/di';
2
- import { Nullable } from '../../shared/types';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IDisposable } from '../../common/di';
17
+ import type { Nullable } from '../../shared/types';
3
18
  import { Observable } from 'rxjs';
4
19
  /**
5
20
  * IConfig provides universal configuration for the whole application.
6
21
  */
7
- export declare const IConfigService: import('@wendellhu/redi').IdentifierDecorator<IConfigService>;
22
+ export declare const IConfigService: import("@wendellhu/redi").IdentifierDecorator<IConfigService>;
8
23
  interface IConfigOptions {
9
24
  /**
10
25
  * Whether the configuration is read-only.
@@ -1,6 +1,21 @@
1
- import { IDisposable } from '../../common/di';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IDisposable } from '../../common/di';
2
17
  import { Subject } from 'rxjs';
3
- export declare const IConfirmService: import('@wendellhu/redi').IdentifierDecorator<IConfirmService<unknown>>;
18
+ export declare const IConfirmService: import("@wendellhu/redi").IdentifierDecorator<IConfirmService<unknown>>;
4
19
  export interface IConfirmService<T = unknown> {
5
20
  readonly confirmOptions$: Subject<T[]>;
6
21
  open(params: T): IDisposable;
@@ -1,3 +1,18 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
1
16
  import { Observable } from 'rxjs';
2
17
  import { Disposable } from '../../shared/lifecycle';
3
18
  export interface IContextService {
@@ -8,7 +23,7 @@ export interface IContextService {
8
23
  setContextValue(key: string, value: boolean): void;
9
24
  subscribeContextValue$(key: string): Observable<boolean>;
10
25
  }
11
- export declare const IContextService: import('@wendellhu/redi').IdentifierDecorator<IContextService>;
26
+ export declare const IContextService: import("@wendellhu/redi").IdentifierDecorator<IContextService>;
12
27
  export declare class ContextService extends Disposable implements IContextService {
13
28
  private _contextChanged$;
14
29
  readonly contextChanged$: Observable<{
@@ -1,10 +1,25 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
1
16
  import { Disposable } from '../../shared/lifecycle';
2
17
  export interface IError {
3
18
  errorKey: string;
4
19
  }
5
20
  export declare class ErrorService extends Disposable {
6
21
  private readonly _error$;
7
- error$: import('rxjs').Observable<IError>;
22
+ error$: import("rxjs").Observable<IError>;
8
23
  dispose(): void;
9
24
  emit(key: string): void;
10
25
  }
@@ -1,5 +1,20 @@
1
- import { Observable } from 'rxjs';
2
- import { Nullable } from '../../shared/types';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
17
+ import type { Nullable } from '../../shared/types';
3
18
  /**
4
19
  * The type of image data source
5
20
  */
@@ -39,4 +54,4 @@ export interface IImageIoService {
39
54
  getImageSourceCache(source: string, imageSourceType: ImageSourceType): Nullable<HTMLImageElement>;
40
55
  addImageSourceCache(source: string, imageSourceType: ImageSourceType, imageSource: Nullable<HTMLImageElement>): void;
41
56
  }
42
- export declare const IImageIoService: import('@wendellhu/redi').IdentifierDecorator<IImageIoService>;
57
+ export declare const IImageIoService: import("@wendellhu/redi").IdentifierDecorator<IImageIoService>;
@@ -1,4 +1,19 @@
1
- import { IDisposable } from '../../common/di';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IDisposable } from '../../common/di';
2
17
  export interface IURLImageService {
3
18
  /**
4
19
  * Get image url or base64.
@@ -19,4 +34,4 @@ export interface IURLImageService {
19
34
  */
20
35
  registerURLImageDownloader(downloader: (url: string) => Promise<string>): IDisposable;
21
36
  }
22
- export declare const IURLImageService: import('@wendellhu/redi').IdentifierDecorator<IURLImageService>;
37
+ export declare const IURLImageService: import("@wendellhu/redi").IdentifierDecorator<IURLImageService>;
@@ -1,7 +1,24 @@
1
- import { Observable } from 'rxjs';
2
- import { IDisposable, Injector } from '../../common/di';
3
- import { UnitModel, UnitType, UniverInstanceType } from '../../common/unit';
4
- import { Nullable } from '../../shared';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
17
+ import type { IDisposable } from '../../common/di';
18
+ import type { UnitModel, UnitType } from '../../common/unit';
19
+ import type { Nullable } from '../../shared';
20
+ import { Injector } from '../../common/di';
21
+ import { UniverInstanceType } from '../../common/unit';
5
22
  import { DocumentDataModel } from '../../docs/data-model/document-data-model';
6
23
  import { Disposable } from '../../shared/lifecycle';
7
24
  import { Workbook } from '../../sheets/workbook';
@@ -67,7 +84,7 @@ export interface IUniverInstanceService {
67
84
  /** @deprecated */
68
85
  getCurrentUniverDocInstance(): Nullable<DocumentDataModel>;
69
86
  }
70
- export declare const IUniverInstanceService: import('@wendellhu/redi').IdentifierDecorator<IUniverInstanceService>;
87
+ export declare const IUniverInstanceService: import("@wendellhu/redi").IdentifierDecorator<IUniverInstanceService>;
71
88
  export declare class UniverInstanceService extends Disposable implements IUniverInstanceService {
72
89
  private readonly _injector;
73
90
  private readonly _contextService;
@@ -1,4 +1,19 @@
1
- import { Observable } from 'rxjs';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
2
17
  import { Disposable } from '../../shared/lifecycle';
3
18
  import { ILogService } from '../log/log.service';
4
19
  import { LifecycleStages } from './lifecycle';
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- export declare const ILocalStorageService: import('@wendellhu/redi').IdentifierDecorator<ILocalStorageService>;
16
+ export declare const ILocalStorageService: import("@wendellhu/redi").IdentifierDecorator<ILocalStorageService>;
17
17
  export type LocalStorageValueTypes = string;
18
18
  export interface ILocalStorageService {
19
19
  getItem<T>(key: string): Promise<T | null>;
@@ -1,4 +1,19 @@
1
- import { ILanguagePack, ILocales, LanguageValue } from '../../shared/locale';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { ILanguagePack, ILocales, LanguageValue } from '../../shared/locale';
2
17
  import { Subject } from 'rxjs';
3
18
  import { Disposable } from '../../shared/lifecycle';
4
19
  import { LocaleType } from '../../types/enum/locale-type';
@@ -7,7 +22,7 @@ import { LocaleType } from '../../types/enum/locale-type';
7
22
  */
8
23
  export declare class LocaleService extends Disposable {
9
24
  private _currentLocale$;
10
- readonly currentLocale$: import('rxjs').Observable<LocaleType>;
25
+ readonly currentLocale$: import("rxjs").Observable<LocaleType>;
11
26
  private get _currentLocale();
12
27
  private _locales;
13
28
  localeChanged$: Subject<void>;
@@ -1,3 +1,18 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
1
16
  import { Disposable } from '../../shared/lifecycle';
2
17
  export declare enum LogLevel {
3
18
  SILENT = 0,
@@ -15,7 +30,7 @@ export interface ILogService {
15
30
  deprecate(...args: ArgsType): void;
16
31
  setLogLevel(enabled: LogLevel): void;
17
32
  }
18
- export declare const ILogService: import('@wendellhu/redi').IdentifierDecorator<ILogService>;
33
+ export declare const ILogService: import("@wendellhu/redi").IdentifierDecorator<ILogService>;
19
34
  export declare class DesktopLogService extends Disposable implements ILogService {
20
35
  private _logLevel;
21
36
  private _deduction;
@@ -1,4 +1,19 @@
1
- import { IListMentionParam, IListMentionResponse, IMentionIOService } from './type';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IListMentionParam, IListMentionResponse, IMentionIOService } from './type';
2
17
  import { UserManagerService } from '../user-manager/user-manager.service';
3
18
  export declare class MentionIOLocalService implements IMentionIOService {
4
19
  private _userManagerService;
@@ -1,5 +1,20 @@
1
- import { MentionType } from '../../types/enum';
2
- import { IMention } from '../../types/interfaces';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { MentionType } from '../../types/enum';
17
+ import type { IMention } from '../../types/interfaces';
3
18
  export interface IListMentionParam {
4
19
  search?: string;
5
20
  type?: MentionType;
@@ -22,4 +37,4 @@ export interface IListMentionResponse {
22
37
  export interface IMentionIOService {
23
38
  list(params: IListMentionParam): Promise<IListMentionResponse>;
24
39
  }
25
- export declare const IMentionIOService: import('@wendellhu/redi').IdentifierDecorator<IMentionIOService>;
40
+ export declare const IMentionIOService: import("@wendellhu/redi").IdentifierDecorator<IMentionIOService>;
@@ -1,5 +1,21 @@
1
- import { Observable, BehaviorSubject } from 'rxjs';
2
- import { IPermissionPoint, IPermissionService } from './type';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
17
+ import type { IPermissionPoint, IPermissionService } from './type';
18
+ import { BehaviorSubject } from 'rxjs';
3
19
  import { Disposable } from '../../shared';
4
20
  export declare class PermissionService extends Disposable implements IPermissionService {
5
21
  private _permissionPointMap;
@@ -1,7 +1,22 @@
1
- import { UnitAction, UnitObject } from '@univerjs/protocol';
2
- import { BehaviorSubject, Observable } from 'rxjs';
3
- import { Nullable } from '../../shared/types';
4
- import { IRange } from '../../sheets/typedef';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { UnitAction, UnitObject } from '@univerjs/protocol';
17
+ import type { BehaviorSubject, Observable } from 'rxjs';
18
+ import type { Nullable } from '../../shared/types';
19
+ import type { IRange } from '../../sheets/typedef';
5
20
  export declare enum PermissionStatus {
6
21
  INIT = "init",
7
22
  FETCHING = "fetching",
@@ -41,4 +56,4 @@ export interface IPermissionService {
41
56
  getShowComponents(): boolean;
42
57
  setShowComponents(showComponents: boolean): void;
43
58
  }
44
- export declare const IPermissionService: import('@wendellhu/redi').IdentifierDecorator<IPermissionService>;
59
+ export declare const IPermissionService: import("@wendellhu/redi").IdentifierDecorator<IPermissionService>;
@@ -1,4 +1,19 @@
1
- import { Dependency, DependencyIdentifier, DependencyItem } from '../../common/di';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Dependency, DependencyIdentifier, DependencyItem } from '../../common/di';
2
17
  export type NullableDependencyPair<T> = [DependencyIdentifier<T>, DependencyItem<T> | null];
3
18
  /**
4
19
  * Overrides the dependencies defined in the plugin. Only dependencies that are identified by `IdentifierDecorator` can be overridden.
@@ -1,5 +1,21 @@
1
- import { Ctor, IDisposable, Injector } from '../../common/di';
2
- import { UnitType } from '../../common/unit';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Ctor, IDisposable } from '../../common/di';
17
+ import type { UnitType } from '../../common/unit';
18
+ import { Injector } from '../../common/di';
3
19
  import { Disposable } from '../../shared/lifecycle';
4
20
  import { LifecycleService } from '../lifecycle/lifecycle.service';
5
21
  import { ILogService } from '../log/log.service';
@@ -1,4 +1,19 @@
1
- import { IResourceLoaderService } from './type';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IResourceLoaderService } from './type';
2
17
  import { Disposable } from '../../shared/lifecycle';
3
18
  import { IUniverInstanceService } from '../instance/instance.service';
4
19
  import { IResourceManagerService } from '../resource-manager/type';
@@ -8,6 +23,6 @@ export declare class ResourceLoaderService extends Disposable implements IResour
8
23
  constructor(_resourceManagerService: IResourceManagerService, _univerInstanceService: IUniverInstanceService);
9
24
  private _init;
10
25
  saveUnit<T = object>(unitId: string): ({
11
- resources: import('../..').IResources;
26
+ resources: import("../..").IResources;
12
27
  } & T) | null;
13
28
  }
@@ -1,5 +1,20 @@
1
- import { IResources } from '../resource-manager/type';
2
- export declare const IResourceLoaderService: import('@wendellhu/redi').IdentifierDecorator<IResourceLoaderService>;
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IResources } from '../resource-manager/type';
17
+ export declare const IResourceLoaderService: import("@wendellhu/redi").IdentifierDecorator<IResourceLoaderService>;
3
18
  export interface IResourceLoaderService {
4
19
  saveUnit<T = object>(unitId: string): T & {
5
20
  resources: IResources;
@@ -1,12 +1,27 @@
1
- import { UniverInstanceType } from '../../common/unit';
2
- import { IResourceHook, IResourceManagerService, IResourceName, IResources } from './type';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { UniverInstanceType } from '../../common/unit';
17
+ import type { IResourceHook, IResourceManagerService, IResourceName, IResources } from './type';
3
18
  import { Disposable } from '../../shared/lifecycle';
4
19
  import { ILogService } from '../log/log.service';
5
20
  export declare class ResourceManagerService extends Disposable implements IResourceManagerService {
6
21
  private readonly _logService;
7
22
  private _resourceMap;
8
23
  private readonly _register$;
9
- readonly register$: import('rxjs').Observable<IResourceHook<any>>;
24
+ readonly register$: import("rxjs").Observable<IResourceHook<any>>;
10
25
  constructor(_logService: ILogService);
11
26
  getAllResourceHooks(): IResourceHook<any>[];
12
27
  getResources(unitId: string): IResources;
@@ -15,7 +30,7 @@ export declare class ResourceManagerService extends Disposable implements IResou
15
30
  name: `SHEET_${string}_PLUGIN` | `DOC_${string}_PLUGIN`;
16
31
  data: string;
17
32
  }[];
18
- registerPluginResource<T = unknown>(hook: IResourceHook<T>): import('@wendellhu/redi').IDisposable;
33
+ registerPluginResource<T = unknown>(hook: IResourceHook<T>): import("@wendellhu/redi").IDisposable;
19
34
  disposePluginResource(pluginName: IResourceName): void;
20
35
  loadResources(unitId: string, resources?: IResources): void;
21
36
  unloadResources(unitId: string, type: UniverInstanceType): void;
@@ -1,6 +1,21 @@
1
- import { Observable } from 'rxjs';
2
- import { IDisposable } from '../../common/di';
3
- import { UniverInstanceType } from '../../common/unit';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
17
+ import type { IDisposable } from '../../common/di';
18
+ import type { UniverInstanceType } from '../../common/unit';
4
19
  export type IResources = Array<{
5
20
  id?: string;
6
21
  name: string;
@@ -26,5 +41,5 @@ export interface IResourceManagerService {
26
41
  loadResources: (unitId: string, resources?: IResources) => void;
27
42
  unloadResources(unitId: string, type: UniverInstanceType): void;
28
43
  }
29
- export declare const IResourceManagerService: import('@wendellhu/redi').IdentifierDecorator<IResourceManagerService>;
44
+ export declare const IResourceManagerService: import("@wendellhu/redi").IdentifierDecorator<IResourceManagerService>;
30
45
  export {};
@@ -1,4 +1,19 @@
1
- import { Observable } from 'rxjs';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
2
17
  import { defaultTheme } from '@univerjs/themes';
3
18
  import { Disposable } from '../../shared/lifecycle';
4
19
  export type Theme = typeof defaultTheme;
@@ -1,8 +1,25 @@
1
- import { Observable, BehaviorSubject } from 'rxjs';
2
- import { IAccessor, IDisposable } from '../../common/di';
3
- import { Nullable } from '../../shared/types';
4
- import { IMutationInfo, CommandType, ICommandService } from '../command/command.service';
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { Observable } from 'rxjs';
17
+ import type { IAccessor, IDisposable } from '../../common/di';
18
+ import type { Nullable } from '../../shared/types';
19
+ import type { IMutationInfo } from '../command/command.service';
20
+ import { BehaviorSubject } from 'rxjs';
5
21
  import { Disposable } from '../../shared/lifecycle';
22
+ import { CommandType, ICommandService } from '../command/command.service';
6
23
  import { IContextService } from '../context/context.service';
7
24
  import { IUniverInstanceService } from '../instance/instance.service';
8
25
  export interface IUndoRedoItem {
@@ -50,7 +67,7 @@ export interface IUndoRedoCommandInfos {
50
67
  undos: IMutationInfo[];
51
68
  redos: IMutationInfo[];
52
69
  }
53
- export declare const IUndoRedoService: import('@wendellhu/redi').IdentifierDecorator<IUndoRedoService>;
70
+ export declare const IUndoRedoService: import("@wendellhu/redi").IdentifierDecorator<IUndoRedoService>;
54
71
  export interface IUndoRedoStatus {
55
72
  undos: number;
56
73
  redos: number;