playbook_ui_docs 14.23.0.pre.alpha.PLAY2243customindeterminatemaincheckboxlabels9046 → 14.23.0.pre.alpha.PLAY2303optD9000

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.
Files changed (27) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_indeterminate.html.erb +1 -1
  3. data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_indeterminate_rails.md +1 -2
  4. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_colors.jsx +15 -32
  5. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_complex.jsx +9 -35
  6. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_default.jsx +14 -26
  7. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_disable_animation.jsx +15 -32
  8. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_full_circle.jsx +17 -45
  9. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_height.jsx +22 -59
  10. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_live_data.jsx +9 -40
  11. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_min_max.jsx +18 -50
  12. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_pb_styles.jsx +30 -0
  13. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_pb_styles.md +1 -0
  14. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_sizing.jsx +18 -31
  15. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_title.jsx +17 -34
  16. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_units.jsx +23 -64
  17. data/app/pb_kits/playbook/pb_gauge/docs/example.yml +1 -0
  18. data/app/pb_kits/playbook/pb_gauge/docs/index.js +1 -0
  19. data/app/pb_kits/playbook/pb_table/docs/_table_with_selectable_rows.html.erb +0 -1
  20. data/dist/playbook-doc.js +1 -1
  21. metadata +6 -8
  22. data/app/pb_kits/playbook/pb_gauge/docs/_description.md +0 -1
  23. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_colors_react.md +0 -2
  24. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_complex_react.md +0 -1
  25. data/app/pb_kits/playbook/pb_gauge/docs/_gauge_units_react.md +0 -1
  26. /data/app/pb_kits/playbook/pb_gauge/docs/{_gauge_colors_rails.md → _gauge_colors.md} +0 -0
  27. /data/app/pb_kits/playbook/pb_gauge/docs/{_gauge_complex_rails.md → _gauge_complex.md} +0 -0
@@ -1,38 +1,21 @@
1
1
  import React from 'react'
2
- import gaugeTheme from '../gaugeTheme'
3
- import Highcharts from "highcharts"
4
- import HighchartsReact from "highcharts-react-official"
5
- import HighchartsMore from "highcharts/highcharts-more"
6
- import SolidGauge from "highcharts/modules/solid-gauge"
2
+ import Gauge from '../../pb_gauge/_gauge'
7
3
 
8
- HighchartsMore(Highcharts);
9
- SolidGauge(Highcharts);
4
+ const data = [
5
+ { name: 'Score', value: 780 },
6
+ ]
10
7
 
11
- const data = [{ name: "Score", y: 780 }]
8
+ const GaugeTitle = (props) => (
9
+ <div>
10
+ <Gauge
11
+ chartData={data}
12
+ id="gauge-title"
13
+ max={850}
14
+ min={300}
15
+ title="Credit Score"
16
+ {...props}
17
+ />
18
+ </div>
19
+ )
12
20
 
13
- const baseOptions = {
14
- title: {
15
- text: "Credit Score",
16
- },
17
- yAxis: {
18
- min: 300,
19
- max: 850,
20
- },
21
- series: [{ data: data }],
22
- };
23
-
24
- const GaugeTitle = () => {
25
- const options = Highcharts.merge({}, gaugeTheme, baseOptions);
26
-
27
- return (
28
- <div>
29
- <HighchartsReact
30
- highcharts={Highcharts}
31
- id="gauge-title"
32
- options={options}
33
- />
34
- </div>
35
- );
36
- };
37
-
38
- export default GaugeTitle;
21
+ export default GaugeTitle
@@ -1,72 +1,31 @@
1
1
  import React from 'react'
2
- import gaugeTheme from '../gaugeTheme'
3
- import Highcharts from "highcharts"
4
- import HighchartsReact from "highcharts-react-official"
5
- import HighchartsMore from "highcharts/highcharts-more"
6
- import SolidGauge from "highcharts/modules/solid-gauge"
7
- import colors from '../../tokens/exports/_colors.module.scss'
8
- import typography from '../../tokens/exports/_typography.module.scss'
9
-
10
- HighchartsMore(Highcharts);
11
- SolidGauge(Highcharts);
2
+ import Gauge from '../../pb_gauge/_gauge'
12
3
 
13
4
  const data1 = [
14
- { name: 'Data Used', y: 32 },
5
+ { name: 'Data Used', value: 32 },
15
6
  ]
16
7
  const data2 = [
17
- { name: 'Sales to Date', y: 65 },
8
+ { name: 'Sales to Date', value: 65 },
18
9
  ]
19
10
 
20
- const baseOptions1 = {
21
- title: {
22
- text: "Data Usage",
23
- },
24
- series: [{ data: data1 }],
25
- plotOptions: {
26
- solidgauge: {
27
- dataLabels: {
28
- format:
29
- `<span class="fix">{y:,f}</span>` +
30
- `<span style="fill: ${colors.text_lt_light}; font-size: ${typography.text_larger};">GB</span>`,
31
- },
32
- },
33
- },
34
- };
35
- const baseOptions2 = {
36
- title: {
37
- text: "Sales Goal",
38
- },
39
- series: [{ data: data2 }],
40
- plotOptions: {
41
- solidgauge: {
42
- dataLabels: {
43
- format:
44
- `<span y="28" style="fill: ${colors.text_lt_light}; font-size: ${typography.text_base};">$</span>` +
45
- `<span class="fix" y="38">{y:,f}</span>` +
46
- `<span style="fill: ${colors.text_lt_light}; font-size: ${typography.text_larger};">k</span>`,
47
- },
48
- },
49
- },
50
- };
51
-
52
- const GaugeUnits = () => {
53
- const options1 = Highcharts.merge({}, gaugeTheme, baseOptions1);
54
- const options2 = Highcharts.merge({}, gaugeTheme, baseOptions2);
55
-
56
- return (
57
- <div>
58
- <HighchartsReact
59
- highcharts={Highcharts}
60
- id="gauge-units1"
61
- options={options1}
62
- />
63
- <HighchartsReact
64
- highcharts={Highcharts}
65
- id="gauge-units2"
66
- options={options2}
67
- />
68
- </div>
69
- );
70
- };
11
+ const GaugeUnits = (props) => (
12
+ <div>
13
+ <Gauge
14
+ chartData={data1}
15
+ id="gauge-units1"
16
+ suffix="GB"
17
+ title="Data Usage"
18
+ {...props}
19
+ />
20
+ <Gauge
21
+ chartData={data2}
22
+ id="gauge-units2"
23
+ prefix="$"
24
+ suffix="k"
25
+ title="Sales Goal"
26
+ {...props}
27
+ />
28
+ </div>
29
+ )
71
30
 
72
- export default GaugeUnits;
31
+ export default GaugeUnits
@@ -15,6 +15,7 @@ examples:
15
15
 
16
16
  react:
17
17
  - gauge_default: Default
18
+ - gauge_pb_styles: Playbook Styles
18
19
  - gauge_disable_animation: Disable Animation
19
20
  - gauge_title: Title
20
21
  - gauge_units: Units
@@ -1,4 +1,5 @@
1
1
  export { default as GaugeDefault } from './_gauge_default.jsx'
2
+ export { default as GaugePbStyles } from './_gauge_pb_styles.jsx'
2
3
  export { default as GaugeDisableAnimation } from './_gauge_disable_animation.jsx'
3
4
  export { default as GaugeFullCircle } from './_gauge_full_circle.jsx'
4
5
  export { default as GaugeHeight } from './_gauge_height.jsx'
@@ -19,7 +19,6 @@
19
19
  value: "checkbox-value",
20
20
  name: "main-checkbox-selectable",
21
21
  indeterminate_main: true,
22
- indeterminate_main_labels: ["", ""],
23
22
  id: "checkbox-selectable"
24
23
  }) %>
25
24
  <% end %>