Skip to content

Commit 2bd203a

Browse files
authored
Merge pull request #2414 from adumesny/master
v9.0.0 release
2 parents 3131015 + ac6bd59 commit 2bd203a

23 files changed

+33
-26
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ Join us on Slack: [https://gridstackjs.slack.com](https://join.slack.com/t/grids
4545
- [Migrating to v6](#migrating-to-v6)
4646
- [Migrating to v7](#migrating-to-v7)
4747
- [Migrating to v8](#migrating-to-v8)
48+
- [Migrating to v9](#migrating-to-v9)
4849
- [jQuery Application](#jquery-application)
4950
- [Changes](#changes)
5051
- [The Team](#the-team)
@@ -443,6 +444,12 @@ Possible breaking change if you use nested grid JSON format, or original Angular
443444
* remove `GridStackOptions.minWidth` obsolete since 5.1, use `oneColumnSize` instead
444445
* CSS rules removed `.grid-stack` prefix for anything already gs based, 12 column (default) now uses `.gs-12`, extra.css is less than 1/4th it original size!, `gs-min|max_w|h` attribute no longer written (but read)
445446
447+
## Migrating to v9
448+
449+
New addition - see release notes about `fitToContent` feature.
450+
Possible break:
451+
* `GridStack.onParentResize()` is now called `onResize()` as grid now directly track size change, no longer involving parent per say to tell us anything. Note sure why it was public.
452+
446453
# jQuery Application
447454
448455
This is **old and no longer apply to v6+**. You'll need to use v5.1.1 and before

angular/projects/lib/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "gridstack-angular",
3-
"version": "8.4.0-dev",
3+
"version": "9.0.0",
44
"peerDependencies": {
55
"@angular/common": "^14.2.0",
66
"@angular/core": "^14.2.0"

angular/projects/lib/src/lib/base-widget.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack-item.component.ts 8.4.0-dev
2+
* gridstack-item.component.ts 9.0.0
33
* Copyright (c) 2022 Alain Dumesny - see GridStack root license
44
*/
55

angular/projects/lib/src/lib/gridstack-item.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack-item.component.ts 8.4.0-dev
2+
* gridstack-item.component.ts 9.0.0
33
* Copyright (c) 2022 Alain Dumesny - see GridStack root license
44
*/
55

angular/projects/lib/src/lib/gridstack.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack.component.ts 8.4.0-dev
2+
* gridstack.component.ts 9.0.0
33
* Copyright (c) 2022 Alain Dumesny - see GridStack root license
44
*/
55

angular/projects/lib/src/lib/gridstack.module.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack.component.ts 8.4.0-dev
2+
* gridstack.component.ts 9.0.0
33
* Copyright (c) 2022 Alain Dumesny - see GridStack root license
44
*/
55

doc/CHANGES.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Change log
55
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
66
**Table of Contents** *generated with [DocToc](http://doctoc.herokuapp.com/)*
77

8-
- [8.4.0-dev (TBD)](#840-dev-tbd)
8+
- [9.0.0 (2023-08-23)](#900-2023-08-23)
99
- [8.4.0 (2023-07-20)](#840-2023-07-20)
1010
- [8.3.0 (2023-06-13)](#830-2023-06-13)
1111
- [8.2.3 (2023-06-11)](#823-2023-06-11)
@@ -93,7 +93,7 @@ Change log
9393

9494
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
9595

96-
## 8.4.0-dev (TBD)
96+
## 9.0.0 (2023-08-23)
9797
- feat [#404](https://github.com/gridstack/gridstack.js/issues/404) added `GridStackOptions.fitToContent` and `GridStackWidget.fitToContent` to make gridItems size themselves to their content (no scroll bar), calling `GridStack.resizeToContent(el)` whenever the grid or item is resized.
9898
- also added new `'resizecontent'` event, and `resizeToContentCB` and `resizeToContentParent` vars.
9999
- fix [#2406](https://github.com/gridstack/gridstack.js/issues/2406) inf loop when autoPosition after loading into 1 column, then 2.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "gridstack",
3-
"version": "8.4.0-dev",
3+
"version": "9.0.0",
44
"license": "MIT",
55
"author": "Alain Dumesny <[email protected]> (https://github.com/adumesny)",
66
"contributors": [

src/dd-base-impl.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-base-impl.ts 8.4.0-dev
2+
* dd-base-impl.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-draggable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-draggable.ts 8.4.0-dev
2+
* dd-draggable.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-droppable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-droppable.ts 8.4.0-dev
2+
* dd-droppable.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-element.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-elements.ts 8.4.0-dev
2+
* dd-elements.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-gridstack.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-gridstack.ts 8.4.0-dev
2+
* dd-gridstack.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-manager.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-manager.ts 8.4.0-dev
2+
* dd-manager.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-resizable-handle.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-resizable-handle.ts 8.4.0-dev
2+
* dd-resizable-handle.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-resizable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* dd-resizable.ts 8.4.0-dev
2+
* dd-resizable.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/dd-touch.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* touch.ts 8.4.0-dev
2+
* touch.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/gridstack-engine.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack-engine.ts 8.4.0-dev
2+
* gridstack-engine.ts 9.0.0
33
* Copyright (c) 2021-2022 Alain Dumesny - see GridStack root license
44
*/
55

src/gridstack-poly.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack-poly.ts 8.4.0-dev used for IE and older browser support (not supported in v2-v4.3.1, but again in v4.4)
2+
* gridstack-poly.ts 9.0.0 used for IE and older browser support (not supported in v2-v4.3.1, but again in v4.4)
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/gridstack.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* gridstack SASS styles 8.4.0-dev
2+
* gridstack SASS styles 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/gridstack.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* GridStack 8.4.0-dev
2+
* GridStack 9.0.0
33
* https://gridstackjs.com/
44
*
55
* Copyright (c) 2021-2022 Alain Dumesny
@@ -1739,7 +1739,7 @@ export class GridStack {
17391739
return this;
17401740
}
17411741

1742-
static GDRev = '8.4.0-dev';
1742+
static GDRev = '9.0.0';
17431743

17441744
/* ===========================================================================================
17451745
* drag&drop methods that used to be stubbed out and implemented in dd-gridstack.ts

src/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* types.ts 8.4.0-dev
2+
* types.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

src/utils.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* utils.ts 8.4.0-dev
2+
* utils.ts 9.0.0
33
* Copyright (c) 2021 Alain Dumesny - see GridStack root license
44
*/
55

@@ -103,8 +103,8 @@ export class Utils {
103103
}
104104

105105
/** true if we should resize to content */
106-
static shouldFitToContent(n: GridStackNode): boolean {
107-
return n.fitToContent || (n.grid?.opts.fitToContent && n.fitToContent !== false);
106+
static shouldFitToContent(n: GridStackNode | undefined): boolean {
107+
return n?.grid && (n.fitToContent || (n.grid.opts.fitToContent && n.fitToContent !== false));
108108
}
109109

110110
/** returns true if a and b overlap */

0 commit comments

Comments
 (0)