Skip to content

Commit ab83b91

Browse files
author
QuantLab
committed
cell style
1 parent c87b1d8 commit ab83b91

12 files changed

Lines changed: 71 additions & 82 deletions

dist/@quantlab/handsontable.css

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/@quantlab/handsontable.full.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
2424
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2525
*
26-
* Version: 0.33.0
27-
* Date: Fri Aug 04 2017 16:54:30 GMT+0800 (China Standard Time)
26+
* Version: 0.33.2
27+
* Date: Mon Aug 07 2017 13:35:36 GMT+0800 (China Standard Time)
2828
*/
2929
@charset "UTF-8";
3030

dist/@quantlab/handsontable.full.js

Lines changed: 18 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
2424
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2525
*
26-
* Version: 0.33.0
27-
* Date: Fri Aug 04 2017 16:54:30 GMT+0800 (China Standard Time)
26+
* Version: 0.33.2
27+
* Date: Mon Aug 07 2017 13:35:36 GMT+0800 (China Standard Time)
2828
*/
2929
(function webpackUniversalModuleDefinition(root, factory) {
3030
if(typeof exports === 'object' && typeof module === 'object')
@@ -53255,9 +53255,9 @@ Handsontable.DefaultSettings = _defaultSettings2.default;
5325553255
Handsontable.EventManager = _eventManager2.default;
5325653256
Handsontable._getListenersCounter = _eventManager.getListenersCounter; // For MemoryLeak tests
5325753257

53258-
Handsontable.buildDate = "2017-08-04T08:54:30.739Z";
53258+
Handsontable.buildDate = "2017-08-07T05:35:36.339Z";
5325953259
Handsontable.packageName = "@quantlab/handsontable";
53260-
Handsontable.version = "0.33.0";
53260+
Handsontable.version = "0.33.2";
5326153261

5326253262
var baseVersion = undefined;
5326353263

@@ -61665,6 +61665,11 @@ function isFormula(value) {
6166561665
* @param cellProperties
6166661666
*/
6166761667
function formulaRenderer(instance, TD, row, col, prop, value, cellProperties) {
61668+
//set cellProperties
61669+
if (cellProperties.fontWeight != null) TD.style.fontWeight = cellProperties.fontWeight;
61670+
if (cellProperties.color != null) TD.style.color = cellProperties.color;
61671+
if (cellProperties.background != null) TD.style.background = cellProperties.background;
61672+
6166861673
if (isFormula(value)) {
6166961674
// translate coordinates into cellId
6167061675
var cellId = instance.plugin.utils.translateCellCoords({
@@ -61760,24 +61765,12 @@ function formulaRenderer(instance, TD, row, col, prop, value, cellProperties) {
6176061765
}
6176161766

6176261767
// change background color
61763-
var className = cellProperties.className || '';
61764-
61765-
var classArr = className.length ? className.split(' ') : [];
61766-
6176761768
if (instance.plugin.utils.isSet(error)) {
61768-
if (classArr.indexOf('formula-error') < 0) {
61769-
classArr.push('formula-error');
61770-
}
61769+
(0, _element.addClass)(TD, 'formula-error');
6177161770
} else if (instance.plugin.utils.isSet(result)) {
61772-
if (classArr.indexOf('formula-error') >= 0) {
61773-
classArr.splice(classArr.indexOf('formula-error'), 1);
61774-
}
61775-
if (classArr.indexOf('formula') < 0) {
61776-
classArr.push('formula');
61777-
}
61771+
(0, _element.removeClass)(TD, 'formula-error');
61772+
(0, _element.addClass)(TD, 'formula');
6177861773
}
61779-
61780-
cellProperties.className = classArr.join(' ');
6178161774
}
6178261775

6178361776
var escaped = (0, _mixed.stringify)(value);
@@ -74867,7 +74860,11 @@ var ruleJS = function ruleJS(root) {
7486774860
var colFragment = [];
7486874861

7486974862
for (var col = startCellCoord.column.index; col <= endCellCoord.column.index; col++) {
74870-
colFragment.push(rowData[col]);
74863+
var cellId = instance.utils.translateCellCoords({ row: row, col: col });
74864+
var val = instance.helper.cellValue(cellId);
74865+
while (val[0] === '=') {
74866+
val = instance.helper.cellValue(val.substr(1));
74867+
}colFragment.push(val);
7487174868
}
7487274869
fragment.push(colFragment);
7487374870
}
@@ -75183,9 +75180,7 @@ var Formula = function (_BasePlugin) {
7518375180
this.addHook('afterChange', function (changes, source) {
7518475181
return _this2.afterChange(changes, source);
7518575182
});
75186-
this.addHook('beforeAutofillInsidePopulate', function (index, direction, data, deltas, iterators, selected) {
75187-
return _this2.beforeAutofillInsidePopulate(index, direction, data, deltas, iterators, selected);
75188-
});
75183+
//this.addHook('beforeAutofillInsidePopulate', (index, direction, data, deltas, iterators, selected) => this.beforeAutofillInsidePopulate(index, direction, data, deltas, iterators, selected));
7518975184
this.addHook('afterCreateRow', function (row, amount, auto) {
7519075185
return _this2.afterCreateRow(row, amount, auto);
7519175186
});

dist/@quantlab/handsontable.full.min.css

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/@quantlab/handsontable.full.min.js

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/@quantlab/handsontable.js

Lines changed: 18 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
2424
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2525
*
26-
* Version: 0.33.0
27-
* Date: Fri Aug 04 2017 16:54:30 GMT+0800 (China Standard Time)
26+
* Version: 0.33.2
27+
* Date: Mon Aug 07 2017 13:35:36 GMT+0800 (China Standard Time)
2828
*/
2929
(function webpackUniversalModuleDefinition(root, factory) {
3030
if(typeof exports === 'object' && typeof module === 'object')
@@ -36383,9 +36383,9 @@ Handsontable.DefaultSettings = _defaultSettings2.default;
3638336383
Handsontable.EventManager = _eventManager2.default;
3638436384
Handsontable._getListenersCounter = _eventManager.getListenersCounter; // For MemoryLeak tests
3638536385

36386-
Handsontable.buildDate = "2017-08-04T08:54:30.739Z";
36386+
Handsontable.buildDate = "2017-08-07T05:35:36.339Z";
3638736387
Handsontable.packageName = "@quantlab/handsontable";
36388-
Handsontable.version = "0.33.0";
36388+
Handsontable.version = "0.33.2";
3638936389

3639036390
var baseVersion = undefined;
3639136391

@@ -40044,6 +40044,11 @@ function isFormula(value) {
4004440044
* @param cellProperties
4004540045
*/
4004640046
function formulaRenderer(instance, TD, row, col, prop, value, cellProperties) {
40047+
//set cellProperties
40048+
if (cellProperties.fontWeight != null) TD.style.fontWeight = cellProperties.fontWeight;
40049+
if (cellProperties.color != null) TD.style.color = cellProperties.color;
40050+
if (cellProperties.background != null) TD.style.background = cellProperties.background;
40051+
4004740052
if (isFormula(value)) {
4004840053
// translate coordinates into cellId
4004940054
var cellId = instance.plugin.utils.translateCellCoords({
@@ -40139,24 +40144,12 @@ function formulaRenderer(instance, TD, row, col, prop, value, cellProperties) {
4013940144
}
4014040145

4014140146
// change background color
40142-
var className = cellProperties.className || '';
40143-
40144-
var classArr = className.length ? className.split(' ') : [];
40145-
4014640147
if (instance.plugin.utils.isSet(error)) {
40147-
if (classArr.indexOf('formula-error') < 0) {
40148-
classArr.push('formula-error');
40149-
}
40148+
(0, _element.addClass)(TD, 'formula-error');
4015040149
} else if (instance.plugin.utils.isSet(result)) {
40151-
if (classArr.indexOf('formula-error') >= 0) {
40152-
classArr.splice(classArr.indexOf('formula-error'), 1);
40153-
}
40154-
if (classArr.indexOf('formula') < 0) {
40155-
classArr.push('formula');
40156-
}
40150+
(0, _element.removeClass)(TD, 'formula-error');
40151+
(0, _element.addClass)(TD, 'formula');
4015740152
}
40158-
40159-
cellProperties.className = classArr.join(' ');
4016040153
}
4016140154

4016240155
var escaped = (0, _mixed.stringify)(value);
@@ -53246,7 +53239,11 @@ var ruleJS = function ruleJS(root) {
5324653239
var colFragment = [];
5324753240

5324853241
for (var col = startCellCoord.column.index; col <= endCellCoord.column.index; col++) {
53249-
colFragment.push(rowData[col]);
53242+
var cellId = instance.utils.translateCellCoords({ row: row, col: col });
53243+
var val = instance.helper.cellValue(cellId);
53244+
while (val[0] === '=') {
53245+
val = instance.helper.cellValue(val.substr(1));
53246+
}colFragment.push(val);
5325053247
}
5325153248
fragment.push(colFragment);
5325253249
}
@@ -53562,9 +53559,7 @@ var Formula = function (_BasePlugin) {
5356253559
this.addHook('afterChange', function (changes, source) {
5356353560
return _this2.afterChange(changes, source);
5356453561
});
53565-
this.addHook('beforeAutofillInsidePopulate', function (index, direction, data, deltas, iterators, selected) {
53566-
return _this2.beforeAutofillInsidePopulate(index, direction, data, deltas, iterators, selected);
53567-
});
53562+
//this.addHook('beforeAutofillInsidePopulate', (index, direction, data, deltas, iterators, selected) => this.beforeAutofillInsidePopulate(index, direction, data, deltas, iterators, selected));
5356853563
this.addHook('afterCreateRow', function (row, amount, auto) {
5356953564
return _this2.afterCreateRow(row, amount, auto);
5357053565
});

dist/@quantlab/handsontable.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/@quantlab/handsontable.min.css

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/@quantlab/handsontable.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"url": "https://github.com/handsontable/handsontable/issues"
1111
},
1212
"author": "Handsoncode <hello@handsontable.com>",
13-
"version": "0.33.0",
13+
"version": "0.33.3",
1414
"browser": "dist/@quantlab/handsontable.full.js",
1515
"main": "commonjs/index.js",
1616
"module": "es/index.js",

0 commit comments

Comments
 (0)