]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/pybind/mgr/dashboard/frontend/src/app/shared/enum/cell-template.enum.ts
import 15.2.0 Octopus source
[ceph.git] / ceph / src / pybind / mgr / dashboard / frontend / src / app / shared / enum / cell-template.enum.ts
index cf3e11a7ecfb9db7cdb20bcb4c4c3e7b2b678fe1..47f180bc5a90109b0c80fbb967b3c9187f7e4870 100644 (file)
@@ -5,5 +5,29 @@ export enum CellTemplate {
   checkIcon = 'checkIcon',
   routerLink = 'routerLink',
   executing = 'executing',
-  classAdding = 'classAdding'
+  classAdding = 'classAdding',
+  // Display the cell value as a badge. The template
+  // supports an optional custom configuration:
+  // {
+  //   ...
+  //   cellTransformation: CellTemplate.badge,
+  //   customTemplateConfig: {
+  //     class?: string; // Additional class name.
+  //     prefix?: any;   // Prefix of the value to be displayed.
+  //                     // 'map' and 'prefix' exclude each other.
+  //     map?: {
+  //       [key: any]: { value: any, class?: string }
+  //     }
+  //   }
+  // }
+  badge = 'badge',
+  // Maps the value using the given dictionary.
+  // {
+  //   ...
+  //   cellTransformation: CellTemplate.map,
+  //   customTemplateConfig: {
+  //     [key: any]: any
+  //   }
+  // }
+  map = 'map'
 }