Releases: iTwin/saved-views
Releases · iTwin/saved-views
@itwin/[email protected]
Beaking changes
SavedView
interface changes- Rename
id
property tosavedViewId
- Remove
thumbnail
property - Move
viewData
andextensions
properties toSavedViewData
type- Type of
viewData
has changed and definition has moved to@itwin/saved-views-react
- Type of
- Change type of
creationTime
andlastModified
properties toDate | undefined
- Rename
- Make
applySavedView
settings easier to understand- Remove
"reset"
fromApplyStrategy
union, instead make"clear"
a valid value foremphasis
andperModelCategoryVisibility
properties - Remove
all
property which set defaultApplyStrategy
of all settings - Update documentation
- Remove
useSavedViews
hook rework- No longer implements optimistic behaviour
- Lazily loads Saved View thumbnails and
SavedViewData
- Can utilize user-supplied external state store
- All actions now return a promise that resolves on action completion
- All creation actions now return id of the created entity
- Rename
SavedViewActions
type toSavedViewsActions
- Split
submitSavedView
intocreateSavedView
andupdateSavedView
- Add
lookupSavedViewData
action - Remove
moveToNewGroup
andaddNewTag
actions
SavedViewTag
: Renameid
property totagId
SavedViewGroup
: Renameid
property togroupId
SavedViewsClient
interface changes- Rename methods
getAllSavedViews
->getSavedViews
getAllGroups
->getGroups
getAllTags
->getTags
getSavedView
->getSavedViewById
- Add
getSavedViewDataById
method - Method argument types now instead of ending in
*Params
now end in*Args
, e.g.CreateSavedViewParams
->CreateSavedViewArgs
- You can now query all Saved Views that are assigned to a particular group using
SavedViewsClient.getSavedViews
CreateSavedViewArgs
,UpdateSavedViewArgs
: Inline properties previously nested withinsavedView
propertyCreateGroupArgs
,UpdateGroupArgs
: Inline properties previously nested withingroup
propertyUpdateTagArgs
: Inline properties previously nested withintag
property
- Rename methods
<SavedViewTile />
changes- Add
thumbnail
prop - Thumbnails that were specified as image URLs now need to be explicitly passed as
<img src={url} />
onRename
callback will no longer sendundefined
fornewName
argument
- Add
Minor changes
applySavedView
enhancements- Accept custom
viewChangeOptions
that the function will internally pass through toviewport.changeView
call - Add
camera
setting that controls how camera data is applied. Allow supplying a customViewPose
or ignoring Saved View data to keep the camera in place.
- Accept custom
Fixes
- Fix
captureSavedViewData
failing with blank iModel connections - Replace usage of internal iTwin.js API with public alternative
@itwin/[email protected]
Breaking changes
SavedViewsClient
interface changes- Remove
getSavedViewInfo
method - Add
getAllSavedViews
,getAllGroups
, andgetAllTags
methods as replacement forgetSavedViewInfo
- Rename
getSingularSavedView
method togetSavedView
- Remove
captureSavedViewData
now also captures extension data thus return type has now changed to{ viewData: ViewData; extensions: SavedViewExtension[] | undefined }
SavedViewsClient.createSavedView
: Update parameter bag to reflectSavedView
change (see minor changes)SavedViewsClient.updateSavedView
: Update parameter bag to reflectSavedView
change (see minor changes)useSavedViews
: UpdatesubmitSavedView
action parameters to reflectSavedView
change (see minor changes)- Update
applySavedView
parameter types.savedViewData
is now a subset ofSavedView
object.
Minor changes
SavedView
now also contains optionalviewData
andextension
properties. Objects returned byITwinSavedViewsClient
will have these fields populated.- Permit
ApplySavedViewSettings.viewState
value to be"reset"
. Due to technicalities, it has the same semantics as"apply"
. SavedViewTile
: Update placeholder icon
Fixes
ITwinSavedViewsClient.createSavedView
: Extension data now is no longer ignoredITwinSavedViewsClient.updateSavedView
: Fix extension data not being updatedITwinSavedViewsClient.deleteGroup
now correctly attempts to delete multiple pages of Saved Views
Dependencies
- Bump
@itwin/itwinui-icons-react
version requirement from^2.4.0
to^2.9.0
- Bump
@itwin/saved-views-client
version requirement from^0.3.0
to^0.4.0
@itwin/[email protected]
Breaking changes
SavedViewsClient
interface changesgetAllSavedViewsMinimal
andgetAllSavedViewsRepresentation
now returnAsyncIterableIterator
to better emphasize that results are delivered in pagescreateSavedView
andupdateSavedView
now returnSavedViewRepresentationResponse
to match the current iTwin API behavior
Fixes
- Remove
extensions
property fromUpdateSavedViewParams
because extensions are immutable ITwinSavedViewsClient
: Fix fetch requests failing when request body contains forbidden characters
@itwin/[email protected]
Breaking changes
captureSavedViewData
: RemovecaptureHiddenModelsAndCategories
setting from parameter bag. This function now behaves as if its value is alwaystrue
.createViewState
: Change function signature to takeViewData
instead ofSavedViewRepresentation
and use parameter bag for additional settings- Remove experimental
ModelCategoryOverrideProvider
class - Remove experimental
applyExtensionsToViewport
function
Minor changes
- Add
applySavedView
function - Promote
createViewState
to public API
@itwin/[email protected]
Patch changes
- Expose parameter types used in
SavedViewsClient
methods
@itwin/[email protected]
Minor changes
- Add
extensions
property toSavedView
type - Add
creationTime
andlastModified
properties toSavedView
type - Update
ITwinSavedViewsClient
to includecreationTime
andlastModified
ingetSavedViewInfo
,getSingularSavedView
,createSavedView
, andupdateSavedView
responses
@itwin/[email protected]
Fixes
LayeredMenuItem
: Fix chevron not aligning itself with item content
Dependencies
- Bump
@itwin/saved-views-client
package version from^0.2.1
to^0.3.0
@itwin/[email protected]
Minor changes
- Add
creationTime
andlastModified
properties toSavedView
type
@itwin/[email protected]
Breaking changes
SavedViewTile
:onRename
callback can now receiveundefined
value fornewName
parameter to indicate that user has canceled rename operationuseSavedViews
: RenamecreateSavedView
tosubmitSavedView
. When the first argument is a partialSavedView
object, this operation will now update or create a Saved View using the supplied information.
Minor changes
- Add optional
creatorId
property toSavedView
andSavedViewGroup
types - Add support for placing context menu button within
StickyExpandableBlock
title ITwinSavedViewsClient.deleteGroup
: Delete all views contained within group before attempting to delete the group itselfLayeredDropdownMenu
: Improve keyboard navigationLayeredMenuItem
: ForwardclassName
property to wrapping HTML elementLayeredMenuItem
: Increase spacing between label and right chevronSavedViewOptions
: ForwardclassName
property to wrapping HTML elementuseSavedViews
:- View and Group creation operations now sort stored locally stored Views / Groups
- Failed View and Group delete operations now restore deleted items to their original spots
Fixes
SavedViewTile
: Fix context menu button not appearing whenoptions
prop receives a function with zero parameters- Fix text overflow issues in
SavedViewTile
andStickyExpandableBlock
components by truncating titles with ellipses - Fix an issue with
useSavedViews
failing to load Saved View thumbnails when a cached data source is used
Dependencies
- Bump
@itwin/itwinui-react
package version from^3.0.11
to^3.8.1
- Update and bump
@itwin/saved-views-client
package version specifier from0.2.0
to^0.2.1
@itwin/[email protected]
Fixes
- Fix
ITwinSavedViewsClient.updateSavedView
failing when saved view data contains URL fields