File tree 1 file changed +7
-4
lines changed
1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,7 @@ const analyzeDayAndPeriod = (str: string): { day: Day; period: number }[] => {
60
60
*/
61
61
const analyzeModule = ( str : string ) : Module [ ] => {
62
62
const result : Module [ ] = [ ]
63
+
63
64
64
65
/*
65
66
/春[ABC]*A/は春A 春AB 春ABCに
@@ -70,15 +71,17 @@ const analyzeModule = (str: string): Module[] => {
70
71
if ( / 春 [ A B C ] * B / gm. test ( str ) ) result . push ( Module . SpringB )
71
72
if ( / 春 [ A B C ] * C / gm. test ( str ) ) result . push ( Module . SpringC )
72
73
73
- // 春季休業中のマッチング
74
- if ( str . includes ( Module . SpringVacation ) ) result . push ( Module . SpringVacation )
74
+ // 夏季休業中、通年のマッチング
75
+ if ( str . includes ( Module . SummerVacation ) ) result . push ( Module . SummerVacation )
75
76
76
77
if ( / 秋 [ A B C ] * A / gm. test ( str ) ) result . push ( Module . FallA )
77
78
if ( / 秋 [ A B C ] * B / gm. test ( str ) ) result . push ( Module . FallB )
78
79
if ( / 秋 [ A B C ] * C / gm. test ( str ) ) result . push ( Module . FallC )
80
+
81
+ // 春季休業中のマッチング
82
+ if ( str . includes ( Module . SpringVacation ) ) result . push ( Module . SpringVacation )
79
83
80
- // 秋季休業中、通年のマッチング
81
- if ( str . includes ( Module . SummerVacation ) ) result . push ( Module . SummerVacation )
84
+ // 通年のマッチング
82
85
if ( str . includes ( Module . Annual ) ) result . push ( Module . Annual )
83
86
84
87
//どのモジュールにも判定されなかったが空文字ではない場合、仮にunknownとする
You can’t perform that action at this time.
0 commit comments