-
Notifications
You must be signed in to change notification settings - Fork 0
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
questionnaire/newのText系の実装 #920
Conversation
modelvalue追加しないとCheckboxElementの入れ替えでうまくいかないこと忘れてました。
InputTextで代用できるのでいらないかもしれません
レビューお願いします |
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.
いい感じだと思います:+1:
@@ -0,0 +1,70 @@ | |||
<template> |
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.
これをUIいかに置いてくれてるのはいいですね:+1:
だいたいは直したんですけど、直してない点が二つくらいあります。 |
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.
通話で言ったこと
<QuestionUpdown | ||
:index="i" | ||
:max="questions.length" | ||
:class="$style.border" | ||
@swap="swapQuestions" | ||
/> |
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.
<QuestionUpdown | |
:index="i" | |
:max="questions.length" | |
:class="$style.border" | |
@swap="swapQuestions" | |
/> | |
<QuestionUpdown | |
:class="$style.border" | |
:up-disable="i === 0" | |
:down-disable="i === questions.length - 1" | |
@up="() => swapQuestions(i, i - 1)" | |
@down="() => swapQuestions(i, i + 1)" | |
/> |
こんな感じにしてほしい
@@ -0,0 +1,125 @@ | |||
<template> |
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.
QuestionContentにしてほしい
return false | ||
} | ||
}) | ||
const questionIsRequired = computed(() => props.isRequired) |
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.
これ自体なくてよくない?
updateQuestionIsRequiredはprops使えばいい気がする
figmaをみて直してみました。前のレビューで言われたところでfigmaと違うところがあったので、figmaのほうに合わせたんですが直さないほうがよかったらすみません |
import QuestionTypeSelect from './Forms/QuestionTypeSelect.vue' | ||
|
||
export default defineComponent({ | ||
name: 'Question', |
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.
name: 'Question', | |
name: 'QuestionContent', |
index: { | ||
type: Number, | ||
required: true | ||
} |
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.
これいらないよね?
questionarray: { | ||
type: Array, | ||
required: true | ||
}, | ||
index: { |
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.
おなじくいらない?
width: 28px; | ||
height: 21px; |
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.
これは指定しなくていいかな(意図として指定したいのはfontsizeとline-heightなので)
color: $ui-secondary; | ||
} | ||
&:hover { | ||
background-color: $bg-secondary-highlight; |
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.
アクションに対して色変えるときはtransitionほしいです
src/components/UI/InputText.vue
Outdated
@@ -1,8 +1,13 @@ | |||
<template> | |||
<div> | |||
<div :class="[isNumber ? $style.spin : '']"> |
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.
複雑になっちゃったんでInputTextBaseみたいなのをつくってNumberとTextでわけたいですね
nonEvents: { | ||
type: Boolean, | ||
default: false | ||
}, |
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.
pointer-eventsがnoneかどうかっていうprops名じゃなくてどういう場合にこのpropsを渡すのかっていうprops名にしたいです
src/components/UI/ToggleSwitch.vue
Outdated
background-color: $ui-primary; | ||
width: 34px; | ||
height: 20px; | ||
border-radius: 9999px; |
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.
意図が分かりづらいんでheight/2
で指定してほしいです
src/components/UI/ToggleSwitch.vue
Outdated
border-radius: 50%; | ||
background-color: $ui-white; | ||
opacity: 1; |
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.
いらないかな?
figmaみたら新規作成のところでInputTextいらなかったぽかったので、直しました。 |
InputNumberとInputTextBaseを消しました |
src/components/UI/InputNumber.vue
Outdated
nonEvents: { | ||
type: Boolean, | ||
default: false | ||
}, |
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.
ここ変えてほしいです
src/components/UI/InputNumber.vue
Outdated
modelValue: { | ||
type: String, | ||
required: true | ||
} |
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.
numberで受け取りたいです
src/components/UI/InputNumber.vue
Outdated
@@ -0,0 +1,139 @@ | |||
<template> | |||
<div :class="$style.spin"> |
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.
<div :class="$style.spin"> | |
<div :class="$style.container"> |
かな
src/components/UI/InputText.vue
Outdated
isLong: { | ||
type: Boolean, | ||
default: false | ||
}, |
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.
いらない?
.input { | ||
padding: 4px 8px; | ||
width: 100%; | ||
height: 32px; | ||
@include size-body; | ||
color: $ui-primary; | ||
box-sizing: border-box; | ||
border: none; | ||
border-bottom: $input-border solid $ui-secondary; | ||
outline: none; | ||
&::placeholder { | ||
padding: 4px 8px; | ||
width: 100%; | ||
height: 24px; | ||
@include size-body-small; | ||
color: $ui-secondary; | ||
} | ||
&:hover { | ||
background-color: $bg-secondary-highlight; | ||
transition: 0.1s; | ||
} | ||
&:focus { | ||
background-color: $bg-secondary-highlight; | ||
} | ||
} |
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.
ここが多分共通だと思うんでInputBase
でうまいこと共通化したいです
import InputText from './InputText.vue' | ||
|
||
export default defineComponent({ | ||
name: 'InputTextBase', |
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.
name: 'InputTextBase', | |
name: 'InputBase', |
@@ -0,0 +1,60 @@ | |||
<template> |
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.
<tempate>
<input 共通のクラスを付ける />
</template>
で、InputBaseWithUnderline
で
<tempate>
<div>
<slot />
<underline />
</div>
</template>
で、InputText
とかで
<tempate>
<input-base-with-underline>
<input-base Text固有のクラスを付ける />
</input-base-with-underline>
</template>
ですかね?
こっちのほうがスマートじゃね?って思ったら言ってください
コミットされる前のやつを見てコメントしちゃった |
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.
多分いいと思う:+1:
No description provided.