File tree Expand file tree Collapse file tree 6 files changed +72
-7
lines changed Expand file tree Collapse file tree 6 files changed +72
-7
lines changed Original file line number Diff line number Diff line change @@ -78,4 +78,39 @@ protected function _renderColumnarSettings() {
78
78
self ::_renderGroupEnd ();
79
79
}
80
80
81
+
82
+ /**
83
+ * Renders general settings block for vertical axis settings.
84
+ *
85
+ * @since 1.4.0
86
+ *
87
+ * @access protected
88
+ */
89
+ protected function _renderVerticalAxisGeneralSettings () {
90
+ parent ::_renderVerticalAxisGeneralSettings ();
91
+ self ::_renderColorPickerItem (
92
+ esc_html__ ( 'Axis Text Color ' , Visualizer_Plugin::NAME ),
93
+ 'hAxis[textStyle] ' ,
94
+ isset ( $ this ->hAxis ['textStyle ' ] ) ? $ this ->hAxis ['textStyle ' ] : null ,
95
+ '#000 '
96
+ );
97
+ }
98
+
99
+ /**
100
+ * Renders general settings block for vertical axis settings.
101
+ *
102
+ * @since 1.4.0
103
+ *
104
+ * @access protected
105
+ */
106
+ protected function _renderHorizontalAxisGeneralSettings () {
107
+ parent ::_renderHorizontalAxisGeneralSettings ();
108
+ self ::_renderColorPickerItem (
109
+ esc_html__ ( 'Axis Text Color ' , Visualizer_Plugin::NAME ),
110
+ 'vAxis[textStyle] ' ,
111
+ isset ( $ this ->vAxis ['textStyle ' ] ) ? $ this ->vAxis ['textStyle ' ] : null ,
112
+ '#000 '
113
+ );
114
+ }
115
+
81
116
}
Original file line number Diff line number Diff line change @@ -133,7 +133,7 @@ protected function _renderChartTitleSettings() {
133
133
*
134
134
* @access protected
135
135
*/
136
- protected function _renderHorizontalAxisGeneratSettings () {
136
+ protected function _renderHorizontalAxisGeneralSettings () {
137
137
self ::_renderTextItem (
138
138
esc_html__ ( 'Axis Title ' , Visualizer_Plugin::NAME ),
139
139
'hAxis[title] ' ,
@@ -179,7 +179,7 @@ protected function _renderHorizontalAxisGeneratSettings() {
179
179
protected function _renderHorizontalAxisSettings () {
180
180
self ::_renderGroupStart ( esc_html__ ( 'Horizontal Axis Settings ' , Visualizer_Plugin::NAME ) );
181
181
self ::_renderSectionStart ( esc_html__ ( 'General Settings ' , Visualizer_Plugin::NAME ), false );
182
- $ this ->_renderHorizontalAxisGeneratSettings ();
182
+ $ this ->_renderHorizontalAxisGeneralSettings ();
183
183
self ::_renderSectionEnd ();
184
184
185
185
if ( $ this ->_horizontalGridLines ) {
Original file line number Diff line number Diff line change @@ -91,8 +91,16 @@ public function __construct( $data = array() ) {
91
91
*
92
92
* @access protected
93
93
*/
94
- protected function _renderHorizontalAxisGeneratSettings () {
95
- parent ::_renderHorizontalAxisGeneratSettings ();
94
+ protected function _renderHorizontalAxisGeneralSettings () {
95
+ parent ::_renderHorizontalAxisGeneralSettings ();
96
+
97
+ self ::_renderColorPickerItem (
98
+ esc_html__ ( 'Axis Text Color ' , Visualizer_Plugin::NAME ),
99
+ 'vAxis[textStyle] ' ,
100
+ isset ( $ this ->vAxis ['textStyle ' ] ) ? $ this ->vAxis ['textStyle ' ] : null ,
101
+ '#000 '
102
+ );
103
+
96
104
$ this ->_renderHorizontalAxisFormatField ();
97
105
}
98
106
@@ -105,6 +113,14 @@ protected function _renderHorizontalAxisGeneratSettings() {
105
113
*/
106
114
protected function _renderVerticalAxisGeneralSettings () {
107
115
parent ::_renderVerticalAxisGeneralSettings ();
116
+
117
+ self ::_renderColorPickerItem (
118
+ esc_html__ ( 'Axis Text Color ' , Visualizer_Plugin::NAME ),
119
+ 'hAxis[textStyle] ' ,
120
+ isset ( $ this ->hAxis ['textStyle ' ] ) ? $ this ->hAxis ['textStyle ' ] : null ,
121
+ '#000 '
122
+ );
123
+
108
124
$ this ->_renderVerticalAxisFormatField ();
109
125
}
110
126
Original file line number Diff line number Diff line change @@ -54,8 +54,8 @@ public function __construct( $data = array( ) ) {
54
54
*
55
55
* @access protected
56
56
*/
57
- protected function _renderHorizontalAxisGeneratSettings () {
58
- parent ::_renderHorizontalAxisGeneratSettings ();
57
+ protected function _renderHorizontalAxisGeneralSettings () {
58
+ parent ::_renderHorizontalAxisGeneralSettings ();
59
59
$ this ->_renderHorizontalAxisFormatField ();
60
60
}
61
61
Original file line number Diff line number Diff line change 98
98
a . href = url ;
99
99
a . download = data . data . name ;
100
100
a . click ( ) ;
101
- window . URL . revokeObjectURL ( url ) ;
101
+ setTimeout ( function ( ) {
102
+ window . URL . revokeObjectURL ( url ) ;
103
+ } , 100 ) ;
102
104
}
103
105
} ) ;
104
106
return false ;
Original file line number Diff line number Diff line change 132
132
}
133
133
}
134
134
135
+ if ( settings . hAxis ) {
136
+ if ( settings . hAxis . textStyle && settings . hAxis . textStyle != '' ) {
137
+ settings . hAxis . textStyle = { color : settings . hAxis . textStyle } ;
138
+ }
139
+ }
140
+
141
+ if ( settings . vAxis ) {
142
+ if ( settings . vAxis . textStyle && settings . vAxis . textStyle != '' ) {
143
+ settings . vAxis . textStyle = { color : settings . vAxis . textStyle } ;
144
+ }
145
+ }
146
+
135
147
for ( i = 0 ; i < data . length ; i ++ ) {
136
148
row = [ ] ;
137
149
for ( j = 0 ; j < series . length ; j ++ ) {
You can’t perform that action at this time.
0 commit comments