mirror of
https://codeberg.org/andyscott/ExerciseTracker.git
synced 2024-11-09 06:00:48 -05:00
Set default unit to "lbs" and updated placeholder text
This commit is contained in:
parent
2b36d6bfa7
commit
6a8c513204
1 changed files with 11 additions and 11 deletions
|
@ -6,7 +6,7 @@ export const CreatePage = () => {
|
||||||
const [name, setName] = useState("");
|
const [name, setName] = useState("");
|
||||||
const [reps, setReps] = useState("");
|
const [reps, setReps] = useState("");
|
||||||
const [weight, setWeight] = useState("");
|
const [weight, setWeight] = useState("");
|
||||||
const [unit, setUnit] = useState("");
|
const [unit, setUnit] = useState("lbs");
|
||||||
const [date, setDate] = useState("");
|
const [date, setDate] = useState("");
|
||||||
|
|
||||||
const history = useHistory();
|
const history = useHistory();
|
||||||
|
@ -31,31 +31,31 @@ export const CreatePage = () => {
|
||||||
<h2>Create Exercise</h2>
|
<h2>Create Exercise</h2>
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Enter name here"
|
placeholder="Exercise name"
|
||||||
value={name}
|
value={name}
|
||||||
onChange={(e) => setName(e.target.value)}
|
onChange={(e) => setName(e.target.value)}
|
||||||
/>
|
/>
|
||||||
<input
|
<input
|
||||||
type="number"
|
type="number"
|
||||||
placeholder="Enter reps here"
|
min="1"
|
||||||
|
placeholder="# of reps"
|
||||||
value={reps}
|
value={reps}
|
||||||
onChange={(e) => setReps(e.target.value)}
|
onChange={(e) => setReps(e.target.value)}
|
||||||
/>
|
/>
|
||||||
<input
|
<input
|
||||||
type="number"
|
type="number"
|
||||||
placeholder="Enter weight here"
|
min="1"
|
||||||
|
placeholder="Weight"
|
||||||
value={weight}
|
value={weight}
|
||||||
onChange={(e) => setWeight(e.target.value)}
|
onChange={(e) => setWeight(e.target.value)}
|
||||||
/>
|
/>
|
||||||
|
<select value={unit} onChange={(e) => setUnit(e.target.value)}>
|
||||||
|
<option value="lbs">lbs</option>
|
||||||
|
<option value="kgs">kgs</option>
|
||||||
|
</select>
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Enter unit here"
|
placeholder="Date (MM-DD-YY)"
|
||||||
value={unit}
|
|
||||||
onChange={(e) => setUnit(e.target.value)}
|
|
||||||
/>
|
|
||||||
<input
|
|
||||||
type="text"
|
|
||||||
placeholder="Enter date here"
|
|
||||||
value={date}
|
value={date}
|
||||||
onChange={(e) => setDate(e.target.value)}
|
onChange={(e) => setDate(e.target.value)}
|
||||||
/>
|
/>
|
||||||
|
|
Loading…
Reference in a new issue