vmware-clarity

How to dynamically switch theme with vmware clarity

帅比萌擦擦* 提交于 2021-02-06 11:28:31
问题 Vmware Clarity 0.10.16 just released the new dark theme. This is great! They described how to add that new theme, but nothing about the possibility to dynamically change it inside the page. Is it because it is not doable? If it is, how can I do it with Angular 4+? Any site that could help me explaining how to realize that? Thanks in advance! 回答1: Clarity now ships with stylesheets for both light and dark themes. We document how to consume them here with both angular-cli or webpack build

How to dynamically switch theme with vmware clarity

萝らか妹 提交于 2021-02-06 11:24:48
问题 Vmware Clarity 0.10.16 just released the new dark theme. This is great! They described how to add that new theme, but nothing about the possibility to dynamically change it inside the page. Is it because it is not doable? If it is, how can I do it with Angular 4+? Any site that could help me explaining how to realize that? Thanks in advance! 回答1: Clarity now ships with stylesheets for both light and dark themes. We document how to consume them here with both angular-cli or webpack build

How to dynamically switch theme with vmware clarity

别来无恙 提交于 2021-02-06 11:24:21
问题 Vmware Clarity 0.10.16 just released the new dark theme. This is great! They described how to add that new theme, but nothing about the possibility to dynamically change it inside the page. Is it because it is not doable? If it is, how can I do it with Angular 4+? Any site that could help me explaining how to realize that? Thanks in advance! 回答1: Clarity now ships with stylesheets for both light and dark themes. We document how to consume them here with both angular-cli or webpack build

How can I dynamically change the shape of a clr-icon custom element?

耗尽温柔 提交于 2020-01-23 09:21:25
问题 In the Clarity Icon docs they show that you can use the shape attribute to set the icons shape like this: <clr-icon shape="info-circle" size="16"></clr-icon> In my angular template I am using a clr-icon element like this: <clr-icon [shape]="myShape"></clr-icon> And use my component to set the string value of the shape bound to myShape : export class MyComponent { public myShape = 'volume-up'; changeShape() { if(this.myShape === 'volume-up') { this.myShape = 'volume-mute'; return; } this

display first tab as default when page loads

自古美人都是妖i 提交于 2019-12-24 20:35:01
问题 log.component.html: <clr-tabs> <clr-tab> <button style="margin-left: 3% !important;" clrTabLink [routerLink]="'log1'">Log1</button> <ng-template [(clrIfActive)]="log1"> <clr-tab-content> <div class="main-container"> <div class="content-container"> <div class="content-area"> <router-outlet></router-outlet> </div> </div> </div> </clr-tab-content> </ng-template> </clr-tab> <clr-tab> <button style="margin-left: 3% !important;" clrTabLink [routerLink]="'log2'">Log2</button> <ng-template [

Clarity: Is there a recommended way to make clr-datagrid take up all available vertical space?

自闭症网瘾萝莉.ら 提交于 2019-12-19 08:30:21
问题 I am trying to make my take up all vertical space even if there are no rows in the table yet. Is clr-datagrid customizable to do so? It seems like I have to manually override flexbox properties of .datagrid-host and .datagrid-overlay-wrapper in order to make it grow in column direction. I tried even that but the datagrid don't seem to be growing vertically. 回答1: The Clarity datagrid supports any fixed height you want on the datagrid element itself. If the height is too large for the number of

ERROR in : 'clr-icon' is not a known element:

北城余情 提交于 2019-12-13 15:35:18
问题 Running the following command: ng build --prod --base-href ./ I get: ERROR in : 'clr-icon' is not a known element: 1. If 'clr-icon' is an Angular component, then verify that it is part of this module. 2. If 'clr-icon' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message. ("spinner spinner-sm spinner-inverse" [style.display]="loading ? 'inline-block' : 'none'"></span> [ERROR ->]<clr-icon clrSignpostTrigger shape="check" size

How to clear all datagrid filters programmatically?

﹥>﹥吖頭↗ 提交于 2019-12-13 05:35:56
问题 I'd like to have a button that the user can click to clear all the filters. I haven't found a way to do so yet. Any hints? I have a mix of default and custom column filters <clr-datagrid (clrDgRefresh)="refresh($event)" [clrDgLoading]="loading"> <clr-dg-column [clrDgField]="'healthScore'" class="healthScoreWidth"> Health <clr-dg-filter [clrDgFilter]="refHealthScoreFilter"> <app-filter-checkbox #refHealthScoreFilter [items]="healthScoreItems" [filter]="healthScoreFilter"> </app-filter-checkbox

Uncaught TypeError: Cannot read property 'chocolate' of undefined

故事扮演 提交于 2019-12-13 04:22:54
问题 I am getting this error: Uncaught TypeError: Cannot read property 'chocolate' of undefined when building ( ng build --prod ) my Angular project with @clr version 0.12.6 and more. Anybody got the same issue and if so, were you able to resolve it and how? Anybody could tell me where the 'chocholate' property is used? That could help me to point out my issue. Thanks 回答1: Sometimes your node modules get out of sync, try deleting the directory and reinstalling. I recommend using NPM 5+ or Yarn to

How can I dynamically change the shape of a clr-icon custom element?

安稳与你 提交于 2019-12-06 01:41:23
In the Clarity Icon docs they show that you can use the shape attribute to set the icons shape like this: <clr-icon shape="info-circle" size="16"></clr-icon> In my angular template I am using a clr-icon element like this: <clr-icon [shape]="myShape"></clr-icon> And use my component to set the string value of the shape bound to myShape : export class MyComponent { public myShape = 'volume-up'; changeShape() { if(this.myShape === 'volume-up') { this.myShape = 'volume-mute'; return; } this.myShape = 'volume-up; } } Using a button (not shown in the template) I want to run the changeShape() to