Skip to content

Commit f04189f

Browse files
committed
fix: uglify fix
1 parent 69a32f6 commit f04189f

File tree

4 files changed

+4
-16
lines changed

4 files changed

+4
-16
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
"@angular/router": "~12.2.0",
5858
"@commitlint/cli": "^13.1.0",
5959
"@commitlint/config-conventional": "^13.1.0",
60-
"@nativescript-community/text": "^1.4.31",
60+
"@nativescript-community/text": "^1.4.32",
6161
"@nativescript/angular": "12.0.6",
6262
"@nativescript/core": "8.0.8",
6363
"@nativescript/types-android": "8.0.1",

plugin/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,6 @@
3232
"license": "Apache-2.0",
3333
"readmeFilename": "README.md",
3434
"dependencies": {
35-
"@nativescript-community/text": "^1.4.31"
35+
"@nativescript-community/text": "^1.4.32"
3636
}
3737
}

src/label-common.ts

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,6 @@ import { Label as LabelViewDefinition, LineBreak, TextShadow } from './label';
2525
// init text to ensure font overrides are called
2626
init();
2727

28-
// const CHILD_SPAN = 'Span';
29-
// const CHILD_FORMATTED_TEXT = 'formattedText';
30-
// const CHILD_FORMATTED_STRING = 'FormattedString';
31-
// FormattedString.prototype.addPropertyChangeHandler = function (span: Span) {
32-
// span.on(Observable.propertyChangeEvent, this.onPropertyChange, this);
33-
// };
34-
// FormattedString.prototype.removePropertyChangeHandler = function (span: Span) {
35-
// span.off(Observable.propertyChangeEvent, this.onPropertyChange, this);
36-
// };
37-
3828
export const needFormattedStringComputation = function (
3929
target: any,
4030
propertyKey: string | Symbol,

src/label.android.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,7 @@ const sdkVersion = lazy(() => parseInt(Device.sdkVersion, 10));
5757

5858
let TextView: typeof com.nativescript.label.EllipsizingTextView;
5959

60-
const CHILD_SPAN = 'Span';
6160
const CHILD_FORMATTED_TEXT = 'formattedText';
62-
const CHILD_FORMATTED_STRING = 'FormattedString';
6361

6462
const resetSymbol = Symbol('textPropertyDefault');
6563
enum SuspendType {
@@ -281,7 +279,7 @@ abstract class LabelBase extends View implements LabelViewDefinition {
281279
}
282280

283281
public _addChildFromBuilder(name: string, value: any): void {
284-
if (name === CHILD_SPAN) {
282+
if (name === Span.name) {
285283
if (!this.formattedText) {
286284
let formattedText: FormattedString;
287285
if (overrideSpanAndFormattedStringEnabled) {
@@ -295,7 +293,7 @@ abstract class LabelBase extends View implements LabelViewDefinition {
295293
} else {
296294
this.formattedText.spans.push(value);
297295
}
298-
} else if (name === CHILD_FORMATTED_TEXT || name === CHILD_FORMATTED_STRING) {
296+
} else if (name === CHILD_FORMATTED_TEXT || name === FormattedString.name) {
299297
this.formattedText = value;
300298
value.parent = this;
301299
}

0 commit comments

Comments
 (0)