MCPcopy Index your code
hub / github.com/angular/components / _setIndentInput

Method _setIndentInput

src/cdk/tree/padding.ts:118–131  ·  view source on GitHub ↗

* This has been extracted to a util because of TS 4 and VE. * View Engine doesn't support property rename inheritance. * TS 4.0 doesn't allow properties to override accessors or vice-versa. * @docs-private

(indent: number | string)

Source from the content-addressed store, hash-verified

116 * @docs-private
117 */
118 protected _setIndentInput(indent: number | string) {
119 let value = indent;
120 let units = 'px';
121
122 if (typeof indent === 'string') {
123 const parts = indent.split(cssUnitPattern);
124 value = parts[0];
125 units = parts[1] || units;
126 }
127
128 this.indentUnits = units;
129 this._indent = numberAttribute(value);
130 this._setPadding();
131 }
132}

Callers 2

indentMethod · 0.95
indentMethod · 0.80

Calls 1

_setPaddingMethod · 0.95

Tested by

no test coverage detected