-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix: 초성, 중성, 종성을 사용하도록 통일 * fix: 표기 수정 * fix: 표기 수정 * fix: 표기 수정 * fix: v2 반영 * fix: 불필요한 파일 삭제 * fix: import 수정 * fix: 테스트 코드 수정
- Loading branch information
1 parent
65e2c7c
commit 08adfc9
Showing
33 changed files
with
349 additions
and
307 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import { disassembleCompleteCharacter } from './disassembleCompleteCharacter'; | ||
|
||
describe('disassembleCompleteCharacter', () => { | ||
it('값', () => { | ||
expect(disassembleCompleteCharacter('값')).toEqual({ | ||
choseong: 'ㄱ', | ||
jungseong: 'ㅏ', | ||
jongseong: 'ㅂㅅ', | ||
}); | ||
}); | ||
|
||
it('리', () => { | ||
expect(disassembleCompleteCharacter('리')).toEqual({ | ||
choseong: 'ㄹ', | ||
jungseong: 'ㅣ', | ||
jongseong: '', | ||
}); | ||
}); | ||
|
||
it('빚', () => { | ||
expect(disassembleCompleteCharacter('빚')).toEqual({ | ||
choseong: 'ㅂ', | ||
jungseong: 'ㅣ', | ||
jongseong: 'ㅈ', | ||
}); | ||
}); | ||
|
||
it('박', () => { | ||
expect(disassembleCompleteCharacter('박')).toEqual({ | ||
choseong: 'ㅂ', | ||
jungseong: 'ㅏ', | ||
jongseong: 'ㄱ', | ||
}); | ||
}); | ||
|
||
it('완전한 한글 문자열이 아니면 undefined를 반환해야 합니다.', () => { | ||
expect(disassembleCompleteCharacter('ㄱ')).toBeUndefined; | ||
expect(disassembleCompleteCharacter('ㅏ')).toBeUndefined; | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
import { Syllable } from './rules.types'; | ||
|
||
export function replace받침ㅎ(currentSyllable: Syllable): Syllable['last'] { | ||
return currentSyllable.last.replace('ㅎ', '') as Syllable['last']; | ||
export function replace받침ㅎ(currentSyllable: Syllable): Syllable['jongseong'] { | ||
return currentSyllable.jongseong.replace('ㅎ', '') as Syllable['jongseong']; | ||
} |
Oops, something went wrong.