@ni/nimble-components 33.2.0 → 33.4.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.
@@ -4700,7 +4700,10 @@ const ty="underline",ey="outline",ny="block",iy=Mt`
4700
4700
 
4701
4701
  :host([disabled]) {
4702
4702
  color: ${Gc};
4703
- cursor: default;
4703
+ }
4704
+
4705
+ :host([disabled][appearance-readonly]) {
4706
+ color: ${Wc};
4704
4707
  }
4705
4708
 
4706
4709
  .label {
@@ -4713,6 +4716,10 @@ const ty="underline",ey="outline",ny="block",iy=Mt`
4713
4716
  color: ${fd};
4714
4717
  }
4715
4718
 
4719
+ :host([disabled][appearance-readonly]) .label {
4720
+ color: ${pd};
4721
+ }
4722
+
4716
4723
  .root {
4717
4724
  position: relative;
4718
4725
  display: flex;
@@ -4798,14 +4805,22 @@ const ty="underline",ey="outline",ny="block",iy=Mt`
4798
4805
  outline: none;
4799
4806
  }
4800
4807
 
4808
+ :host([disabled][appearance-readonly]) .control {
4809
+ cursor: text;
4810
+ }
4811
+
4801
4812
  .control::placeholder {
4802
4813
  color: ${pd};
4803
4814
  }
4804
4815
 
4805
- .control[disabled]::placeholder {
4816
+ :host([disabled]) .control::placeholder {
4806
4817
  color: ${Gc};
4807
4818
  }
4808
4819
 
4820
+ :host([disabled][appearance-readonly]) .control::placeholder {
4821
+ color: ${pd};
4822
+ }
4823
+
4809
4824
  .controls {
4810
4825
  display: contents;
4811
4826
  }
@@ -4876,7 +4891,7 @@ const ty="underline",ey="outline",ny="block",iy=Mt`
4876
4891
  >
4877
4892
  <slot ${ie("defaultSlottedNodes")}></slot>
4878
4893
  </label>`)
4879
- class oy extends(Ug(hv(ts))){constructor(){super(...arguments),this.appearance=ty}connectedCallback(){super.connectedCallback(),this.control.setAttribute("role","spinbutton")}}t([ft],oy.prototype,"appearance",void 0)
4894
+ class oy extends(Ug(hv(ts))){constructor(){super(...arguments),this.appearance=ty,this.appearanceReadOnly=!1}connectedCallback(){super.connectedCallback(),this.control.setAttribute("role","spinbutton")}}t([ft],oy.prototype,"appearance",void 0),t([ft({attribute:"appearance-readonly",mode:"boolean"})],oy.prototype,"appearanceReadOnly",void 0)
4880
4895
  const ry=oy.compose({baseName:"number-field",baseClass:ts,template:(t,e)=>Q`
4881
4896
  <template class="${t=>t.readOnly?"readonly":""}">
4882
4897
  ${sy}
@@ -12451,6 +12466,10 @@ const KB="outline",YB="block",XB=Mt`
12451
12466
  color: ${Gc};
12452
12467
  }
12453
12468
 
12469
+ :host([disabled][appearance-readonly]) {
12470
+ color: ${Wc};
12471
+ }
12472
+
12454
12473
  .label {
12455
12474
  display: block;
12456
12475
  color: ${pd};
@@ -12461,6 +12480,10 @@ const KB="outline",YB="block",XB=Mt`
12461
12480
  color: ${fd};
12462
12481
  }
12463
12482
 
12483
+ :host([disabled][appearance-readonly]) .label {
12484
+ color: ${pd};
12485
+ }
12486
+
12464
12487
  .container {
12465
12488
  display: flex;
12466
12489
  justify-content: center;
@@ -12536,6 +12559,10 @@ const KB="outline",YB="block",XB=Mt`
12536
12559
  border-color: rgba(${cl}, 0.1);
12537
12560
  }
12538
12561
 
12562
+ :host([disabled][appearance-readonly]) .control {
12563
+ cursor: text;
12564
+ }
12565
+
12539
12566
  :host([error-visible]) .control {
12540
12567
  border-bottom-color: ${dl};
12541
12568
  }
@@ -12548,10 +12575,14 @@ const KB="outline",YB="block",XB=Mt`
12548
12575
  color: ${pd};
12549
12576
  }
12550
12577
 
12551
- .control[disabled]::placeholder {
12578
+ :host([disabled]) .control::placeholder {
12552
12579
  color: ${fd};
12553
12580
  }
12554
12581
 
12582
+ :host([disabled][appearance-readonly]) .control::placeholder {
12583
+ color: ${pd};
12584
+ }
12585
+
12555
12586
  :host([resize='both']) .control {
12556
12587
  resize: both;
12557
12588
  }
@@ -12591,6 +12622,11 @@ const KB="outline",YB="block",XB=Mt`
12591
12622
  background-color: rgba(${cl}, 0.1);
12592
12623
  }
12593
12624
 
12625
+ :host([disabled][appearance-readonly]) .control {
12626
+ border-color: rgba(${cl}, 0.1);
12627
+ background-color: transparent;
12628
+ }
12629
+
12594
12630
  :host([error-visible][disabled]) .control {
12595
12631
  border-bottom-color: ${dl};
12596
12632
  }
@@ -12603,7 +12639,7 @@ const KB="outline",YB="block",XB=Mt`
12603
12639
  <slot ${ie("defaultSlottedNodes")}></slot>
12604
12640
  </label>
12605
12641
  `)
12606
- class QB extends(Ug(hv(ws))){constructor(){super(...arguments),this.appearance=KB,this.scrollbarWidth=-1,this.updateScrollbarWidthQueued=!1}connectedCallback(){super.connectedCallback(),this.resizeObserver=new ResizeObserver((()=>this.onResize())),this.resizeObserver.observe(this)}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver?.disconnect()}onTextAreaInput(){this.handleTextInput(),this.queueUpdateScrollbarWidth()}placeholderChanged(){this.queueUpdateScrollbarWidth()}valueChanged(t,e){super.valueChanged(t,e),this.queueUpdateScrollbarWidth()}onResize(){this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}queueUpdateScrollbarWidth(){this.$fastController.isConnected&&(this.updateScrollbarWidthQueued||(this.updateScrollbarWidthQueued=!0,b.queueUpdate((()=>this.updateScrollbarWidth()))))}updateScrollbarWidth(){this.updateScrollbarWidthQueued=!1,this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}}t([ft],QB.prototype,"appearance",void 0),t([C],QB.prototype,"scrollbarWidth",void 0)
12642
+ class QB extends(Ug(hv(ws))){constructor(){super(...arguments),this.appearance=KB,this.appearanceReadOnly=!1,this.scrollbarWidth=-1,this.updateScrollbarWidthQueued=!1}connectedCallback(){super.connectedCallback(),this.resizeObserver=new ResizeObserver((()=>this.onResize())),this.resizeObserver.observe(this)}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver?.disconnect()}onTextAreaInput(){this.handleTextInput(),this.queueUpdateScrollbarWidth()}placeholderChanged(){this.queueUpdateScrollbarWidth()}valueChanged(t,e){super.valueChanged(t,e),this.queueUpdateScrollbarWidth()}onResize(){this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}queueUpdateScrollbarWidth(){this.$fastController.isConnected&&(this.updateScrollbarWidthQueued||(this.updateScrollbarWidthQueued=!0,b.queueUpdate((()=>this.updateScrollbarWidth()))))}updateScrollbarWidth(){this.updateScrollbarWidthQueued=!1,this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}}t([ft],QB.prototype,"appearance",void 0),t([ft({attribute:"appearance-readonly",mode:"boolean"})],QB.prototype,"appearanceReadOnly",void 0),t([C],QB.prototype,"scrollbarWidth",void 0)
12607
12643
  const tP=QB.compose({baseName:"text-area",baseClass:ws,template:()=>Q`
12608
12644
  ${JB}
12609
12645
  <div class="container">
@@ -12800,6 +12836,10 @@ const eP="underline",nP="outline",iP="block",sP="frameless",oP=Mt`
12800
12836
  text-overflow: clip;
12801
12837
  }
12802
12838
 
12839
+ :host([disabled][appearance-readonly]) .control {
12840
+ cursor: text;
12841
+ }
12842
+
12803
12843
  .control::placeholder {
12804
12844
  color: ${pd};
12805
12845
  }