Commit 047d9f9 andxu282
committed
1 parent a3cbb70 commit 047d9f9 Copy full SHA for 047d9f9
File tree 1 file changed +9
-1
lines changed
src/components/ScheduleGenerate
1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 46
46
<button
47
47
class =" add-requirement-button"
48
48
@click =" addRequirement"
49
- :disabled =" Object.keys(availableRequirements). length === 0 "
49
+ :disabled =" requirements. length === numberOfRequirements "
50
50
>
51
51
+ Requirement
52
52
</button >
@@ -76,6 +76,7 @@ export default defineComponent({
76
76
data(): {
77
77
requirements: string [];
78
78
availableRequirements: Record <string , string >;
79
+ numberOfRequirements: number ;
79
80
} {
80
81
return {
81
82
requirements: [],
@@ -84,6 +85,7 @@ export default defineComponent({
84
85
' Probability Requirement' : ' Probability Requirement' ,
85
86
' Liberal Studies' : ' Liberal Studies' ,
86
87
},
88
+ numberOfRequirements: 3 ,
87
89
};
88
90
},
89
91
components: {
@@ -305,4 +307,10 @@ export default defineComponent({
305
307
font-size : 16px ;
306
308
align-items : center ;
307
309
}
310
+
311
+ .add-requirement-button :disabled {
312
+ border : 1px solid $inactiveGray ;
313
+ background : $inactiveGray ;
314
+ cursor : not-allowed ;
315
+ }
308
316
</style >
You can’t perform that action at this time.
0 commit comments