Skip to content

Commit d76fe54

Browse files
committed
refactor(core): the selectable-card internal entry keeps Field's styling hook
`@astryxdesign/core/internal/selectable-card` stays in Core's exports and re-exports `useFieldInputStyling` only. Lab's ListInput is moving to that hook through this entry in a separate change, so the two can land in either order. The entry no longer exports SelectableCard's group context, its membership type or `joinAriaIDs`: SelectableCardGroup now lives in Core and imports them by relative path. No public API changes.
1 parent b19f232 commit d76fe54

3 files changed

Lines changed: 21 additions & 0 deletions

File tree

‎packages/core/package.json‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -869,6 +869,11 @@
869869
"types": "./dist/internal/touch.d.ts",
870870
"default": "./dist/internal/touch.js"
871871
},
872+
"./internal/selectable-card": {
873+
"source": "./src/internal/selectable-card.ts",
874+
"types": "./dist/internal/selectable-card.d.ts",
875+
"default": "./dist/internal/selectable-card.js"
876+
},
872877
"./internal/spinner-rotor": {
873878
"source": "./src/internal/spinner-rotor.ts",
874879
"types": "./dist/internal/spinner-rotor.d.ts",
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright (c) Meta Platforms, Inc. and affiliates.
2+
/**
3+
* @file selectable-card.ts
4+
* @input The Field input styling rule
5+
* @output `@astryxdesign/core/internal/selectable-card`: useFieldInputStyling,
6+
* re-exported by name for Lab components that compose Field
7+
* @position An internal entry reserved for Astryx's own packages:
8+
* undocumented, outside the public API and its compatibility promise,
9+
* versioned in lockstep with Core, and allowed only in Core and Lab by the
10+
* `@astryx/no-core-internal-import` lint rule. Core components import the
11+
* same module by relative path. Named re-exports only.
12+
*
13+
* SYNC: When modified, update scripts/sync-exports.js.
14+
*/
15+
export {useFieldInputStyling} from '../Field/fieldParts';

‎scripts/sync-exports.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ const FILE_MODULE_SUBPATH_EXPORTS = [
243243
'internal/reorderHandle.stylex',
244244
'internal/touchHitArea.stylex',
245245
'internal/touch',
246+
'internal/selectable-card',
246247
'internal/spinner-rotor',
247248
'internal/calendar-system',
248249
'internal/dialog-context',

0 commit comments

Comments
 (0)