Skip to content

Commit

Permalink
Fix compatibility with latest UI version (various broken styles)
Browse files Browse the repository at this point in the history
  • Loading branch information
blmage committed Oct 26, 2024
1 parent e70a7c2 commit ea69331
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 11 deletions.
15 changes: 10 additions & 5 deletions src/common/components/Dropdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,19 +130,24 @@ const ITEM_ICON = 'item_icon';
const CLASS_NAMES = {
// Copied from the "courses" menu.
[CONTEXT_CHALLENGE]: {
[WRAPPER]: [ '_1UOaB', '_2ifIT', '_3ApTJ' ],
[CONTENT]: [ '_1DLP9', '_1sDll' ],
[ARROW]: [ 'Vpm8Y' ],
[ARROW_ICON]: [ '_1IAp5' ],
[ITEMS]: [ '_2Xp7p' ],
[WRAPPER]: [ '_1UOaB', '_2ifIT', '_3ApTJ', '_3zpnU', '_3OfAS', '_1o3g5' ],
[CONTENT]: [ '_1DLP9', '_1sDll', '_36bu_', '_2xxCs' ],
[ARROW]: [ 'Vpm8Y', '_3T97b' ],
[ARROW_ICON]: [ '_1IAp5', '_1TMn5' ],
[ITEMS]: [ '_2Xp7p', '_3BhSk' ],
[ITEM_WRAPPER]: [
// Copied from the "My Courses" item (adds a bottom border).
'_2CU3K',
'_34_P_',
// Copied from any item from the "More" menu.
'_3vGNs',
'_2YF0P',
'_2np5u',
'yb-vp',
'_1gEmM',
'_7jW2t',
'_3QrGV',
'GHXZL',
],
// Copied by searching for the main (link) color without side-effects.
[ITEM_ICON]: [ '_27FUO', '_1PPA6' ],
Expand Down
4 changes: 2 additions & 2 deletions src/common/components/Modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,9 +178,9 @@ const SIZE_BUTTON = 'size_button';

const CLASS_NAMES = {
[BASE]: {
// Copied from the modal backdrop ('*[data-test="drawer-backdrop"'] at the moment).
// Copied from the modal backdrop ('*[data-test="drawer-backdrop"]' at the moment).
// The class name responsible for the opacity, if any, must not be included here.
[OVERLAY]: [ '_3wtIn', 'Vm8CO', '_1Fnem', '_3ovH6' ],
[OVERLAY]: [ '_3wtIn', 'Vm8CO', '_3ovH6', '_1Fnem', '_1ATOC' ],
// Copied from the global wrapper of the "Report" modal content.
// The class name responsible for the opacity, if any, must not be included here.
[POSITIONER]: [ '_3Mzt6', '_3ovH6' ],
Expand Down
8 changes: 4 additions & 4 deletions src/common/components/Pagination.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,18 +168,18 @@ const CLASS_NAMES = {
[ITEM]: [ '_3FVNQ', 'wQ_9d' ],
// Copied from the special letter buttons.
[BUTTON]: [
'_8AMBh',
'_2vfJy',
'_3Qy5R',
'_2yFpW',
'_1Qh5D',
'_36g4N',
'_2YF0P',
'_2yFpW',
'_2V6ug',
'_1ursp',
'_7jW2t',
],
[DISABLED_BUTTON]: [
'_20q0d',
'_1NM1Q',
'_2wryV',
// Copied by searching for a class that resets the bottom border, alongside the other button classes.
'_1_xfn',
],
Expand Down
6 changes: 6 additions & 0 deletions src/common/components/UserReference.js
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,12 @@ const CLASS_NAMES = {
'_2YF0P',
'_3DbUj',
'_38g3s',
// -----
'_1rcV8',
'_1VYyp',
'_1ursp',
'_7jW2t',
'_2VWgj',
],
// Copied from the "Continue" button when the given answer is correct.
[COMMIT_BUTTON]: [ '_2oGJR' ],
Expand Down

0 comments on commit ea69331

Please sign in to comment.