Sha256: fbdf0fa5a17ce76fe8fe4072b6df3ce6539b8a40814b185c6d94d793067b058a
Contents?: true
Size: 1.32 KB
Versions: 553
Compression:
Stored size: 1.32 KB
Contents
# frozen_string_literal: true module Playbook module PbTreemapChart class TreemapChart < Playbook::KitBase prop :chart_data, type: Playbook::Props::Array, default: [] prop :colors, type: Playbook::Props::Array, default: [] prop :custom_options, default: {} prop :drillable, type: Playbook::Props::Boolean, default: false prop :grouped, type: Playbook::Props::Boolean, default: false prop :height prop :title, default: "" prop :tooltip_html, default: '<span style="font-weight: bold; color:{point.color};">● </span> {point.name}: ' + '<b>{point.value} </b>' def chart_type "treemap" end def standard_options { chartData: chart_data, className: classname, colors: colors, dark: dark ? "dark" : "", drillable: drillable, grouped: grouped, height: height, id: id, title: title, tooltipHtml: tooltip_html, type: chart_type, } end def chart_options standard_options.deep_merge(custom_options) end def classname generate_classname("pb_treemap_chart") end end end end
Version data entries
553 entries across 553 versions & 1 rubygems