@worktile/theia 1.2.19 → 2.1.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worktile/theia",
3
- "version": "1.2.19",
3
+ "version": "2.1.0",
4
4
  "description": "theia editor",
5
5
  "author": "YanDong <nanianqiumo@foxmail.com>",
6
6
  "homepage": "https://github.com/atinc/theia#readme",
@@ -6,24 +6,24 @@ import { DropdownMode, TheCodeConfig, ToolbarItemMode } from '../../constants';
6
6
  import { DefaultToolbarItem, TheBaseElementComponent } from '../../interfaces';
7
7
  import { CodeElement } from '../../custom-types';
8
8
  import { ThyResizeEvent } from 'ngx-tethys/resizable';
9
+ import { TheContextService } from '../../services/context.service';
9
10
  import * as i0 from "@angular/core";
10
11
  export declare class TheCodeComponent extends TheBaseElementComponent<CodeElement, Editor> implements OnInit, AfterViewInit {
11
12
  elementRef: ElementRef;
12
13
  cdr: ChangeDetectorRef;
13
14
  private thyNotifyService;
15
+ private contextService;
14
16
  private ngZone;
15
17
  private config;
16
18
  startRenderCodemirror: boolean;
17
19
  dropdownMode: typeof DropdownMode;
18
- codeMirrorFocused: boolean;
19
20
  maxHeight: number;
20
21
  menus: {
21
22
  key: string;
22
23
  name: string;
23
24
  }[];
24
25
  ToolbarItemMode: typeof ToolbarItemMode;
25
- isAutoWrap: boolean;
26
- isResizing: boolean;
26
+ isFocusCode: boolean;
27
27
  resizeHeight: number;
28
28
  options: {
29
29
  mode: string;
@@ -35,26 +35,25 @@ export declare class TheCodeComponent extends TheBaseElementComponent<CodeElemen
35
35
  cursorBlinkRate: number;
36
36
  };
37
37
  actives: DefaultToolbarItem;
38
+ resizeBounds: any;
38
39
  get code(): string;
39
40
  codemirror: CodeMirrorComponent;
40
- handleCodeMousedown(event: MouseEvent): void;
41
41
  onContextChange(): void;
42
- constructor(elementRef: ElementRef, cdr: ChangeDetectorRef, thyNotifyService: ThyNotifyService, ngZone: NgZone, config: TheCodeConfig);
42
+ constructor(elementRef: ElementRef, cdr: ChangeDetectorRef, thyNotifyService: ThyNotifyService, contextService: TheContextService, ngZone: NgZone, config: TheCodeConfig);
43
43
  ngOnInit(): void;
44
44
  ngAfterViewInit(): void;
45
- focusChange(codeMirrorFocused: boolean): void;
46
45
  renderCodemirror(): void;
47
46
  initializeCodemirrorFocus(): void;
48
47
  codeChange($event: any): void;
49
48
  onDelete(event: MouseEvent): void;
50
49
  onCopy(event: MouseEvent): void;
50
+ focusChange(codeMirrorFocused: boolean): void;
51
51
  onChangeLangulage: (item: any) => void;
52
52
  useMode(): void;
53
53
  useAutoWrap(): void;
54
54
  useHeight(): void;
55
55
  useReadonly(): void;
56
56
  onResize({ height }: ThyResizeEvent): void;
57
- onStartResize(): void;
58
57
  onEndResize(): void;
59
58
  onChangeWrap(value: boolean): void;
60
59
  static ɵfac: i0.ɵɵFactoryDeclaration<TheCodeComponent, never>;
@@ -1,5 +1,5 @@
1
1
  .the-font-size-toolbar-item {
2
- width: 60px;
2
+ width: 45px;
3
3
 
4
4
  &.disabled {
5
5
  cursor: not-allowed;
@@ -11,3 +11,14 @@
11
11
  }
12
12
  }
13
13
  }
14
+ .the-toolbar-dropdown-popover.font-size {
15
+ .thy-popover-container {
16
+ min-width: 90px;
17
+ }
18
+ .dropdown {
19
+ width: 90px;
20
+ }
21
+ .action-menu-item {
22
+ text-align: center;
23
+ }
24
+ }
@@ -189,13 +189,14 @@ $thy-icon-nav-link-margin-right: 5px;
189
189
  box-shadow: $box-shadow;
190
190
  }
191
191
 
192
- .the-block-operation {
192
+ .the-code-block-operation {
193
193
  @include the-toolbar-layout();
194
194
  display: flex;
195
195
  transform: translateY(-100%);
196
196
  left: 0;
197
197
  top: -10px;
198
198
  z-index: 10;
199
+ min-width: 306px;
199
200
  .thy-select-custom {
200
201
  width: 115px;
201
202
  .form-control {