Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sparkline Support #472

Open
MarkhamShofner opened this issue Mar 5, 2020 · 0 comments
Open

Sparkline Support #472

MarkhamShofner opened this issue Mar 5, 2020 · 0 comments

Comments

@MarkhamShofner
Copy link
Contributor

Here is a custom definition that could be used, should cedar ever move to support sparklines. ... indicating values that were specific to my definition generation and don't need to be mirrored. Primarily lean on the 'type': 'line', and the 'overrides': portions.

    let definition = {
      'type': 'line',
      'datasets': ...,
      'series': [{
        'source': ...,
        'category': {
          'field': ...',
          'label': ...
        },
        'group': ..,
        'value': {
          'field': ...,
          'label': ...
        }
      }],
      'overrides': {
        'type': 'serial',
        'theme': 'calcite',
        'autoMargins': false,
        'marginLeft': 0,
        'marginRight': 3,
        'marginTop': 0,
        'marginBottom': 0,
        'graphs': [{
          'bullet': 'none',
          // 'lineColor': '#4c4c4c', // '#a9ec49'
        }],
        'valueAxes': [{
          'gridAlpha': 0,
          'axisAlpha': 0,
          'minimum': -1,
        }],
        'categoryAxis': {
          'gridAlpha': 0,
          'axisAlpha': 0,
          'startOnAxis': true,
        }
      },
      'legend': {},
      'style': {}
    };
    return definition;
  })
});

Which leads to a sparkline that looks like this
https___zebra-dc_hubqa_arcgis_com_4200_dashboard_edit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant