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

Hide CFM menu inside of the Activity Player #1557

Merged
merged 1 commit into from
Oct 23, 2024

Conversation

scytacki
Copy link
Member

@scytacki scytacki commented Oct 22, 2024

The CFM menu is hidden when the interactiveApi URL param is present.

The interactiveApi url param is added to the URL when a "Interactive API" share link is copied from the CFM share dialog.

The CODAP v2 code also checked for older url params lara and launchFromLara.

codap/apps/dg/core.js

Lines 354 to 359 in 9b54cf1

hideCFMMenu: function () {
var interactiveApi = getUrlParameter('interactiveApi'),
// handle presence of the parameter without a value
hasInteractiveApiParam = !!interactiveApi || (interactiveApi === null);
return hasInteractiveApiParam || !!getUrlParameter('launchFromLara') || !!getUrlParameter('lara');
}.property(),

I checked and there are no URLs in the LARA authoring system which use those older params, so I didn't include support for them in the CODAPv3 code.

The interactieApi url param is added to the URL when a activity player embedded share link is copied
from the CFM share menu.
The CODAP v2 code also checked for older url params `lara` and `launchFromLara`. There are no interactives
in the LARA authoring system which use those older params, so support for them is dropped.
Copy link

codecov bot commented Oct 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.50%. Comparing base (16f6e70) to head (9b54cf1).
Report is 5 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1557   +/-   ##
=======================================
  Coverage   84.50%   84.50%           
=======================================
  Files         582      582           
  Lines       29435    29435           
  Branches     7547     7547           
=======================================
  Hits        24875    24875           
  Misses       4404     4404           
  Partials      156      156           
Flag Coverage Δ
cypress 74.13% <ø> (ø)
jest 52.50% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

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

Copy link

cypress bot commented Oct 22, 2024

codap-v3    Run #4739

Run Properties:  status check passed Passed #4739  •  git commit 7afee37e87: Merge pull request #1557 from concord-consortium/188415994-in-ap-hide-cfm-menu
Project codap-v3
Branch Review main
Run status status check passed Passed #4739
Run duration 08m 47s
Commit git commit 7afee37e87: Merge pull request #1557 from concord-consortium/188415994-in-ap-hide-cfm-menu
Committer Scott Cytacki
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 45
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 218
View all changes introduced in this branch ↗︎

@scytacki scytacki changed the title if interactiveApi url param, then hide cfm menu Hide CFM menu inside of the Activity Player Oct 22, 2024
@scytacki scytacki marked this pull request as ready for review October 23, 2024 00:14
@scytacki scytacki requested a review from kswenson October 23, 2024 00:14
Copy link
Member

@kswenson kswenson left a comment

Choose a reason for hiding this comment

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

👍 Looks good! In practice the hideMenuBar option in the CFM config seems to hide the hamburger menu rather than the menu bar, but that's a preexisting condition.

@kswenson kswenson added the v3 CODAP v3 label Oct 23, 2024
@scytacki scytacki merged commit 7afee37 into main Oct 23, 2024
19 checks passed
@scytacki scytacki deleted the 188415994-in-ap-hide-cfm-menu branch October 23, 2024 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants