This repository was archived by the owner on Aug 29, 2025. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 72
3.1 props refactoring #106
Merged
Merged
Changes from all commits
Commits
Show all changes
32 commits
Select commit
Hold shift + click to select a range
7394393
refactor virtualization, virtualization settings, and derived props
81e0802
refactor renaming paging / pagination props
646068b
refactor virtual, viewport and pagination into adapters
3b13dbb
isolate derived props
4e0ecad
build update
fadbe4b
fix regression
8c60f0b
improve typing
7013574
fix test regression
b606834
simplify pagination adapter / refactor
ec68944
lint
ba80945
clean up unused props
f9ce473
- change factory
78a1844
Merge remote-tracking branch 'origin/master' into 3.0-props-refactoring
452de9b
fix lint
8ec667e
bump version
b334918
add dash level props for virtual_dataframe
80a2c02
refactor fp / derived props
2b674ee
derived props
b2fc917
refactor viewport and virtual controlled props
6ba5403
fix fp regression
e546390
fix fp regression
a520da6
refactor controlled table / table fp
d9e294d
controlled table purecomponent
770effa
fix test (rebrake it!)
6577df5
fix selection regression for be paging/sorting/filtering
e86b8fd
improve re-renders & controlled props
c816691
fix test regressions
f02ee15
update inner-selection fixture
cd06e6c
merge master into 3.0-props-refactoring
5af4a70
remove useless spy
9b12845
- fix pr comment
231ab9d
clean up
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -12,8 +12,8 @@ export default class Table extends Component { | |
| } | ||
|
|
||
| export const defaultProps = { | ||
| virtualization: 'fe', | ||
| virtualization_settings: { | ||
| pagination_mode: 'fe', | ||
| pagination_settings: { | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. virtualization made no sense -- this is about pagination, renaming |
||
| displayed_pages: 1, | ||
| current_page: 0, | ||
| page_size: 250 | ||
|
|
@@ -28,8 +28,10 @@ export const defaultProps = { | |
| sorting_type: 'single', | ||
| sorting_settings: [], | ||
|
|
||
| virtual_dataframe: [], | ||
| virtual_dataframe_indices: [], | ||
| derived_viewport_dataframe: [], | ||
| derived_viewport_indices: [], | ||
| derived_virtual_dataframe: [], | ||
| derived_virtual_indices: [], | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. New read-only derived properties |
||
|
|
||
| column_conditional_dropdowns: [], | ||
| column_static_dropdown: [], | ||
|
|
@@ -40,48 +42,14 @@ export const defaultProps = { | |
| row_conditional_styles: [], | ||
| row_static_style: {}, | ||
|
|
||
| changed_data: {}, | ||
| dataframe: [], | ||
| columns: [], | ||
| editable: false, | ||
| active_cell: [], | ||
| index_name: '', | ||
| types: {}, | ||
| merged_styles: {}, | ||
| selected_cell: [[]], | ||
| selected_rows: [], | ||
| row_selectable: false, | ||
| table_style: [], | ||
| base_styles: { | ||
| numeric: { | ||
| 'text-align': 'right', | ||
| 'font-family': `'Droid Sans Mono', Courier, monospace` | ||
| }, | ||
|
|
||
| string: { | ||
| 'text-align': 'left' | ||
| }, | ||
|
|
||
| input: { | ||
| padding: 0, | ||
| margin: 0, | ||
| width: '80px', | ||
| border: 'none', | ||
| 'font-size': '1rem' | ||
| }, | ||
|
|
||
| 'input-active': { | ||
| outline: '#7FDBFF auto 3px' | ||
| }, | ||
|
|
||
| table: {}, | ||
|
|
||
| thead: {}, | ||
|
|
||
| th: {}, | ||
|
|
||
| td: {} | ||
| } | ||
| table_style: [] | ||
| }; | ||
|
|
||
| export const propTypes = { | ||
|
|
@@ -111,8 +79,8 @@ export const propTypes = { | |
| rule: PropTypes.string | ||
| })), | ||
|
|
||
| virtualization: PropTypes.oneOf(['fe', 'be', true, false]), | ||
| virtualization_settings: PropTypes.shape({ | ||
| pagination_mode: PropTypes.oneOf(['fe', 'be', true, false]), | ||
| pagination_settings: PropTypes.shape({ | ||
| displayed_pages: PropTypes.number, | ||
| current_page: PropTypes.number, | ||
| page_size: PropTypes.number | ||
|
|
@@ -171,8 +139,10 @@ export const propTypes = { | |
| })), | ||
| sorting_treat_empty_string_as_none: PropTypes.bool, | ||
|
|
||
| virtual_dataframe: PropTypes.arrayOf(PropTypes.object), | ||
| virtual_dataframe_indices: PropTypes.arrayOf(PropTypes.number), | ||
| derived_viewport_dataframe: PropTypes.arrayOf(PropTypes.object), | ||
| derived_viewport_indices: PropTypes.arrayOf(PropTypes.number), | ||
| derived_virtual_dataframe: PropTypes.arrayOf(PropTypes.object), | ||
| derived_virtual_indices: PropTypes.arrayOf(PropTypes.number), | ||
|
|
||
| dropdown_properties: PropTypes.any, | ||
| }; | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
A memoize function that knows if the cache has been hit or not