import {
  __decorateClass
} from "../../chunks/chunk.QU3DSPNU.js";
import { property } from "lit/decorators.js";
import { html, unsafeStatic } from "lit/static-html.js";
import { tokens } from "../../tokens.style.js";
import { styleExpressionProperty } from "../../utils/decorators/style-expression-property.js";
import { gdsCustomElement } from "../../utils/helpers/custom-element-scoping.js";
import { GdsDiv } from "../div/div.component.js";
import { defaultStyles } from "./default-typography.styles.js";
import TextStyles from "./text.styles.js";
let GdsText = class extends GdsDiv {
  constructor() {
    super(...arguments);
    this.tag = "span";
  }
  render() {
    const TAG = unsafeStatic(encodeURI(this.tag));
    return html`<${TAG} tag><slot></slot></${TAG}>`;
  }
};
GdsText.styles = [tokens, defaultStyles, TextStyles];
__decorateClass([
  property({ type: String })
], GdsText.prototype, "tag", 2);
__decorateClass([
  styleExpressionProperty({
    selector: "[tag]",
    styleTemplate: (_prop, values) => {
      const size = values[0];
      return `font: var(--gds-sys-text-${size});`;
    }
  })
], GdsText.prototype, "font", 2);
__decorateClass([
  styleExpressionProperty({
    selector: "[tag]",
    valueTemplate: (v) => `var(--gds-sys-text-weight-${v})`
  })
], GdsText.prototype, "font-weight", 2);
__decorateClass([
  styleExpressionProperty()
], GdsText.prototype, "text-transform", 2);
__decorateClass([
  styleExpressionProperty({
    selector: "[tag]"
  })
], GdsText.prototype, "text-decoration", 2);
__decorateClass([
  styleExpressionProperty({
    selector: "[tag]",
    styleTemplate: (_prop, values) => {
      return `overflow: hidden;
      text-overflow: ellipsis;
      display: -webkit-box;
      -webkit-line-clamp: ${values[0]};
      -webkit-box-orient: vertical;`;
    }
  })
], GdsText.prototype, "lines", 2);
GdsText = __decorateClass([
  gdsCustomElement("gds-text")
], GdsText);
export {
  GdsText
};
