Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
frontend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vicotor
frontend
Commits
ab3fb647
Commit
ab3fb647
authored
Aug 30, 2022
by
tom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try to adapt forms and modals
parent
ceb2d373
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
3 deletions
+21
-3
Form.ts
theme/components/Form.ts
+3
-0
Modal.ts
theme/components/Modal.ts
+15
-0
PublicTagsForm.tsx
ui/publicTags/PublicTagsForm/PublicTagsForm.tsx
+2
-2
FormModal.tsx
ui/shared/FormModal.tsx
+1
-1
No files found.
theme/components/Form.ts
View file @
ab3fb647
...
@@ -121,6 +121,9 @@ const variantFloating: PartsStyleFunction<typeof parts> = (props: StyleFunctionP
...
@@ -121,6 +121,9 @@ const variantFloating: PartsStyleFunction<typeof parts> = (props: StyleFunctionP
margin
:
0
,
margin
:
0
,
transformOrigin
:
'
top left
'
,
transformOrigin
:
'
top left
'
,
transitionProperty
:
'
font-size, line-height, padding, top, background-color
'
,
transitionProperty
:
'
font-size, line-height, padding, top, background-color
'
,
overflow
:
'
hidden
'
,
whiteSpace
:
'
nowrap
'
,
textOverflow
:
'
ellipsis
'
,
},
},
'
input:not(:placeholder-shown) + label, textarea:not(:placeholder-shown) + label
'
:
{
'
input:not(:placeholder-shown) + label, textarea:not(:placeholder-shown) + label
'
:
{
...
activeLabelStyles
,
...
activeLabelStyles
,
...
...
theme/components/Modal.ts
View file @
ab3fb647
...
@@ -59,6 +59,21 @@ const sizes = {
...
@@ -59,6 +59,21 @@ const sizes = {
maxW
:
'
760px
'
,
maxW
:
'
760px
'
,
},
},
},
},
full
:
{
dialog
:
{
borderRadius
:
'
none
'
,
padding
:
'
80px 16px 32px 16px
'
,
},
closeButton
:
{
top
:
4
,
right
:
6
,
width
:
6
,
height
:
6
,
},
header
:
{
mb
:
6
,
},
},
};
};
const
Modal
:
ComponentMultiStyleConfig
=
{
const
Modal
:
ComponentMultiStyleConfig
=
{
...
...
ui/publicTags/PublicTagsForm/PublicTagsForm.tsx
View file @
ab3fb647
...
@@ -52,7 +52,7 @@ const placeholders = {
...
@@ -52,7 +52,7 @@ const placeholders = {
comment
:
'
Specify the reason for adding tags and color preference(s).
'
,
comment
:
'
Specify the reason for adding tags and color preference(s).
'
,
}
as
Record
<
Path
<
Inputs
>
,
string
>
;
}
as
Record
<
Path
<
Inputs
>
,
string
>
;
const
ADDRESS_INPUT_BUTTONS_WIDTH
=
1
7
0
;
const
ADDRESS_INPUT_BUTTONS_WIDTH
=
1
0
0
;
const
PublicTagsForm
=
({
changeToDataScreen
,
data
}:
Props
)
=>
{
const
PublicTagsForm
=
({
changeToDataScreen
,
data
}:
Props
)
=>
{
const
queryClient
=
useQueryClient
();
const
queryClient
=
useQueryClient
();
...
@@ -152,7 +152,7 @@ const PublicTagsForm = ({ changeToDataScreen, data }: Props) => {
...
@@ -152,7 +152,7 @@ const PublicTagsForm = ({ changeToDataScreen, data }: Props) => {
<
Box
width=
{
`calc(100% - ${ ADDRESS_INPUT_BUTTONS_WIDTH }px)`
}
maxWidth=
"844px"
>
<
Box
width=
{
`calc(100% - ${ ADDRESS_INPUT_BUTTONS_WIDTH }px)`
}
maxWidth=
"844px"
>
{
isAlertVisible
&&
<
Box
mb=
{
4
}
><
FormSubmitAlert
/></
Box
>
}
{
isAlertVisible
&&
<
Box
mb=
{
4
}
><
FormSubmitAlert
/></
Box
>
}
<
Text
size=
"sm"
variant=
"secondary"
paddingBottom=
{
5
}
>
Company info
</
Text
>
<
Text
size=
"sm"
variant=
"secondary"
paddingBottom=
{
5
}
>
Company info
</
Text
>
<
Grid
templateColumns=
"1fr 1fr"
rowGap=
{
4
}
columnGap=
{
5
}
>
<
Grid
templateColumns=
{
{
base
:
'
1fr
'
,
lg
:
'
1fr 1fr
'
}
}
rowGap=
{
4
}
columnGap=
{
5
}
>
<
GridItem
>
<
GridItem
>
<
PublicTagsFormInput
<
Inputs
>
<
PublicTagsFormInput
<
Inputs
>
fieldName="fullName"
fieldName="fullName"
...
...
ui/shared/FormModal.tsx
View file @
ab3fb647
...
@@ -39,7 +39,7 @@ export default function FormModal<TData>({
...
@@ -39,7 +39,7 @@ export default function FormModal<TData>({
},
[
onClose
,
setAlertVisible
]);
},
[
onClose
,
setAlertVisible
]);
return
(
return
(
<
Modal
isOpen=
{
isOpen
}
onClose=
{
onModalClose
}
size=
"md"
>
<
Modal
isOpen=
{
isOpen
}
onClose=
{
onModalClose
}
size=
{
{
base
:
'
full
'
,
lg
:
'
md
'
}
}
>
<
ModalOverlay
/>
<
ModalOverlay
/>
<
ModalContent
>
<
ModalContent
>
<
ModalHeader
fontWeight=
"500"
textStyle=
"h3"
>
{
title
}
</
ModalHeader
>
<
ModalHeader
fontWeight=
"500"
textStyle=
"h3"
>
{
title
}
</
ModalHeader
>
...
...
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