-
Notifications
You must be signed in to change notification settings - Fork 382
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
Convert modding profile component to typescript #10311
Merged
nanaya
merged 19 commits into
ppy:master
from
notbakaneko:feature/ts-modding-profile-main
Jul 6, 2023
Merged
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
efe02d2
convert to typescript (rename)
notbakaneko b14dbb3
convert to typescript (mostly)
notbakaneko 5fbdf2f
add UserModdingProfileJson type
notbakaneko b083dcd
no saved state to restore
notbakaneko f34a66a
applying mobx
notbakaneko 91351f5
userUpdate shouldn't be needed?
notbakaneko 29c9f74
use computeds
notbakaneko 16a6d74
convert to typescript (rename)
notbakaneko b8921e1
convert to typescript
notbakaneko aeca1dd
remove unused/unneeded; change to default export
notbakaneko e6dd8d3
remove _ import
notbakaneko 8b36c64
bad dot
notbakaneko ac0c40f
no longer needed
notbakaneko f2d378a
allow tab bar to be visible on mobile layout
notbakaneko d28e0c2
apparently Set can be spread directly
notbakaneko aa1516c
Fix error during show more on kudosu section.
notbakaneko d750015
move shared includes
notbakaneko f8b5906
PureComponent observer makes no sense
notbakaneko dea465f
Merge branch 'master' into feature/ts-modding-profile-main
nanaya 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 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 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 was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the GNU Affero General Public License v3.0. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
import Main from 'modding-profile/main'; | ||
import core from 'osu-core-singleton'; | ||
import React from 'react'; | ||
import { parseJson } from 'utils/json'; | ||
|
||
core.reactTurbolinks.register('modding-profile', () => ( | ||
<Main | ||
beatmaps={parseJson('json-beatmaps')} | ||
beatmapsets={parseJson('json-beatmapsets')} | ||
discussions={parseJson('json-discussions')} | ||
events={parseJson('json-events')} | ||
extras={parseJson('json-extras')} | ||
perPage={parseJson('json-perPage')} | ||
posts={parseJson('json-posts')} | ||
user={parseJson('json-user')} | ||
users={parseJson('json-users')} | ||
votes={parseJson('json-votes')} | ||
/> | ||
)); |
This file contains 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 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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the GNU Affero General Public License v3.0. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
import UserExtendedJson from './user-extended-json'; | ||
import { ProfileHeaderIncludes } from './user-json'; | ||
|
||
type ModdingProfileIncludes = | ||
ProfileHeaderIncludes | ||
| 'graveyard_beatmapset_count' | ||
| 'loved_beatmapset_count' | ||
| 'pending_beatmapset_count' | ||
| 'ranked_beatmapset_count' | ||
| 'statistics'; | ||
|
||
type UserModdingProfileJson = UserExtendedJson & Required<Pick<UserExtendedJson, ModdingProfileIncludes>>; | ||
|
||
export default UserModdingProfileJson; |
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.
what's this change doing here 🤔 although I guess it's simple enough so this can stay
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.
max_blocks
isn't supposed to beundefined
and this just makes the default 0 so pages that don't need editing can skip adding a provider without causingmax_blocks
to beundefined