Skip to content

Commit

Permalink
chore: fix select style
Browse files Browse the repository at this point in the history
close #3193
  • Loading branch information
zhouhanseng committed May 28, 2021
1 parent 336b323 commit 86e1528
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 17 deletions.
17 changes: 7 additions & 10 deletions packages/maskbook/src/_locales/ko/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,6 @@
"eanble_or_disable_plugin": "플러그인 사용/사용 안 함",
"feedback": "피드백",
"fingerprint": "지문",
"activity": "활동",
"activity_inbound": "받기",
"activity_outbound": "보내기",
"buy": "매수하기",
"buy_now": "바로 매수하기",
"setup_guide_optional": "[옵션널]",
Expand Down Expand Up @@ -343,6 +340,8 @@
"plugin_wallet_settings_portfolio_data_source_secondary": "포트폴리오 데이터 소스 선택",
"plugin_wallet_settings_collectible_data_source_primary": "수집품 데이터 소스",
"plugin_wallet_settings_collectible_data_source_secondary": "수집품 데이터 소스 선택",
"plugin_wallet_fail_to_sign": "",
"plugin_wallet_cancel_sign": "",
"plugin_red_packet_display_name": "플러그인: 빨간 백",
"plugin_red_packet_split_mode": "분할 모드",
"plugin_red_packet_average": "평균",
Expand All @@ -351,7 +350,10 @@
"plugin_red_packet_best_wishes": "행운을 빌어요!",
"plugin_red_packet_create_new": "새로운 것 만들기",
"plugin_red_packet_claim": "수령",
"plugin_red_packet_claiming": "",
"plugin_red_packet_refund": "반환",
"plugin_red_packet_empty": "",
"plugin_red_packet_refunding": "",
"plugin_red_packet_select_existing": "기존 빨간 백 선택",
"plugin_red_packet_attached_message": "첨부 메시지",
"plugin_red_packet_from": "보낸사람: {{name}}",
Expand All @@ -364,22 +366,17 @@
"plugin_red_packet_description_failover": "{{name}} / {{shares}}에서 / {{total}} {{symbol}} 공유합니다.",
"plugin_red_packet_claiming_from": "{{name}}에서 빨간 팩 받는 중",
"plugin_red_packet_refunding_for": "{{balance}} {{symbol}} 빨간 백 반환 중",
"plugin_red_packet_claiming": "",
"plugin_red_packet_empty": "",
"plugin_red_packet_refunding": "",
"plugin_red_packet_amount_per_share": "공유 총액",
"plugin_red_packet_send_symbol": "{{symbol}} 보내기",
"plugin_red_packet_create_with_token": "{{symbol}} 으로 빨간 백 만드는 중",
"plugin_gitcoin_readme": "이 서비스를 이용하면 <fund>Gitcoin 개발 기금에 당신의 기여금</fund>의 5%를 기부할 것이다.",
"plugin_gitcoin_readme_fund_link": "https://gitcoin.co/grants/86/gitcoin-sustainability-fund",
"plugin_wallet_fail_to_sign": "",
"plugin_wallet_cancel_sign": "",
"plugin_red_packet_history_duration": "",
"plugin_red_packet_history_total_amount": "",
"plugin_red_packet_history_total_claimed_amount": "",
"plugin_red_packet_history_claimed": "",
"plugin_red_packet_history_split_mode": "",
"plugin_red_packet_history_send": "",
"plugin_gitcoin_readme": "이 서비스를 이용하면 <fund>Gitcoin 개발 기금에 당신의 기여금</fund>의 5%를 기부할 것이다.",
"plugin_gitcoin_readme_fund_link": "https://gitcoin.co/grants/86/gitcoin-sustainability-fund",
"plugin_gitcoin_select_a_token": "토큰 선택",
"plugin_gitcoin_enter_an_amount": "수액 입력",
"plugin_gitcoin_grant_not_available": "이용 불가",
Expand Down
13 changes: 6 additions & 7 deletions packages/maskbook/src/plugins/RedPacket/UI/RedPacketForm.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { useState, useRef, useCallback, useMemo, ChangeEvent, useEffect } from 'react'
import { makeStyles, FormControl, TextField, InputLabel, Select, MenuItem, MenuProps } from '@material-ui/core'
import { omit } from 'lodash-es'
import classNames from 'classnames'
import { v4 as uuid } from 'uuid'
import BigNumber from 'bignumber.js'

Expand Down Expand Up @@ -43,10 +42,7 @@ const useStyles = makeStyles((theme) => ({
flex: 1,
padding: theme.spacing(0.5),
},
selectInput: {
paddingLeft: theme.spacing(2),
paddingRight: theme.spacing(2),
},

tip: {
fontSize: 12,
color: theme.palette.text.secondary,
Expand All @@ -55,6 +51,10 @@ const useStyles = makeStyles((theme) => ({
marginTop: theme.spacing(1.5),
},
selectShrinkLabel: {
top: 6,
backgroundColor: theme.palette.background.default,
paddingLeft: 2,
paddingRight: 7,
transform: 'translate(17px, -10px) scale(0.75) !important',
},
inputShrinkLabel: {
Expand Down Expand Up @@ -255,10 +255,9 @@ export function RedPacketForm(props: RedPacketFormProps) {
return (
<>
<div className={classes.line}>
<FormControl className={classNames(classes.input, classes.selectInput)} variant="outlined">
<FormControl className={classes.input} variant="outlined">
<InputLabel className={classes.selectShrinkLabel}>{t('plugin_red_packet_split_mode')}</InputLabel>
<Select
variant="standard"
value={isRandom ? 1 : 0}
onChange={(e) => {
// foolproof, reset amount since the meaning of amount changed:
Expand Down

0 comments on commit 86e1528

Please sign in to comment.