Skip to content

Commit b5583ad

Browse files
authored
Merge pull request #98 from Semantic-Org/feat/query-anchor
Feat: Adds Anchor Plugin
2 parents 14c0c1a + ba864f4 commit b5583ad

File tree

126 files changed

+6810
-2189
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+6810
-2189
lines changed

CHANGELOG.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,11 @@ Please note after `1.0` Semver will be followed using normal protocols.
88

99
# Version 0.17.0 - xx.xx.xxxx
1010

11+
## Major Features
12+
* **Attach** - Added new `attach` behavior that allows you to position elements relative to other elements using `css anchor` positioning.
13+
1114
## Breaking Changes
15+
* **Utils** - `deepExtend` now preserves non clonables by default. This is to prevent very common scenarios where extend is used with custom classes or dom elements where the original reference should be maintained. Note this still can be overwritten using `deepExtend(obj1, obj2, { preserveNonCloneable: false });`
1216
* **Query** - Renamed `containingParent` to `positioningParent` and added support for values that can cause `position: fixed` to be relative to different coordinate systems. `containingParent` is still available but will always return the `offsetParent` of an element. This is faster but MAY NOT always be the proper parent for positioning.
1317

1418
## CSS Tokens
@@ -18,16 +22,26 @@ Please note after `1.0` Semver will be followed using normal protocols.
1822
* **Feature** - Added [`position()`](https://next.semantic-ui.com/api/query/dimensions#position) method that replaces `containerPosition()` with enhanced API supporting multiple coordinate systems (global, local, relative) and proper empty selection handling.
1923
* **Feature** - Added [`pagePosition()`](https://next.semantic-ui.com/api/query/dimensions#pageposition) method for getting/setting element position relative to the document.
2024
* **Feature** - Added [`dimensions()`](https://next.semantic-ui.com/api/query/dimensions#dimensions) method returning comprehensive dimension information including content, padding, border, margin, and scroll dimensions.
21-
* **Feature** - Added [`isInViewport()`](https://next.semantic-ui.com/api/query/visibility#isinviewport) method for detecting viewport intersection with optional threshold and fully visible options.
25+
* **Feature** - Added [`intersects()`](https://next.semantic-ui.com/api/query/dimensions#intersects) method for checking element intersection with configurable threshold, side detection, and detailed intersection data.
26+
* **Feature** - Added [`isInView()`](https://next.semantic-ui.com/api/query/visibility#isinview) method for detecting viewport intersection with optional threshold and fully visible options.
2227
* **Feature** - Added [`positioningParent()`](https://next.semantic-ui.com/api/query/visibility#positioningparent) method that correctly identifies positioning contexts for both absolute and fixed elements, including modern CSS properties like transform, filter, perspective, contain, and will-change.
2328
* **Feature** - Added [`show()`](https://next.semantic-ui.com/api/query/visibility#show) method for showing hidden elements with optional `calculate` parameter to determine natural display values.
2429
* **Feature** - Added [`hide()`](https://next.semantic-ui.com/api/query/visibility#hide) method for hiding elements by setting display to 'none'.
2530
* **Feature** - Added [`toggle()`](https://next.semantic-ui.com/api/query/visibility#toggle) method for toggling element visibility with optional `calculate` parameter.
31+
* **Feature** - Added [`removeData()`](https://next.semantic-ui.com/api/query/attributes#removedata) method for removing data attributes from elements. Supports space-separated strings or arrays for removing multiple attributes at once.
2632
* **Enhancement** - [`naturalDisplay()`](https://next.semantic-ui.com/api/query/dimensions#naturaldisplay) now accepts `calculate` parameter to control whether to analyze stylesheets (default: true) or use tag-based lookup only.
2733
* **Enhancement** - [`isVisible()`](https://next.semantic-ui.com/api/query/logical-operators#isvisible) now checks for `visibility: hidden` and `content-visibility: hidden` by default, with new `includeVisibility` parameter for control.
2834
* **Enhancement** - [`containingParent()`](https://next.semantic-ui.com/api/query/visibility#containingparent) now provides simple `offsetParent` wrapper functionality alongside the new `positioningParent()` method.
35+
* **Enhancement** - [`closest()`](https://next.semantic-ui.com/api/query/dom-traversal#closest) now supports passing DOM elements directly as the selector parameter, checking containment using the element's `contains()` method.
2936
* **Bug** - Fixed CSS nesting parsing in [`naturalDisplay()`](https://next.semantic-ui.com/api/query/dimensions#naturaldisplay) to properly resolve nested selectors with `&` parent references (e.g., `& .grid-container`).
3037
* **Bug** - Fixed [`position()`](https://next.semantic-ui.com/api/query/dimensions#position) method to return `undefined` for empty selections instead of empty array when used as getter.
38+
* **Bug** - Fixed issue where using non clonables as settings like query collections, or custom classes wouldn't work as expected. This was related to the default behavior of deepExtend and clone (see breaking changes).
39+
* **Bug** - Fixed bug in `is` where it would return true for non-existent selectors
40+
41+
## Utils
42+
* **Feature** - Clone now has a new setting `preserveDOM` which will not clone DOM nodes if present. This can be useful in scenarios where you want to clone an object with references to the live DOM you want to maintain
43+
* **Feature** - Added `log()` function for flexible logging with formatting, namespacing, timestamps, and JSON output support
44+
* **Feature** - Renamed `errors.js` module to `debug.js` to better reflect its logging and debugging capabilities
3145

3246
# Version 0.16.1-2 - 08.21.2025
3347

@@ -41,7 +55,6 @@ Please note after `1.0` Semver will be followed using normal protocols.
4155
## UI Changes
4256

4357
`semantic-ui/core` is now organized into three groups: [`primitives`](https://github.com/Semantic-Org/Semantic-Next/tree/main/src/primitives), [`components`](https://github.com/Semantic-Org/Semantic-Next/tree/main/src/components), and [`behaviors`](https://github.com/Semantic-Org/Semantic-Next/tree/main/src/behaviors)
44-
4558
* **Primitives** include JSON specs and are essential building blocks like `modal` and `button`.
4659
* **Components** are built with primitives and have more complex functionality, for example, `global-search` or `theme-switcher`.
4760
* **Behaviors** do not export web components but provide behaviors like `transition` or `position`.

ai/artifacts/query-examples-demonstrates-fixes.md

Lines changed: 0 additions & 98 deletions
This file was deleted.

ai/components/rerender-guard-blocks.md

Lines changed: 0 additions & 106 deletions
This file was deleted.

0 commit comments

Comments
 (0)