Commit Graph

81 Commits

Author SHA1 Message Date
Muhammed Mustafa
49b728d31b refactor: disable naming-convenction rule (#51685) 2023-09-30 20:23:39 +07:00
Muhammed Mustafa
6c31e71029 feat: remove slim width row (#51318) 2023-08-21 17:16:40 +03:00
Oliver Eyton-Williams
c3ce96069a fix: only show loader message on layout (#50556) 2023-05-31 17:22:09 +05:30
Muhammed Mustafa
734a88e5d2 feat(client): delete invalid default profile image (#50352)
* feat(client): delete a not valid variable

* set validation to false if using the image

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>

---------

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
2023-05-16 09:57:54 -07:00
Muhammed Mustafa
3c28323a2c feat(client): remove the height from the space component (#50244) 2023-05-15 12:41:31 -07:00
Vansh Baghel
d43c9b69d7 feat(client): children for spacer component (#50105)
* Replaced padding calculation with paddingBlock, for both children and deefault

* Ran cmd : pnpm run test-client -u to fix checks

* fix snapshot

* Changed calculation, removed extra div

* medium to large in donate

* PaddingBlock to padding, added new values for Padding obj

* Fix snapshots

---------

Co-authored-by: Muhammed Mustafa <muhammed@freecodecamp.org>
2023-04-27 12:51:58 +02:00
Vansh Baghel
85795068a3 feat(client): Customized Radio Buttons in settings page (#50094)
Co-authored-by: Bruce B <bbsmooth@gmail.com>
2023-04-27 08:07:21 +00:00
Manabu Matsumoto
9136f8e408 fix(UI): give the spacer a few standard sizes (#49723)
Co-authored-by: Muhammed Mustafa <muhammed@freecodecamp.org>
2023-03-21 08:17:42 +00:00
Manabu Matsumoto
ba40dbddbb fix(UI): remove the ButtonSpacer (#49480)
Co-authored-by: Muhammed Mustafa <muhammed@freecodecamp.org>
Co-authored-by: Ahmad Abdolsaheb <ahmad.abdolsaheb@gmail.com>
2023-03-15 15:31:56 +03:00
xarcode
de87492cf8 refactor(client): togglebutton's layout from float to flex (#49510)
* Refactor the togglebutton from float to flex

* Update toggle-button.css
2023-02-27 18:12:31 +01:00
Muhammed Mustafa
0971b6a8a3 refactor(client): remove react lazy loader library (#49468)
* feat(client): remove react lazy loader library

* fix: use loading='lazy' to defer loading
2023-02-22 18:05:08 +01:00
Jeff
9f1562291c fix: remove unused className spacer from spacer helper (#49067)
* fix: remove unused className spacer from spacer helper

---------

Co-authored-by: jeff <jeff@vpmbp4.local>
2023-02-21 19:20:29 +05:30
Muhammed Mustafa
181e108418 fix(client): submit button size for external projects (#49448) 2023-02-21 07:40:56 +01:00
Muhammed Mustafa
85e9fbb8df refactor(client): clean extra component and extra unneeded imports (#49391)
* feat: remove extra unnecessary code

* clean the unique way that component was handled

* make bsSize optional

* update snapshot to account for the other button styles

* add comment for our future selves

* clean the changes file
2023-02-19 17:16:53 +05:30
Muhammed Mustafa
251aecc58f feat(client): change the save buttons from disabled to aria-disabled (#49216)
* feat(client): change the buttons from disabled to aria-disabled

Co-authored-by: Bruce Blaser <bbsmooth@gmail.com>

* stop the API call when the validation isn't true

* use aria disabled instead of disabled on the test?

* use have.attr  to check for aria disabled

* hide the button when it's disabled

Co-authored-by: Bruce B <bbsmooth@gmail.com>

* update Privacy Settings save button

---------

Co-authored-by: Bruce Blaser <bbsmooth@gmail.com>
2023-02-18 12:16:35 -08:00
Oliver Eyton-Williams
4ff00922da refactor: fix hidden eslint errors (#49365)
* refactor: explicit types for validate

* refactor: explicit return types for ui-components

* refactor: use exec instead of match

* refactor: add lots more boundary types

* refactor: more eslint warnings

* refactor: more explicit exports

* refactor: more explicit types

* refactor: even more explicit types

* fix: relax type contrainsts for superblock-order

* refactor: final boundaries

* refactor: avoid using 'object' type

* fix: use named import for captureException

This uses TypeScript (which works) instead of import/namespace
(which doesn't) to check if captureException exists in sentry/gatsby
(it does)
2023-02-13 07:13:50 -08:00
Muhammed Mustafa
57317a4a32 feat(client): full width component to carry key prop (#49082)
* feat(client): allow full width to carry key props

* fix: setting can't render the element error

* Remove the key prop from FullWidthRow

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* remove key form fullwidth

* Remove undefined type from children

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* add key to renderProfile

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2023-01-26 08:20:28 +01:00
Mrugesh Mohapatra
f2fcfe593d fix(client): add message to loader (#48934)
Co-authored-by: Muhammed Mustafa <muhammed@freecodecamp.org>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com>
2023-01-06 19:03:52 -08:00
Muhammed Mustafa
8cc575c9b9 feat: swap to logical properties for spacing (#48769) 2022-12-22 10:51:19 +05:30
Muhammed Mustafa
3279ab161e feat(client): refactor universal nav missing types (#48144)
* feat(client): refactor universal nav missing types

* extends link type from gatsby link types


Co-authored-by: auchynnikau <viachaslau_auchynnikau@epam.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2022-10-27 20:20:59 +05:30
Anubhav Jain
88c54192b9 fix(client): remove unused files (#47974)
* removed unused files

Removed unused files as per comments for issue #47971

* fix: removed duplicate exports from 4 files

* Build fix

* made changes for build fix

* made changes for build fix
2022-10-14 18:54:09 +05:30
Niraj Nandish
53164e71f1 fix: circular dependencies (#46638)
* fix: circular dependency in formHelpers

* fix: circular dependency in Flash

* fix: circular dependency in helpers

* fix: circular dependency in current-challenge-saga (1/2)

* fix: circular dependency in code-lock-epic

* feat: eslint rule for circular dependencies

* fix: circular dependency in tools

* fix: import error and more circular dependencies in formHelpers

* fix prettier error

* fix: circular dependency in danger-zone-saga

* fix: circular dependency in update-email-saga

* fix: circular dependency in settings-saga

* fix: circular dependency in accept-terms-saga

* fix: circular dependency in codeally-saga

TODO: make a separate file for selectors

* fix: ci lint error

* fix: ci lint:prettier error

* fix: circular dependency in current-challenge-saga

* fix: cricular dependency in Challenges/redux

* fix: circular dependency in redux/settings

* fix: circular dependency in root redux

* fix: lint errors

* chore: remove unecessary comment

* chore: remove unused export

* fix: clear out actions and selectors

* revert changes to package.json

* test ci with maxDepth of 1

* fix: fallback to empty object

* test action if it will run for maxDepth of 2
2022-10-05 18:08:40 +01:00
Triumph Joshua Odemudia
adcce7fb6d Chore: Typescript Migration for Index.js file (#45447) 2022-03-17 15:34:19 +05:30
Oliver Eyton-Williams
a726dd381f fix(client): prevent data url render (#44658)
* fix: only render profile urls

* feat: warn user when submitting data url

* fix: prevent dataurls being saved to db

* fix: tests and imports

Not sure why jest didn't like the es imports, but they aren't necessary
so I dropped them.

* fix: check for url protocol
2022-01-04 11:05:40 +05:30
Nicholas Carrigan (he/him)
118bf713ae fix(client): remove broken current challenge button (#44405) 2021-12-08 01:05:32 +05:30
Oliver Eyton-Williams
efba2e777d chore: simplify eslint configuration (#44347)
* chore: extend import/recommended

* chore: use recommended lint rules

* refactor: apply lint rules

* chore: drop used config
2021-12-02 00:01:12 +00:00
Ahmad Abdolsaheb
513f27e408 feat: add seasonal learn alert (#44335)
* feat:  add seasonal learn alert

* Update client/src/components/Intro/index.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/pages/learn.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-11-30 09:35:35 -08:00
AndreiD049
a07a16b38b fix: added possibility to revert back to default profile picture (#43962)
* added possibility to revert to default profile picture

* removed required from picture input

* remove addPlaceholderImage and replaced with empty string

* added test for empty string to avatar-renderer
2021-10-25 21:06:32 +02:00
Ahmad Abdolsaheb
1fec73cdf7 feat(client): Unify donation loading state (#43179)
* initial loading state unification

* feat(client): show buttons after 3 seconds

* fix: use window.setInterval explicitly

Otherwise TS assumes that it's node's setInterval

* feat(client): remove spinner when first button load

* feat(client): move the loader to the donate page button area

* feat(client): extract grid from modal donation form

* feat(client): remove duplicate donation forms

* feat(client):extract unused components from donationForm

* feat(client): load paypal on load not onInit (for perf)

* feat(client): set paypal loading state if stripe already loaded

* feat(clinet):make lpaypal oading condition strickt.

* Apply suggestions from code review

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* feat: clean up

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-08-19 14:47:25 -05:00
Oliver Eyton-Williams
e118dda13a fix: order imports and remove circular dependencies (#41824)
* fix: remove circular dependency

redux depended on templates/Challenges/redux and vice versa.  This
meant that import order mattered and confusing bugs could arise.

(cherry picked from commit 7d67a4e70922bbb3051f2f9982dcc69e240d43dc)

* feat: require imports to be in alphabetical order

Import order generally does not matter, but there are edge cases
(circular  imports and css imports, for example) where changing order
changes behaviour

(cherry picked from commit b8d1393a91ec6e068caf8e8498a5c95df68c2b2c)

* chore: order imports

* fix: lift up challenge description + title comps

This brings the classic Show closer to the others as they
now all create the description and title components

* fix: remove donation-saga/index circular import

(cherry picked from commit 51a44ca668a700786d2744feffeae4fdba5fd207)

* refactor: extract action-types from settings

(cherry picked from commit 25e26124d691c84a0d0827d41dafb761c686fadd)

* fix: lint errors

* feat: prevent useless renames
2021-08-02 08:39:40 -05:00
Victor Duarte
a4358fc56c fix(client): update display prop on element (#42912)
* fix: profile menu icon overlapping content

* refactor: profile icon usage
2021-07-27 12:27:32 +03:00
Anirudh Modi
ef3b7ec955 chore(eslint): enables recommended eslint rules for testing-library and jest-dom (#42817) 2021-07-20 21:21:16 +07:00
Ismail Tlemcani
4307179d00 fix broken image url after submission on profile page (#42507) 2021-07-12 13:26:10 +02:00
Moshe
63f26db336 refactor(client): Replace <Fragment> tags to <> (#42796)
* refactor(40115): Replace <Fragment> tags to <>
2021-07-09 09:50:11 +02:00
Tom
b334031b2f fix(client): runtime error with icons/space component (#42665)
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-06-30 20:52:17 +05:30
Parth Parth
61d1020dd7 feat(client): ts-migrate footer (#42636)
Co-authored-by: Parth Parth <thecodingaviator@users.noreply.github.com>
2021-06-30 20:52:17 +05:30
Nicholas Carrigan (he/him)
592a2846d3 chore: pass CI (#42635)
* chore: eslint on icons

* chore: eslint spacer element

* chore: remove more eslint

* fix: existing lint issues

* fix: misnamed import

* fix: client now builds!

* fix: tsc errors

* fix: more linting issues
2021-06-30 20:52:17 +05:30
Oliver Eyton-Williams
d87b472ee7 Fix: assorted next fixes (#42634)
* chore: fix slightly broken package.json

* fix: update children type

* fix: make size optional for Spacer

* fix: correct broken env import

* test: update snapshot and fix typing

* test: fix imports and remove old snapshot
2021-06-30 20:52:17 +05:30
Parth Parth
8c1084a97b feat(client): ts-migrate client/src/components/helpers/form and client/src/components/formHelpers (#42476)
* client(feat): migrate client/src/components/helpers/form

* compete migration

* migrate formHelpers

* migrate BlockSaveButton and BlockSaveWrapper

* finish migration

* kebab-caseify

* Update client/src/components/formHelpers/block-save-button.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix linting errors

* make props optional

Co-authored-by: Parth Parth <thecodingaviator@users.noreply.github.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-06-30 20:50:57 +05:30
Parth Parth
f15a55e2b4 feat(client): Migrate <Link> to ts (#42467)
* rename

* migrate

* fix: remove duplicate

* fix: linting

Co-authored-by: Parth Parth <thecodingaviator@users.noreply.github.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-06-30 20:50:56 +05:30
Parth Parth
0a3a5e7a53 feat(client): migrate icons to TS (#42453)
* migrate files and update tests

fix: use more memory for gatsby develop (#42433)

feat(client): remove whitespace from calculated values (#42400)

* feat(client?): remove whitespace for calculated values

* feat(client): remove whitespace from styledeclaration

* do not automatically strip

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix: include all properties of CSSStyleDeclaration

* fix test for getPropVal

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

fix: get showUpcomingChange from env.json (#42440)

fix(client): display legacy certs like current ones (#42038)

* fix: display legacy certs like the current ones

* fix: link projects in legacy certs to project pages

* fix: update tests to changed legacy cert display

* fix: update tests for removed legacy certs forms

* fix: display legacy certs like the current ones

* fix: submit projects for cert on projects pages

* fix: remove legacy certs form submitting handling

* fix: move claiming cert setup before both tests

* fix: remove legacy cert update props and actions

* fix: remove legacy cert updates from api

* fix: correct merge conflict

fix(curriculum): rework Project Euler 98 (#42423)

* fix: rework challenge to use argument in function

* fix: add solution

* fix: use MathJax to improve math notation

fix(curriculum): rework Project Euler 56 (#42364)

* fix: rework challenge to use argument in function

* fix: add solution

* fix: use MathJax to improve look of math notation

fix(curriculum): correct small english typo (#42447)

chore: group together monaco-editor and plugin (#42443)

This should get renovate to create PRs where both are modified.

fix(deps): update dependency algoliasearch to v4.9.2 (#42432)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

migrate files and update tests

Algorithm moved to TSX

first ten files renamed to tsx

first 10 migration complete

first 20 files renamed

migrate some files. rename all

test

index.tsx forced to ignore ts issues

rename and migrate all files

update tests

* remove missed propType declarations

* kebab-caseify

* fi xlinting

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Parth Parth <thecodingaviator@users.noreply.github.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-06-30 20:50:56 +05:30
Marlon Johnson
4b44bb37d9 feat(client): ts-migrate client/src/components/helpers/** (#42593)
* refactor(client): convert toggle-button to TypeScript

* chore: rename Space to tsx

* refactor(client): convert space to TypeScript

* chore: rename SlimWidthRow to tsx

* refactor(client): slim-width-row to TypeScript

* chore: rename SkeletonSprite to ts

* fix: fixed typos and resolved paths

* chore: resolve path inconsistencies

* refactor(client): skelton-sprite to TypeScript

* chore: rename loader.test to tsx

* chore: add types for react-spinkit

* refactor(client): loader to TypeScript

* refactor(client): link to TypeScript

* refactor(client): image-loader to TypeScript

* refactor(client): full-width-row to TypeScript

* refactor(client): current-challenge-link to TypeScript

* refactor(client): button to TypeScript

* refactor(client): border-color-picker to TypeScript

* refactor(client): avatar-renderer to TypeScript

* chore: changed loadertest(snap) to ts

* chore: optional types added and cleaned files

* fix: args are now optional

* push small updates for Spacer component merge

* update snapshot

* remove type defs from deps

* Revert "remove type defs from deps"

This reverts commit 9f58bf3554.

* correctly remove client type deps

* final push to remove from deps

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-06-30 20:50:56 +05:30
Huyen Nguyen
2c16234853 chore: add jest global variables (#42573) 2021-06-20 09:14:42 +02:00
Mrugesh Mohapatra
ad9b1f89d8 fix(api, client): update Gatsby, webpack & related things (#41452)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-03-25 12:13:43 -07:00
Oliver Eyton-Williams
fffc0e51ec chore(client): refactor & organise config (#40875) 2021-02-03 15:22:07 +05:30
Tom
625469c82f feat: improve ui/ux learn map (#40579)
Co-authored-by: Kris Koishigawa <scissorsneedfoodtoo@gmail.com>
2021-01-31 12:15:39 +05:30
Tom
3978c6be28 feat: i18n user interface (#40306)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-01-31 12:15:32 +05:30
Ashraf Nazar
9831df18e0 feat(profile): Add Top Contributor badge feature (#38348)
Co-authored-by: Twaha Rahman <39026437+Twaha-Rahman@users.noreply.github.com>
Co-authored-by: Twaha Rahman <mahi6703890@gmail.com>
Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com>
2020-11-16 13:49:45 +05:30
Oliver Eyton-Williams
b9db30f7a1 refactor(client): move jest-dom into setup file 2020-10-12 14:11:52 +02:00
Ahmad Abdolsaheb
4e51e845bb fix: remove duplicate of borderColorPicker (#39732) 2020-09-30 14:56:30 +05:30