-
Notifications
You must be signed in to change notification settings - Fork 47
Add support for formatting pane new model interfaces #49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
ShereinDabbah
commented
Jun 22, 2022
- bump to version 5.0.0
- Add formatting pane model interfaces
- Separate visuals and formatting pane interfaces into two files
Export powerbi module Update changelog
This reverts commit 9e00af2.
|
Please wait for api 4.8 before completing this one. |
src/formatting-model-api.d.ts
Outdated
|
|
||
| export interface FormattingModelMessageAction { | ||
| key: string; | ||
| fn: () => void; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what does fn() do? does the CV pass the code into the host?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont know how it exactly works, But I see that yes it run some code in our side in some html file in front end.
Should I delete it ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if this is code that the visual provides then we should remove it.
| topLevelToggle?: EnabledSlice; | ||
| groups: (FormattingGroup | FormattingGroupPlaceholder)[]; | ||
| /** This contains the list of descriptors for revert to default, note the descriptors of all the slices ever possible in the card must be added */ | ||
| revertToDefaultDescriptors?: FormattingDescriptor[]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hey can you explain what the purpose of this is?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revertToDefaultDescriptors is the list of all formatting properties descriptors (descriptor is objectName and propertyName - the same as in capabilites) in this formatting card that will be reverted/reset their values to their default values when we click on Reset to default option which appears in each formatting card.
revertToDefaultDescriptors is required if we want to use the Reset to default option and reset all of the properties in card in one click
| * signal action is taken. E.g., for an Analytics Pane forecast, the forecast parameter values shouldn't be | ||
| * saved to the visual until the Apply button is clicked. Note that this applies to all slices in the group. | ||
| */ | ||
| delaySaveSlices?: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this applicable to CVs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont know exactly what is the use of this
src/formatting-model-api.d.ts
Outdated
| } | ||
|
|
||
| /** | ||
| * Handles resolving the type of placeholder that's expected to be return. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: to be returned.
src/formatting-model-api.d.ts
Outdated
|
|
||
| interface Slider extends NumUpDown { } | ||
|
|
||
| // ideally we would set type here to number, but the old formatting pane always converts enum members to string |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this comment required?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, will be deleted