Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
N
Neos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
love_飞影
Neos
Commits
1baf87eb
Commit
1baf87eb
authored
Aug 09, 2023
by
timel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: empty
parent
bf4cb9b9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
5 deletions
+28
-5
src/ui/BuildDeck/index.module.scss
src/ui/BuildDeck/index.module.scss
+11
-0
src/ui/BuildDeck/index.tsx
src/ui/BuildDeck/index.tsx
+16
-4
src/ui/Shared/IconFont/index.tsx
src/ui/Shared/IconFont/index.tsx
+1
-1
No files found.
src/ui/BuildDeck/index.module.scss
View file @
1baf87eb
...
@@ -116,6 +116,7 @@
...
@@ -116,6 +116,7 @@
}
}
.search-cards-container
{
.search-cards-container
{
height
:
100%
;
.search-cards
{
.search-cards
{
--card-width
:
80px
;
--card-width
:
80px
;
display
:
grid
;
display
:
grid
;
...
@@ -128,3 +129,13 @@
...
@@ -128,3 +129,13 @@
.search-count
{
.search-count
{
font-size
:
11px
;
font-size
:
11px
;
}
}
.empty
{
gap
:
20px
;
width
:
100%
;
height
:
100%
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
center
;
align-items
:
center
;
}
src/ui/BuildDeck/index.tsx
View file @
1baf87eb
...
@@ -15,16 +15,21 @@ import {
...
@@ -15,16 +15,21 @@ import {
Space
,
Space
,
type
ThemeConfig
,
type
ThemeConfig
,
}
from
"
antd
"
;
}
from
"
antd
"
;
import
classNames
from
"
classnames
"
;
import
{
memo
,
useEffect
,
useState
}
from
"
react
"
;
import
{
memo
,
useEffect
,
useState
}
from
"
react
"
;
import
{
LoaderFunction
}
from
"
react-router-dom
"
;
import
{
LoaderFunction
}
from
"
react-router-dom
"
;
import
{
v4
as
v4uuid
}
from
"
uuid
"
;
import
{
v4
as
v4uuid
}
from
"
uuid
"
;
import
{
useSnapshot
}
from
"
valtio
"
;
import
{
useSnapshot
}
from
"
valtio
"
;
import
{
subscribeKey
}
from
"
valtio/utils
"
;
import
{
subscribeKey
}
from
"
valtio/utils
"
;
import
{
type
CardMeta
,
fetchCard
,
searchCards
}
from
"
@/api
"
;
import
{
type
CardMeta
,
searchCards
}
from
"
@/api
"
;
import
{
deckStore
,
type
IDeck
,
initStore
}
from
"
@/stores
"
;
import
{
deckStore
,
type
IDeck
,
initStore
}
from
"
@/stores
"
;
import
{
Background
,
Loading
,
ScrollableArea
,
YgoCard
}
from
"
@/ui/Shared
"
;
import
{
Background
,
IconFont
,
Loading
,
ScrollableArea
,
YgoCard
,
}
from
"
@/ui/Shared
"
;
import
{
CardDetail
}
from
"
./CardDetail
"
;
import
{
CardDetail
}
from
"
./CardDetail
"
;
import
{
DeckSelect
}
from
"
./DeckSelect
"
;
import
{
DeckSelect
}
from
"
./DeckSelect
"
;
...
@@ -202,7 +207,14 @@ const CardSelect: React.FC = () => {
...
@@ -202,7 +207,14 @@ const CardSelect: React.FC = () => {
</
Button
>
</
Button
>
</
div
>
</
div
>
<
ScrollableArea
className=
{
styles
[
"
search-cards-container
"
]
}
>
<
ScrollableArea
className=
{
styles
[
"
search-cards-container
"
]
}
>
<
SearchResults
results=
{
searchResult
}
/>
{
searchResult
.
length
?
(
<
SearchResults
results=
{
searchResult
}
/>
)
:
(
<
div
className=
{
styles
.
empty
}
>
<
IconFont
type=
"icon-empty"
size=
{
40
}
/>
<
div
>
无搜索结果
</
div
>
</
div
>
)
}
</
ScrollableArea
>
</
ScrollableArea
>
</
div
>
</
div
>
);
);
...
...
src/ui/Shared/IconFont/index.tsx
View file @
1baf87eb
import
{
createFromIconfontCN
}
from
"
@ant-design/icons
"
;
import
{
createFromIconfontCN
}
from
"
@ant-design/icons
"
;
const
_IconFont
=
createFromIconfontCN
({
const
_IconFont
=
createFromIconfontCN
({
scriptUrl
:
[
"
//at.alicdn.com/t/c/font_4188978_
kvwn9bcpnx
.js
"
],
scriptUrl
:
[
"
//at.alicdn.com/t/c/font_4188978_
m65y344sn8h
.js
"
],
});
});
export
const
IconFont
:
React
.
FC
<
{
export
const
IconFont
:
React
.
FC
<
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment