Skip to content
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

#8607 Replace remaining occurrences of mod component form state "elements" #8712

Merged
merged 11 commits into from
Jun 28, 2024

Conversation

mnholtz
Copy link
Collaborator

@mnholtz mnholtz commented Jun 27, 2024

What does this PR do?

Copy link

codecov bot commented Jun 27, 2024

Codecov Report

Attention: Patch coverage is 42.55319% with 27 lines in your changes missing coverage. Please review.

Project coverage is 73.66%. Comparing base (c32e86f) to head (81075c0).
Report is 56 commits behind head on main.

Files Patch % Lines
src/pageEditor/sidebar/modals/CreateModModal.tsx 0.00% 8 Missing ⚠️
src/pageEditor/starterBricks/base.ts 14.28% 6 Missing ⚠️
...c/pageEditor/tabs/effect/ExtensionPointPreview.tsx 80.95% 4 Missing ⚠️
src/pageEditor/sidebar/modals/MoveFromModModal.tsx 0.00% 3 Missing ⚠️
src/pageEditor/starterBricks/adapter.ts 0.00% 3 Missing ⚠️
src/pageEditor/sidebar/AddStarterBrickButton.tsx 0.00% 2 Missing ⚠️
src/pageEditor/panes/EditorPane.tsx 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8712      +/-   ##
==========================================
- Coverage   73.69%   73.66%   -0.04%     
==========================================
  Files        1344     1346       +2     
  Lines       41566    41655      +89     
  Branches     7775     7805      +30     
==========================================
+ Hits        30633    30684      +51     
- Misses      10933    10971      +38     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

github-actions bot commented Jun 27, 2024

Playwright test results

passed  80 passed
skipped  2 skipped

Details

report  Open report ↗︎
stats  82 tests across 29 suites
duration  11 minutes, 25 seconds
commit  81075c0

Skipped tests

chrome › tests/runtime/googleSheetsIntegration.spec.ts › can activate a google spreadsheet mod with config options
edge › tests/runtime/googleSheetsIntegration.spec.ts › can activate a google spreadsheet mod with config options

@@ -155,22 +156,22 @@ const CreateModModalBody: React.FC = () => {
}, [dispatch]);

const initialModMetadataFormState = useInitialFormState({
activeElement: activeModComponent,
activeModComponentFormState: activeModComponent,
Copy link
Contributor

@twschiller twschiller Jun 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rename the local variable produced by useSelector(selectActiveModComponentFormState);

@@ -56,7 +56,9 @@ const MoveFromModModal: React.FC = () => {
const { isRemoveFromModModalVisible: show } = useSelector(
selectEditorModalVisibilities,
);
const activeElement = useSelector(selectActiveModComponentFormState);
const activeModComponentFormState = useSelector(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT: I don't think the "active" prefix is necessary here. It just makes the code wordier

Copy link

No loom links were found in the first post. Please add one there if you'd like to it to appear on Slack.

Do not edit this comment manually.

@twschiller
Copy link
Contributor

LGTM: see comment on one inaccurate name

@twschiller twschiller added this to the 2.0.4 milestone Jun 27, 2024
): DraftModComponent {
const elementConfig = ADAPTERS.get(formState.type);
const adapter = ADAPTERS.get(modComponentFormState.type);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❤️

@twschiller twschiller merged commit 98232c7 into main Jun 28, 2024
18 checks passed
@twschiller twschiller deleted the feature/8607_slice_6 branch June 28, 2024 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Rename element -> modComponentFormState
2 participants