├── docs ├── min-CLF.mp4 ├── min-ghopensource.png ├── docs.js ├── index.html ├── updates │ └── README.md └── styles.css ├── projfiles ├── icon │ ├── YCLF.psd │ ├── icon.png │ ├── icon16.png │ ├── icon24.png │ ├── icon32.png │ ├── icon48.png │ ├── icon1024.png │ ├── icon128.png │ ├── icon512.png │ └── 제목_없는_아트워크.psd ├── firefox-addons-banner │ ├── Firefox-Get-The-Addon-Badge.png │ └── min-Firefox-Get-The-Addon-Badge.png └── chrome-web-store-banner │ ├── ChromeWebStore_BadgeWBorder.ai │ ├── ChromeWebStore_BadgeWBorder.pdf │ ├── ChromeWebStore_BadgeWBorder.png │ └── min-ChromeWebStore_BadgeWBorder.png ├── v1 ├── images │ ├── min-icon128.png │ ├── min-icon16.png │ ├── min-icon24.png │ ├── min-icon32.png │ ├── min-icon48.png │ ├── min-icon512.png │ └── min-icon1024.png ├── inject.css ├── pages │ ├── styles.css │ ├── reportbug.html │ ├── popup.html │ └── options.html ├── manifest.json └── scripts │ ├── popup.js │ ├── background.js │ ├── options.js │ └── content.js ├── .prettierrc ├── README.md ├── LICENSE.md └── .gitignore /docs/min-CLF.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/docs/min-CLF.mp4 -------------------------------------------------------------------------------- /projfiles/icon/YCLF.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/YCLF.psd -------------------------------------------------------------------------------- /projfiles/icon/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon.png -------------------------------------------------------------------------------- /docs/min-ghopensource.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/docs/min-ghopensource.png -------------------------------------------------------------------------------- /projfiles/icon/icon16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon16.png -------------------------------------------------------------------------------- /projfiles/icon/icon24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon24.png -------------------------------------------------------------------------------- /projfiles/icon/icon32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon32.png -------------------------------------------------------------------------------- /projfiles/icon/icon48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon48.png -------------------------------------------------------------------------------- /v1/images/min-icon128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon128.png -------------------------------------------------------------------------------- /v1/images/min-icon16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon16.png -------------------------------------------------------------------------------- /v1/images/min-icon24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon24.png -------------------------------------------------------------------------------- /v1/images/min-icon32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon32.png -------------------------------------------------------------------------------- /v1/images/min-icon48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon48.png -------------------------------------------------------------------------------- /v1/images/min-icon512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon512.png -------------------------------------------------------------------------------- /projfiles/icon/icon1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon1024.png -------------------------------------------------------------------------------- /projfiles/icon/icon128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon128.png -------------------------------------------------------------------------------- /projfiles/icon/icon512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/icon512.png -------------------------------------------------------------------------------- /v1/images/min-icon1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/v1/images/min-icon1024.png -------------------------------------------------------------------------------- /projfiles/icon/제목_없는_아트워크.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/icon/제목_없는_아트워크.psd -------------------------------------------------------------------------------- /projfiles/firefox-addons-banner/Firefox-Get-The-Addon-Badge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/firefox-addons-banner/Firefox-Get-The-Addon-Badge.png -------------------------------------------------------------------------------- /projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.ai: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.ai -------------------------------------------------------------------------------- /projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.pdf -------------------------------------------------------------------------------- /projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/chrome-web-store-banner/ChromeWebStore_BadgeWBorder.png -------------------------------------------------------------------------------- /projfiles/firefox-addons-banner/min-Firefox-Get-The-Addon-Badge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/firefox-addons-banner/min-Firefox-Get-The-Addon-Badge.png -------------------------------------------------------------------------------- /projfiles/chrome-web-store-banner/min-ChromeWebStore_BadgeWBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anaclumos/youtube-comment-language-filter/HEAD/projfiles/chrome-web-store-banner/min-ChromeWebStore_BadgeWBorder.png -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "semi": false, 3 | "singleQuote": true, 4 | "arrowParens": "always", 5 | "tabWidth": 2, 6 | "useTabs": false, 7 | "printWidth": 100, 8 | "trailingComma": "es5", 9 | "endOfLine": "lf", 10 | "bracketSpacing": true 11 | } -------------------------------------------------------------------------------- /v1/inject.css: -------------------------------------------------------------------------------- 1 | .CLFFooter { 2 | text-align: center; 3 | color: rgb(133, 133, 133); 4 | margin-bottom: 100px; 5 | font-weight: 500; 6 | } 7 | 8 | .CLFHeader { 9 | color: rgb(133, 133, 133); 10 | margin-bottom: 20px; 11 | margin-top: 20px; 12 | font-weight: 500; 13 | } 14 | -------------------------------------------------------------------------------- /v1/pages/styles.css: -------------------------------------------------------------------------------- 1 | html { 2 | font-family: -apple-system, system-ui, "Inter", "segoe ui", 3 | Helvetica, Arial, sans-serif, "apple color emoji", 4 | "segoe ui emoji", "segoe ui symbol"; 5 | color: black; 6 | display: inline-block; 7 | min-width: 250px; 8 | overflow: hidden; 9 | } 10 | 11 | button { 12 | margin-top: 5px; 13 | margin-bottom: 5px; 14 | width: 100%; 15 | } 16 | 17 | li { 18 | padding-top: 5px; 19 | padding-bottom: 5px; 20 | } 21 | 22 | a { 23 | color: black; 24 | } 25 | 26 | a:visited { 27 | text-decoration: none; 28 | } -------------------------------------------------------------------------------- /v1/pages/reportbug.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Options 9 | 10 | 11 | 12 | ← Back 13 |

Bug Reports

14 |

Please contact mail@chosunghyun.com.

15 |

Make sure to include the following details:

16 | 20 |

You can also submit a GitHub Issue instead.

21 | 22 | 23 | -------------------------------------------------------------------------------- /v1/pages/popup.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | YCLF Popup 10 | 11 | 12 | 13 |

Links

14 |
  • Learn 15 | more
  • 16 |
  • Settings
  • 17 |
  • Report a bug
  • 18 |

    Share with your friends 🧡

    19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## Note 2 | 3 | - Thank you for the love and support. 4 | - I am no longer maintaining this project. 5 | - If you want to fork & improve this project, please feel free to do so. 6 | 7 | ## But why? 8 | 9 | - YouTube now has [comment translations](https://9to5google.com/2021/09/15/youtube-on-ios-android-tests-instant-comment-translations-for-premium-subscribers/). 10 | - Google now forces [MV3](https://developer.chrome.com/docs/extensions/mv3/mv2-sunset/) & [GA4](https://support.google.com/analytics/answer/11583528). I have no interest in implementing those. 11 | 12 | ## Some memorable stuffs... 13 | 14 | - Chrome: ★ 4.61, 2,683 Weekly Active Users 15 | - Firefox: ★ 5.00, 56 Weekly Active Users 16 | 17 | image 18 | 19 | - Got Featured @ Chrome Store! 20 | -------------------------------------------------------------------------------- /v1/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "manifest_version": 2, 3 | "name": "YouTube Comment Language Filter", 4 | "icons": { 5 | "16": "images/min-icon16.png", 6 | "24": "images/min-icon24.png", 7 | "32": "images/min-icon32.png", 8 | "48": "images/min-icon48.png", 9 | "128": "images/min-icon128.png", 10 | "512": "images/min-icon512.png", 11 | "1024": "images/min-icon1024.png" 12 | }, 13 | "version": "1.3.7", 14 | "description": "YouTube Comments in Specific Language", 15 | "author": "Sunghyun Cho", 16 | "background": { 17 | "scripts": ["scripts/background.js"], 18 | "persistent": false 19 | }, 20 | "browser_action": { 21 | "default_popup": "pages/popup.html" 22 | }, 23 | "content_scripts": [ 24 | { 25 | "js": ["./scripts/content.js"], 26 | "matches": ["https://*.youtube.com/*"], 27 | "run_at": "document_end", 28 | "css": ["./inject.css"] 29 | } 30 | ], 31 | "homepage_url": "https://github.com/anaclumos/youtube-comment-language-filter", 32 | "permissions": ["tabs", "storage", "notifications"], 33 | "short_name": "YCLF" 34 | } 35 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 Sunghyun Cho 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /v1/scripts/popup.js: -------------------------------------------------------------------------------- 1 | const chromeStoreUrl = 2 | 'https://chrome.google.com/webstore/detail/youtube-comment-language/pliobnchkbenbollnjaaojhbjkjgfkni' 3 | const firefoxStoreUrl = 'https://addons.mozilla.org/firefox/addon/yclf/' 4 | 5 | window.onload = () => { 6 | document.getElementById('copy-chrome-url').addEventListener('click', function () { 7 | var tempElem = document.createElement('textarea') 8 | tempElem.value = chromeStoreUrl 9 | document.body.appendChild(tempElem) 10 | tempElem.select() 11 | document.execCommand('copy') 12 | document.body.removeChild(tempElem) 13 | document.getElementById('copy-chrome-url').innerText = 'Copied!' 14 | setTimeout(function () { 15 | document.getElementById('copy-chrome-url').innerText = 'Chrome Extension Store Link' 16 | }, 2000) 17 | }) 18 | document.getElementById('copy-firefox-url').addEventListener('click', function () { 19 | var tempElem = document.createElement('textarea') 20 | tempElem.value = firefoxStoreUrl 21 | document.body.appendChild(tempElem) 22 | tempElem.select() 23 | document.execCommand('copy') 24 | document.body.removeChild(tempElem) 25 | document.getElementById('copy-firefox-url').innerText = 'Copied!' 26 | setTimeout(function () { 27 | document.getElementById('copy-firefox-url').innerText = 'Firefox Add-ons Store Link' 28 | }, 2000) 29 | }) 30 | } 31 | -------------------------------------------------------------------------------- /v1/pages/options.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Document 10 | 11 | 12 | 13 | ← Back 14 |

    Settings

    15 |

    Save and refresh to apply settings.

    16 |

    Show Options

    17 |
    18 |
    19 |
    20 |
    21 |
    22 |

    Developer Mode

    23 |

    Enabling this will make YouTube slower.

    24 | 25 |

    Update Notifications

    26 |
    27 |
    28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /v1/scripts/background.js: -------------------------------------------------------------------------------- 1 | var extensionPage = 'https://chosunghyun.com/youtube-comment-language-filter' 2 | var updateLogPage = 'https://chosunghyun.com/youtube-comment-language-filter/updates' 3 | 4 | var showNotification = true 5 | chrome.storage.sync.get(['updateNotificationDisabled'], (result) => { 6 | showNotification = !result.updateNotificationDisabled 7 | if (showNotification) { 8 | chrome.runtime.onInstalled.addListener(function (object) { 9 | if (object.reason === 'install') { 10 | chrome.notifications.create(extensionPage, { 11 | title: 'YCLF is now installed 😎', 12 | message: 'Click here to learn more about the extension!', 13 | iconUrl: './images/min-icon128.png', 14 | type: 'basic', 15 | }) 16 | } else if (object.reason === 'update') { 17 | chrome.notifications.create(updateLogPage, { 18 | title: 'YCLF updated to v' + chrome.runtime.getManifest().version + ' 🚀', 19 | message: "Click here to check out what's new!", 20 | iconUrl: './images/min-icon128.png', 21 | type: 'basic', 22 | }) 23 | } 24 | }) 25 | chrome.notifications.onClicked.addListener(function (notificationId) { 26 | chrome.tabs.create({ url: notificationId }) 27 | }) 28 | } 29 | }) 30 | 31 | chrome.tabs.onUpdated.addListener(function (tabId, changeInfo) { 32 | if (changeInfo.url) { 33 | chrome.tabs.sendMessage(tabId, { 34 | message: 'page moved!', 35 | url: changeInfo.url, 36 | }) 37 | } 38 | }) 39 | -------------------------------------------------------------------------------- /docs/docs.js: -------------------------------------------------------------------------------- 1 | // window.onload = () => { 2 | // setLangtoEnglish(); 3 | // var langButton = document.getElementById("Language"); 4 | // langButton.addEventListener("change", function () { 5 | // if (langButton.value == "English") { 6 | // setLangtoEnglish(); 7 | // } else if (langButton.value == "Korean") { 8 | // setLangtoKorean(); 9 | // } 10 | // }); 11 | // } 12 | 13 | // function setLangtoEnglish() { 14 | // document.getElementById("main-text").innerHTML = ` 15 | //

    Hide language options:

    16 | //
      17 | //
    1. Click on the extension icon.
    2. 18 | //
    3. Go to settings.
    4. 19 | //
    5. Select options you want to hide, and save.
    6. 20 | //
    7. On the YouTube Watch page, there will be an option to filter comments below the description.
    8. 21 | //
    9. If you have something to say, please contact me via mail@chosunghyun.com
    10. 23 | //
    24 | // ` 25 | // } 26 | 27 | // function setLangtoKorean() { 28 | // document.getElementById("main-text").innerHTML = ` 29 | //

    선택지에서 제외하고 싶은 옵션이 있다면?

    30 | //
      31 | //
    1. 확장 프로그램 아이콘을 클릭하세요.
    2. 32 | //
    3. Settings를 누르세요.
    4. 33 | //
    5. 필요 없는 옵션들을 선택하고 Save를 눌러 저장하세요.
    6. 34 | //
    7. YouTube 동영상 페이지 설명란 하단에 댓글을 필터링할 수 있는 언어 선택 메뉴가 생길 것입니다.
    8. 35 | //
    9. 문의 사항은 mail@chosunghyun.com로 메일 부탁드립니다.
    10. 37 | //
    38 | // ` 39 | // } -------------------------------------------------------------------------------- /v1/scripts/options.js: -------------------------------------------------------------------------------- 1 | window.onload = () => { 2 | document.getElementById('save-button').addEventListener('click', function () { 3 | storeSetting() 4 | }) 5 | checkSetting() 6 | } 7 | 8 | function storeSetting() { 9 | const EnglishDisabled = !document.getElementById('lang-english-checkbox').checked 10 | const KoreanDisabled = !document.getElementById('lang-korean-checkbox').checked 11 | const JapaneseDisabled = !document.getElementById('lang-japanese-checkbox').checked 12 | const ChineseDisabled = !document.getElementById('lang-chinese-checkbox').checked 13 | const debugModeEnabled = document.getElementById('debug-checkbox').checked 14 | const updateNotificationDisabled = !document.getElementById('update-noti-checkbox').checked 15 | const setting = { 16 | EnglishDisabled: EnglishDisabled, 17 | KoreanDisabled: KoreanDisabled, 18 | JapaneseDisabled: JapaneseDisabled, 19 | ChineseDisabled: ChineseDisabled, 20 | debugModeEnabled: debugModeEnabled, 21 | updateNotificationDisabled: updateNotificationDisabled, 22 | } 23 | console.log(setting) 24 | chrome.storage.sync.set(setting, () => { 25 | console.log('Stored', setting) 26 | document.getElementById('save-button').innerHTML = 'Saved!' 27 | setTimeout(function () { 28 | document.getElementById('save-button').innerHTML = 'Save' 29 | }, 2000) 30 | }) 31 | } 32 | 33 | function checkSetting() { 34 | chrome.storage.sync.get( 35 | [ 36 | 'EnglishDisabled', 37 | 'KoreanDisabled', 38 | 'JapaneseDisabled', 39 | 'ChineseDisabled', 40 | 'debugModeEnabled', 41 | 'updateNotificationDisabled', 42 | ], 43 | (result) => { 44 | document.getElementById('lang-english-checkbox').checked = !result.EnglishDisabled 45 | document.getElementById('lang-korean-checkbox').checked = !result.KoreanDisabled 46 | document.getElementById('lang-japanese-checkbox').checked = !result.JapaneseDisabled 47 | document.getElementById('lang-chinese-checkbox').checked = !result.ChineseDisabled 48 | document.getElementById('debug-checkbox').checked = result.debugModeEnabled 49 | document.getElementById('update-noti-checkbox').checked = !result.updateNotificationDisabled 50 | } 51 | ) 52 | } 53 | -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 24 | 25 | 31 | 사용해주셔서 감사합니다. 32 | 33 | 34 | 35 |
    36 |

    사용해주셔서 감사합니다.

    37 |

    이제 동영상과 댓글 사이에 댓글의 언어를 선택할 수 있는 옵션이 생겨날 것입니다.

    38 | 42 |

    모든 사람들이 자유롭게 사용할 수 있는 오픈 프로젝트는 처음인지라 부족한 점이 많습니다. 제 미숙한 실력으로 인해서 발생하는 불편함은 너그러이 양해해주시면 감사하겠습니다. 프로젝트에 대한 문의 사항, 43 | 개선 사항이나 질문 등은 제 메일 mail@chosunghyun.com으로 보내주시면 성심성의껏 답변해드리겠습니다.

    44 |

    제대로 작동하지 않는 것 같은 경우에는 대부분 새로고침을 통해서 해결이 가능합니다.

    45 |

    개발 비하인드 스토리

    46 |

    블로그 포스트를 확인해주세요 🚀

    47 |

    Open Source

    48 | Open-sourced on GitHub.com 50 |

    YouTube Comment Language Filter는 100% 오픈소스 프로그램입니다. 인터페이스 개선 및 필터링 규칙 개선, 언어 추가 등의 업데이트를 통해 지속적으로 프로젝트를 개선할 51 | 계획입니다. 또한 현재 프로젝트는 언어 판별이 아닌 글자 판별에 의존하고 있습니다. 차후 업데이트를 통해 이를 개선할 예정입니다.

    52 |

    Updates

    53 | 업데이트 내용은 /updates에서 확인하실 수 있습니다. 54 |

    권한 설명

    55 |

    페이지 방문 기록 및 개인 정보는 일체 수집하지 않으며 외부로 전송되지 않습니다.

    56 |

    1. Read and change your data on all youtube.com sites

    57 |

    YouTube.com에서 데이터를 읽어들이고 변경할 수 있는 권한입니다. 이 권한은 댓글 필터 인터페이스를 삽입하고, 사용자의 선택에 따라 댓글을 언어별로 필터링하기 위해 사용됩니다.

    58 |

    2. Display Notifications

    59 |

    설치 또는 업데이트가 정상적으로 완료되었을 경우 이 사실을 사용자에게 알리기 위한 권한입니다.

    60 |

    3. Read your browsing history

    61 |

    이 권한이 없으면 다음 시나리오들에서 확장 프로그램이 제대로 활성화되지 않습니다.

    62 | 66 |

    원인은 YouTube가 새로운 페이지를 불러올 때 웹페이지 전체를 다시 불러오지 않고 댓글 등의 일부 컴포넌트를 재활용하기 때문입니다. 때문에 새로운 페이지로 넘어가더라도 Chrome 확장 프로그램은 67 | 새로운 페이지로 이동한 것을 알지 못하고, 댓글을 잘못 필터링하거나 인터페이스가 사라지는 등의 에러가 발생하게 됩니다. 때문에 브라우징 기록을 읽어와 새로운 페이지로 넘어갔다는 것을 Chrome 확장 68 | 프로그램에게 알려주는 것입니다. 우려하시는 바와 달리 방문 기록 등의 개인 정보는 수집하지 않습니다.

    69 |

    이 권한을 사용하지 않고서도 Chrome 확장 프로그램이 제대로 동작할 수 있는지 지속적으로 연구해볼 계획입니다.

    70 |
    71 | 72 | 73 | -------------------------------------------------------------------------------- /docs/updates/README.md: -------------------------------------------------------------------------------- 1 | # Updates 2 | 3 | ##### This list is also available on [GitHub](https://github.com/anaclumos/youtube-comment-language-filter/tree/master/docs/updates) 4 | 5 | ## v1.3.7 6 | 7 | - May 20th, 2021 8 | - Fixed: YouTube Updated Several Xpaths. 9 | - Use `commentList[i].querySelector('#content-text').innerText` 10 | 11 | ## v1.3.6 12 | 13 | - Jan 9th, 2021 14 | - Fix Inconsistency between Firefox and Chrome Stores 15 | 16 | ## v1.3.5 17 | 18 | - Jan 9th, 2021 19 | - Fixed: YouTube Updated Several Xpaths. 20 | 21 | ## v1.3.4 22 | 23 | - Oct 23, 2020 24 | - Fixed: YouTube Updated Xpath. 25 | 26 | ## v1.3.3 27 | 28 | - Oct 7, 2020 29 | - Fixed: YouTube Updated Xpath. 30 | - Added: `.prettierrc` 31 | 32 | ## v1.3.2 33 | 34 | - June 2, 2020 35 | - Added: Option to hide update notifications 36 | 37 | ## v1.3.1 38 | 39 | - June 1, 2020 40 | - Added: Copy Firefox Link Button 41 | - Fixed: Chrome Store will now show the default language instead of always showing Korean 42 | 43 | ## v1.3 44 | 45 | - May 24, 2020 46 | - Added: Displays notification on install and update 47 | - Added: Copy Link Button 48 | - Added: Update Log 49 | 50 | ## v1.2.3 51 | 52 | - May 14, 2020 53 | - Fixed: Typo 54 | 55 | ## v1.2.2 56 | 57 | - May 6, 2020 58 | - Fixed: Bug where CLF is not injected in scenario (YT Home -> Video) 59 | 60 | ## v1.2.1 61 | 62 | - May 6, 2020 63 | - Fixed: YouTube Observer Load issue 64 | - Fixed: YouTube Updated Xpath. Closes #11 65 | - Improved: Removed some duplicate codes 66 | 67 | ## v1.2 68 | 69 | - May 6, 2020 70 | - Added: Developer Mode 71 | - Updated: UI Strings to match "char detection" 72 | - Updated: UI Strings for easier understanding 73 | - Fixed: Firefox's wrong popup size 74 | - Fixed: "더보기" Bug. Closes GitHub #10 75 | 76 | ## v1.1.5.1 77 | 78 | - May 1, 2020 79 | - Firefox-specific update 80 | - Fixed: Mozilla Store Error 81 | 82 | ## v1.1.5 83 | 84 | - May 1, 2020 85 | - Fixed: YouTube comment location 86 | 87 | ## v1.1.4 88 | 89 | - Apr 4, 2020 90 | - Fixed: YouTube freezing issue when accessing from a search page. 91 | 92 | ## v1.1.3 93 | 94 | - Apr 3, 2020 95 | - Fixed: Extension update opening the welcome page. 96 | 97 | ## v1.1.2 98 | 99 | - Apr 2, 2020 100 | - Fixed: Update YouTube Comment Path 101 | 102 | ## v1.1.1 103 | 104 | - Unreleased 105 | - Internal Testing Version 106 | 107 | ## v1.1 108 | 109 | - Mar 26, 2020 110 | - Added: Official Firefox Support 111 | 112 | ## v1.0.2 113 | 114 | - Mar 23, 2020 115 | - Fixed: Bug where Chrome gets blocked on Windows 116 | 117 | ## v1.0.1 118 | 119 | - Mar 23, 2020 120 | - Fixed: Bug where settings are not saved 121 | 122 | ## v1.0.0 123 | 124 | - Mar 23, 2020 125 | - First Public Version 126 | 127 | ## v0.11.0 128 | 129 | - Mar 22, 2020 130 | - Updated: Chrome Sync Storage Settings. 131 | - In this version, the chrome sync storage settings have been reverted. This is due to newcomers having every value by `false`. 132 | 133 | ## v0.10.0 134 | 135 | - Mar 22, 2020 136 | - Added: Multi-lang support 137 | - Improved: Faster filter 138 | - Added: Pages for Learn More / Report Bug / Settings 139 | 140 | ## v0.9.0 141 | 142 | - Mar 19, 2020 143 | - Public beta testing version 144 | 145 | ## v0.1.0 146 | 147 | - Mar 11, 2020 148 | - Alpha testing version 149 | - Added: Automatic Rerun on Comment Update 150 | - Hangs if every comment is filtered out. 151 | - Language customize option still not here 152 | - YouTube sometimes loads the `comment` and `meta` lazily 153 | - This makes the extension fail to insert the filter options. 154 | 155 | ## v0.0.1 156 | 157 | - Added: Filter Engine Core Finished 158 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Created by https://www.gitignore.io/api/node,linux,macos,windows 3 | # Edit at https://www.gitignore.io/?templates=node,linux,macos,windows 4 | 5 | ### Linux ### 6 | *~ 7 | 8 | # temporary files which can be created if a process still has a handle open of a deleted file 9 | .fuse_hidden* 10 | 11 | # KDE directory preferences 12 | .directory 13 | 14 | # Linux trash folder which might appear on any partition or disk 15 | .Trash-* 16 | 17 | # .nfs files are created when an open file is removed but is still being accessed 18 | .nfs* 19 | 20 | ### macOS ### 21 | # General 22 | .DS_Store 23 | .AppleDouble 24 | .LSOverride 25 | 26 | # Icon must end with two \r 27 | Icon 28 | 29 | # Thumbnails 30 | ._* 31 | 32 | # Files that might appear in the root of a volume 33 | .DocumentRevisions-V100 34 | .fseventsd 35 | .Spotlight-V100 36 | .TemporaryItems 37 | .Trashes 38 | .VolumeIcon.icns 39 | .com.apple.timemachine.donotpresent 40 | 41 | # Directories potentially created on remote AFP share 42 | .AppleDB 43 | .AppleDesktop 44 | Network Trash Folder 45 | Temporary Items 46 | .apdisk 47 | 48 | ### Node ### 49 | # Logs 50 | logs 51 | *.log 52 | npm-debug.log* 53 | yarn-debug.log* 54 | yarn-error.log* 55 | lerna-debug.log* 56 | 57 | # Diagnostic reports (https://nodejs.org/api/report.html) 58 | report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json 59 | 60 | # Runtime data 61 | pids 62 | *.pid 63 | *.seed 64 | *.pid.lock 65 | 66 | # Directory for instrumented libs generated by jscoverage/JSCover 67 | lib-cov 68 | 69 | # Coverage directory used by tools like istanbul 70 | coverage 71 | *.lcov 72 | 73 | # nyc test coverage 74 | .nyc_output 75 | 76 | # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) 77 | .grunt 78 | 79 | # Bower dependency directory (https://bower.io/) 80 | bower_components 81 | 82 | # node-waf configuration 83 | .lock-wscript 84 | 85 | # Compiled binary addons (https://nodejs.org/api/addons.html) 86 | build/Release 87 | 88 | # Dependency directories 89 | node_modules/ 90 | jspm_packages/ 91 | 92 | # TypeScript v1 declaration files 93 | typings/ 94 | 95 | # TypeScript cache 96 | *.tsbuildinfo 97 | 98 | # Optional npm cache directory 99 | .npm 100 | 101 | # Optional eslint cache 102 | .eslintcache 103 | 104 | # Optional REPL history 105 | .node_repl_history 106 | 107 | # Output of 'npm pack' 108 | *.tgz 109 | 110 | # Yarn Integrity file 111 | .yarn-integrity 112 | 113 | # dotenv environment variables file 114 | .env 115 | .env.test 116 | 117 | # parcel-bundler cache (https://parceljs.org/) 118 | .cache 119 | 120 | # next.js build output 121 | .next 122 | 123 | # nuxt.js build output 124 | .nuxt 125 | 126 | # rollup.js default build output 127 | dist/ 128 | 129 | # Uncomment the public line if your project uses Gatsby 130 | # https://nextjs.org/blog/next-9-1#public-directory-support 131 | # https://create-react-app.dev/docs/using-the-public-folder/#docsNav 132 | # public 133 | 134 | # Storybook build outputs 135 | .out 136 | .storybook-out 137 | 138 | # vuepress build output 139 | .vuepress/dist 140 | 141 | # Serverless directories 142 | .serverless/ 143 | 144 | # FuseBox cache 145 | .fusebox/ 146 | 147 | # DynamoDB Local files 148 | .dynamodb/ 149 | 150 | # Temporary folders 151 | tmp/ 152 | temp/ 153 | 154 | ### Windows ### 155 | # Windows thumbnail cache files 156 | Thumbs.db 157 | Thumbs.db:encryptable 158 | ehthumbs.db 159 | ehthumbs_vista.db 160 | 161 | # Dump file 162 | *.stackdump 163 | 164 | # Folder config file 165 | [Dd]esktop.ini 166 | 167 | # Recycle Bin used on file shares 168 | $RECYCLE.BIN/ 169 | 170 | # Windows Installer files 171 | *.cab 172 | *.msi 173 | *.msix 174 | *.msm 175 | *.msp 176 | 177 | # Windows shortcuts 178 | *.lnk 179 | 180 | # End of https://www.gitignore.io/api/node,linux,macos,windows 181 | 182 | # ---- 183 | 184 | *.zip 185 | 186 | -------------------------------------------------------------------------------- /v1/scripts/content.js: -------------------------------------------------------------------------------- 1 | var CLFSelect = document.createElement('select') 2 | CLFSelect.id = 'CLFSelect' 3 | var CLFFooter = document.createElement('h2') 4 | CLFFooter.id = 'CLFFooter' 5 | var CLFHeader = document.createElement('h2') 6 | CLFHeader.id = 'CLFHeader' 7 | var CLFShown = false 8 | var loc = window.location.href 9 | var commentNum = 0 10 | var shownCommentNum = 0 11 | var observer = new MutationObserver((mutationList) => { 12 | removeComments() 13 | }) 14 | 15 | function containsSelectedLang(string, StartCharset, EndCharset) { 16 | var stlen = string.length 17 | var i = 0 18 | for (i = 0; i < stlen; i++) { 19 | for (var x = 0; x < StartCharset.length; x++) { 20 | if (StartCharset[x] <= string.charCodeAt(i) && string.charCodeAt(i) <= EndCharset[x]) { 21 | return true 22 | } 23 | } 24 | } 25 | return false 26 | } 27 | 28 | function onlyShow(StartCharset, EndCharset) { 29 | var commentList = document.getElementsByTagName('ytd-comment-thread-renderer') 30 | for (var i = commentNum; i < commentList.length; i++) { 31 | commentNum++ 32 | CLFFooter.textContent = shownCommentNum + ' / ' + commentNum 33 | var commentString = commentList[i].querySelector('#content-text').innerText 34 | console.log(commentString) 35 | if (!containsSelectedLang(commentString, StartCharset, EndCharset)) { 36 | commentList[i].style = 'display: none' 37 | } else { 38 | shownCommentNum++ 39 | } 40 | } 41 | } 42 | 43 | function showAllComments() { 44 | commentNum = 0 45 | shownCommentNum = 0 46 | var commentList = document.getElementsByTagName('ytd-comment-thread-renderer') 47 | for (var comment of commentList) { 48 | comment.style = '' 49 | } 50 | } 51 | 52 | function removeComments() { 53 | if (CLFSelect.value == 'All') { 54 | CLFFooter.textContent = 'All comments' 55 | } else if (CLFSelect.value == 'English') { 56 | onlyShow([65, 97], [90, 122]) 57 | } else if (CLFSelect.value == 'Korean') { 58 | onlyShow([0xac00], [0xd7a3]) 59 | } else if (CLFSelect.value == 'Japanese') { 60 | onlyShow([0x3040], [0x30ff]) 61 | } else if (CLFSelect.value == 'Chinese') { 62 | onlyShow([0x4e00], [0x9fff]) 63 | } 64 | } 65 | 66 | async function main(loc) { 67 | if (loc.substring(0, 29) == 'https://www.youtube.com/watch') { 68 | if (!CLFShown) { 69 | chrome.storage.sync.get( 70 | ['EnglishDisabled', 'KoreanDisabled', 'JapaneseDisabled', 'ChineseDisabled'], 71 | (result) => { 72 | var AllSelect = document.createElement('option') 73 | AllSelect.value = 'All' 74 | AllSelect.innerHTML = 'Any character' 75 | CLFSelect.appendChild(AllSelect) 76 | if (!result.EnglishDisabled) { 77 | var EnglishSelect = document.createElement('option') 78 | EnglishSelect.value = 'English' 79 | EnglishSelect.innerHTML = 'Alphabets' 80 | CLFSelect.appendChild(EnglishSelect) 81 | } 82 | if (!result.KoreanDisabled) { 83 | var KoreanSelect = document.createElement('option') 84 | KoreanSelect.value = 'Korean' 85 | KoreanSelect.innerHTML = 'Korean characters (한글)' 86 | CLFSelect.appendChild(KoreanSelect) 87 | } 88 | if (!result.JapaneseDisabled) { 89 | var JapaneseSelect = document.createElement('option') 90 | JapaneseSelect.value = 'Japanese' 91 | JapaneseSelect.innerHTML = 'Japanese characters (仮名)' 92 | CLFSelect.appendChild(JapaneseSelect) 93 | } 94 | if (!result.ChineseDisabled) { 95 | var ChineseSelect = document.createElement('option') 96 | ChineseSelect.value = 'Chinese' 97 | ChineseSelect.innerHTML = 'Chinese characters (漢字)' 98 | CLFSelect.appendChild(ChineseSelect) 99 | } 100 | } 101 | ) 102 | CLFHeader.classList.add('select-text') 103 | CLFHeader.classList.add('CLFHeader') 104 | CLFFooter.classList.add('CLFFooter') 105 | CLFHeader.textContent = 'Comments must include:' 106 | CLFFooter.textContent = 'All comments' 107 | ;(function insertEl() { 108 | var meta = document.evaluate( 109 | '/html/body/ytd-app/div/ytd-page-manager/ytd-watch-flexy/div[5]/div[1]/div/div[7]', 110 | document, 111 | null, 112 | XPathResult.FIRST_ORDERED_NODE_TYPE, 113 | null 114 | ).singleNodeValue 115 | var primary = document.evaluate( 116 | '/html/body/ytd-app/div/ytd-page-manager/ytd-watch-flexy/div[5]/div[1]', 117 | document, 118 | null, 119 | XPathResult.FIRST_ORDERED_NODE_TYPE, 120 | null 121 | ).singleNodeValue 122 | if ( 123 | meta != null && 124 | meta.className != undefined && 125 | primary != null && 126 | primary.className != undefined 127 | ) { 128 | meta.append(CLFHeader) 129 | meta.append(CLFSelect) 130 | primary.append(CLFFooter) 131 | CLFShown = true 132 | } else { 133 | setTimeout(insertEl, 200) 134 | } 135 | })() 136 | CLFSelect.addEventListener('change', function () { 137 | if (CLFSelect.value == 'All') { 138 | CLFFooter.textContent = 'All comments' 139 | observer.disconnect() 140 | showAllComments() 141 | } else { 142 | const config = { 143 | attributes: false, 144 | childList: true, 145 | subtree: true, 146 | } 147 | const target = document.evaluate( 148 | '/html/body/ytd-app/div/ytd-page-manager/ytd-watch-flexy/div[5]/div[1]/div/ytd-comments/ytd-item-section-renderer/div[3]', 149 | document, 150 | null, 151 | XPathResult.FIRST_ORDERED_NODE_TYPE, 152 | null 153 | ).singleNodeValue 154 | showAllComments() 155 | removeComments() 156 | observer.observe(target, config) 157 | } 158 | }) 159 | } 160 | showAllComments() 161 | removeComments() 162 | } 163 | } 164 | 165 | chrome.runtime.onMessage.addListener(function (request, sender, sendResponse) { 166 | if (request.message === 'page moved!') { 167 | loc = request.url 168 | main(loc) 169 | CLFFooter.textContent = 'All comments' 170 | document.getElementById('CLFSelect').selectedIndex = 0 171 | showAllComments() 172 | observer.disconnect() 173 | } 174 | }) 175 | 176 | main(loc) 177 | -------------------------------------------------------------------------------- /docs/styles.css: -------------------------------------------------------------------------------- 1 | @import url("https://rsms.me/inter/inter.css"); 2 | @import url("https://spoqa.github.io/spoqa-han-sans/css/SpoqaHanSans-kr.css"); 3 | 4 | .markdown-body .octicon { 5 | display: inline-block; 6 | fill: currentColor; 7 | vertical-align: text-bottom; 8 | } 9 | 10 | .markdown-body .anchor { 11 | float: left; 12 | line-height: 1; 13 | margin-left: -20px; 14 | padding-right: 4px; 15 | } 16 | 17 | .markdown-body .anchor:focus { 18 | outline: none; 19 | } 20 | 21 | .markdown-body h1 .octicon-link, 22 | .markdown-body h2 .octicon-link, 23 | .markdown-body h3 .octicon-link, 24 | .markdown-body h4 .octicon-link, 25 | .markdown-body h5 .octicon-link, 26 | .markdown-body h6 .octicon-link { 27 | color: #1b1f23; 28 | vertical-align: middle; 29 | visibility: hidden; 30 | } 31 | 32 | .markdown-body h1:hover .anchor, 33 | .markdown-body h2:hover .anchor, 34 | .markdown-body h3:hover .anchor, 35 | .markdown-body h4:hover .anchor, 36 | .markdown-body h5:hover .anchor, 37 | .markdown-body h6:hover .anchor { 38 | text-decoration: none; 39 | } 40 | 41 | .markdown-body h1:hover .anchor .octicon-link, 42 | .markdown-body h2:hover .anchor .octicon-link, 43 | .markdown-body h3:hover .anchor .octicon-link, 44 | .markdown-body h4:hover .anchor .octicon-link, 45 | .markdown-body h5:hover .anchor .octicon-link, 46 | .markdown-body h6:hover .anchor .octicon-link { 47 | visibility: visible; 48 | } 49 | 50 | .markdown-body h1:hover .anchor .octicon-link:before, 51 | .markdown-body h2:hover .anchor .octicon-link:before, 52 | .markdown-body h3:hover .anchor .octicon-link:before, 53 | .markdown-body h4:hover .anchor .octicon-link:before, 54 | .markdown-body h5:hover .anchor .octicon-link:before, 55 | .markdown-body h6:hover .anchor .octicon-link:before { 56 | width: 16px; 57 | height: 16px; 58 | content: " "; 59 | display: inline-block; 60 | background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath fill-rule='evenodd' d='M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z'%3E%3C/path%3E%3C/svg%3E"); 61 | } 62 | .markdown-body { 63 | -ms-text-size-adjust: 100%; 64 | -webkit-text-size-adjust: 100%; 65 | line-height: 1.5; 66 | color: #24292e; 67 | font-family: "system-ui", "-apple-system", "BlinkMacSystemFont", 68 | "Apple SD Gothic Neo", "Inter", "Spoqa Han Sans", "Segoe UI", 69 | Sans-Serif, "Apple Color Emoji", "Segoe UI Emoji", 70 | "Segoe UI Symbol"; 71 | font-size: 16px; 72 | line-height: 1.5; 73 | word-wrap: break-word; 74 | } 75 | 76 | .markdown-body details { 77 | display: block; 78 | } 79 | 80 | .markdown-body summary { 81 | display: list-item; 82 | } 83 | 84 | .markdown-body a { 85 | background-color: initial; 86 | } 87 | 88 | .markdown-body a:active, 89 | .markdown-body a:hover { 90 | outline-width: 0; 91 | } 92 | 93 | .markdown-body strong { 94 | font-weight: inherit; 95 | font-weight: bolder; 96 | } 97 | 98 | .markdown-body h1 { 99 | font-size: 2em; 100 | margin: 0.67em 0; 101 | } 102 | 103 | .markdown-body img { 104 | border-style: none; 105 | } 106 | 107 | .markdown-body code, 108 | .markdown-body kbd, 109 | .markdown-body pre { 110 | font-family: monospace, monospace; 111 | font-size: 1em; 112 | } 113 | 114 | .markdown-body hr { 115 | box-sizing: initial; 116 | height: 0; 117 | overflow: visible; 118 | } 119 | 120 | .markdown-body input { 121 | font: inherit; 122 | margin: 0; 123 | } 124 | 125 | .markdown-body input { 126 | overflow: visible; 127 | } 128 | 129 | .markdown-body [type="checkbox"] { 130 | box-sizing: border-box; 131 | padding: 0; 132 | } 133 | 134 | .markdown-body * { 135 | box-sizing: border-box; 136 | } 137 | 138 | .markdown-body input { 139 | font-family: inherit; 140 | font-size: inherit; 141 | line-height: inherit; 142 | } 143 | 144 | .markdown-body a { 145 | color: #0366d6; 146 | text-decoration: none; 147 | } 148 | 149 | .markdown-body a:hover { 150 | text-decoration: underline; 151 | } 152 | 153 | .markdown-body strong { 154 | font-weight: 600; 155 | } 156 | 157 | .markdown-body hr { 158 | height: 0; 159 | margin: 15px 0; 160 | overflow: hidden; 161 | background: transparent; 162 | border: 0; 163 | border-bottom: 1px solid #dfe2e5; 164 | } 165 | 166 | .markdown-body hr:after, 167 | .markdown-body hr:before { 168 | display: table; 169 | content: ""; 170 | } 171 | 172 | .markdown-body hr:after { 173 | clear: both; 174 | } 175 | 176 | .markdown-body table { 177 | border-spacing: 0; 178 | border-collapse: collapse; 179 | } 180 | 181 | .markdown-body td, 182 | .markdown-body th { 183 | padding: 0; 184 | } 185 | 186 | .markdown-body details summary { 187 | cursor: pointer; 188 | } 189 | 190 | .markdown-body kbd { 191 | display: inline-block; 192 | padding: 3px 5px; 193 | font: 11px SF Mono, Consolas, Liberation Mono, Menlo, monospace; 194 | line-height: 10px; 195 | color: #444d56; 196 | vertical-align: middle; 197 | background-color: #fafbfc; 198 | border: 1px solid #d1d5da; 199 | border-radius: 3px; 200 | box-shadow: inset 0 -1px 0 #d1d5da; 201 | } 202 | 203 | .markdown-body h1, 204 | .markdown-body h2, 205 | .markdown-body h3, 206 | .markdown-body h4, 207 | .markdown-body h5, 208 | .markdown-body h6 { 209 | margin-top: 0; 210 | margin-bottom: 0; 211 | } 212 | 213 | .markdown-body h1 { 214 | font-size: 32px; 215 | } 216 | 217 | .markdown-body h1, 218 | .markdown-body h2 { 219 | font-weight: 600; 220 | } 221 | 222 | .markdown-body h2 { 223 | font-size: 24px; 224 | } 225 | 226 | .markdown-body h3 { 227 | font-size: 20px; 228 | } 229 | 230 | .markdown-body h3, 231 | .markdown-body h4 { 232 | font-weight: 600; 233 | } 234 | 235 | .markdown-body h4 { 236 | font-size: 16px; 237 | } 238 | 239 | .markdown-body h5 { 240 | font-size: 14px; 241 | } 242 | 243 | .markdown-body h5, 244 | .markdown-body h6 { 245 | font-weight: 600; 246 | } 247 | 248 | .markdown-body h6 { 249 | font-size: 12px; 250 | } 251 | 252 | .markdown-body p { 253 | margin-top: 0; 254 | margin-bottom: 10px; 255 | } 256 | 257 | .markdown-body blockquote { 258 | margin: 0; 259 | } 260 | 261 | .markdown-body ol, 262 | .markdown-body ul { 263 | padding-left: 0; 264 | margin-top: 0; 265 | margin-bottom: 0; 266 | } 267 | 268 | .markdown-body ol ol, 269 | .markdown-body ul ol { 270 | list-style-type: lower-roman; 271 | } 272 | 273 | .markdown-body ol ol ol, 274 | .markdown-body ol ul ol, 275 | .markdown-body ul ol ol, 276 | .markdown-body ul ul ol { 277 | list-style-type: lower-alpha; 278 | } 279 | 280 | .markdown-body dd { 281 | margin-left: 0; 282 | } 283 | 284 | .markdown-body code, 285 | .markdown-body pre { 286 | font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, 287 | monospace; 288 | font-size: 12px; 289 | } 290 | 291 | .markdown-body pre { 292 | margin-top: 0; 293 | margin-bottom: 0; 294 | } 295 | 296 | .markdown-body input::-webkit-inner-spin-button, 297 | .markdown-body input::-webkit-outer-spin-button { 298 | margin: 0; 299 | -webkit-appearance: none; 300 | appearance: none; 301 | } 302 | 303 | .markdown-body :checked + .radio-label { 304 | position: relative; 305 | z-index: 1; 306 | border-color: #0366d6; 307 | } 308 | 309 | .markdown-body .border { 310 | border: 1px solid #e1e4e8 !important; 311 | } 312 | 313 | .markdown-body .border-0 { 314 | border: 0 !important; 315 | } 316 | 317 | .markdown-body .border-bottom { 318 | border-bottom: 1px solid #e1e4e8 !important; 319 | } 320 | 321 | .markdown-body .rounded-1 { 322 | border-radius: 3px !important; 323 | } 324 | 325 | .markdown-body .bg-white { 326 | background-color: #fff !important; 327 | } 328 | 329 | .markdown-body .bg-gray-light { 330 | background-color: #fafbfc !important; 331 | } 332 | 333 | .markdown-body .text-gray-light { 334 | color: #6a737d !important; 335 | } 336 | 337 | .markdown-body .mb-0 { 338 | margin-bottom: 0 !important; 339 | } 340 | 341 | .markdown-body .my-2 { 342 | margin-top: 8px !important; 343 | margin-bottom: 8px !important; 344 | } 345 | 346 | .markdown-body .pl-0 { 347 | padding-left: 0 !important; 348 | } 349 | 350 | .markdown-body .py-0 { 351 | padding-top: 0 !important; 352 | padding-bottom: 0 !important; 353 | } 354 | 355 | .markdown-body .pl-1 { 356 | padding-left: 4px !important; 357 | } 358 | 359 | .markdown-body .pl-2 { 360 | padding-left: 8px !important; 361 | } 362 | 363 | .markdown-body .py-2 { 364 | padding-top: 8px !important; 365 | padding-bottom: 8px !important; 366 | } 367 | 368 | .markdown-body .pl-3, 369 | .markdown-body .px-3 { 370 | padding-left: 16px !important; 371 | } 372 | 373 | .markdown-body .px-3 { 374 | padding-right: 16px !important; 375 | } 376 | 377 | .markdown-body .pl-4 { 378 | padding-left: 24px !important; 379 | } 380 | 381 | .markdown-body .pl-5 { 382 | padding-left: 32px !important; 383 | } 384 | 385 | .markdown-body .pl-6 { 386 | padding-left: 40px !important; 387 | } 388 | 389 | .markdown-body .f6 { 390 | font-size: 12px !important; 391 | } 392 | 393 | .markdown-body .lh-condensed { 394 | line-height: 1.25 !important; 395 | } 396 | 397 | .markdown-body .text-bold { 398 | font-weight: 600 !important; 399 | } 400 | 401 | .markdown-body .pl-c { 402 | color: #6a737d; 403 | } 404 | 405 | .markdown-body .pl-c1, 406 | .markdown-body .pl-s .pl-v { 407 | color: #005cc5; 408 | } 409 | 410 | .markdown-body .pl-e, 411 | .markdown-body .pl-en { 412 | color: #6f42c1; 413 | } 414 | 415 | .markdown-body .pl-s .pl-s1, 416 | .markdown-body .pl-smi { 417 | color: #24292e; 418 | } 419 | 420 | .markdown-body .pl-ent { 421 | color: #22863a; 422 | } 423 | 424 | .markdown-body .pl-k { 425 | color: #d73a49; 426 | } 427 | 428 | .markdown-body .pl-pds, 429 | .markdown-body .pl-s, 430 | .markdown-body .pl-s .pl-pse .pl-s1, 431 | .markdown-body .pl-sr, 432 | .markdown-body .pl-sr .pl-cce, 433 | .markdown-body .pl-sr .pl-sra, 434 | .markdown-body .pl-sr .pl-sre { 435 | color: #032f62; 436 | } 437 | 438 | .markdown-body .pl-smw, 439 | .markdown-body .pl-v { 440 | color: #e36209; 441 | } 442 | 443 | .markdown-body .pl-bu { 444 | color: #b31d28; 445 | } 446 | 447 | .markdown-body .pl-ii { 448 | color: #fafbfc; 449 | background-color: #b31d28; 450 | } 451 | 452 | .markdown-body .pl-c2 { 453 | color: #fafbfc; 454 | background-color: #d73a49; 455 | } 456 | 457 | .markdown-body .pl-c2:before { 458 | content: "^M"; 459 | } 460 | 461 | .markdown-body .pl-sr .pl-cce { 462 | font-weight: 700; 463 | color: #22863a; 464 | } 465 | 466 | .markdown-body .pl-ml { 467 | color: #735c0f; 468 | } 469 | 470 | .markdown-body .pl-mh, 471 | .markdown-body .pl-mh .pl-en, 472 | .markdown-body .pl-ms { 473 | font-weight: 700; 474 | color: #005cc5; 475 | } 476 | 477 | .markdown-body .pl-mi { 478 | font-style: italic; 479 | color: #24292e; 480 | } 481 | 482 | .markdown-body .pl-mb { 483 | font-weight: 700; 484 | color: #24292e; 485 | } 486 | 487 | .markdown-body .pl-md { 488 | color: #b31d28; 489 | background-color: #ffeef0; 490 | } 491 | 492 | .markdown-body .pl-mi1 { 493 | color: #22863a; 494 | background-color: #f0fff4; 495 | } 496 | 497 | .markdown-body .pl-mc { 498 | color: #e36209; 499 | background-color: #ffebda; 500 | } 501 | 502 | .markdown-body .pl-mi2 { 503 | color: #f6f8fa; 504 | background-color: #005cc5; 505 | } 506 | 507 | .markdown-body .pl-mdr { 508 | font-weight: 700; 509 | color: #6f42c1; 510 | } 511 | 512 | .markdown-body .pl-ba { 513 | color: #586069; 514 | } 515 | 516 | .markdown-body .pl-sg { 517 | color: #959da5; 518 | } 519 | 520 | .markdown-body .pl-corl { 521 | text-decoration: underline; 522 | color: #032f62; 523 | } 524 | 525 | .markdown-body .mb-0 { 526 | margin-bottom: 0 !important; 527 | } 528 | 529 | .markdown-body .my-2 { 530 | margin-bottom: 8px !important; 531 | } 532 | 533 | .markdown-body .my-2 { 534 | margin-top: 8px !important; 535 | } 536 | 537 | .markdown-body .pl-0 { 538 | padding-left: 0 !important; 539 | } 540 | 541 | .markdown-body .py-0 { 542 | padding-top: 0 !important; 543 | padding-bottom: 0 !important; 544 | } 545 | 546 | .markdown-body .pl-1 { 547 | padding-left: 4px !important; 548 | } 549 | 550 | .markdown-body .pl-2 { 551 | padding-left: 8px !important; 552 | } 553 | 554 | .markdown-body .py-2 { 555 | padding-top: 8px !important; 556 | padding-bottom: 8px !important; 557 | } 558 | 559 | .markdown-body .pl-3 { 560 | padding-left: 16px !important; 561 | } 562 | 563 | .markdown-body .pl-4 { 564 | padding-left: 24px !important; 565 | } 566 | 567 | .markdown-body .pl-5 { 568 | padding-left: 32px !important; 569 | } 570 | 571 | .markdown-body .pl-6 { 572 | padding-left: 40px !important; 573 | } 574 | 575 | .markdown-body .pl-7 { 576 | padding-left: 48px !important; 577 | } 578 | 579 | .markdown-body .pl-8 { 580 | padding-left: 64px !important; 581 | } 582 | 583 | .markdown-body .pl-9 { 584 | padding-left: 80px !important; 585 | } 586 | 587 | .markdown-body .pl-10 { 588 | padding-left: 96px !important; 589 | } 590 | 591 | .markdown-body .pl-11 { 592 | padding-left: 112px !important; 593 | } 594 | 595 | .markdown-body .pl-12 { 596 | padding-left: 128px !important; 597 | } 598 | 599 | .markdown-body hr { 600 | border-bottom-color: #eee; 601 | } 602 | 603 | .markdown-body kbd { 604 | display: inline-block; 605 | padding: 3px 5px; 606 | font: 11px SFMono-Regular, Consolas, Liberation Mono, Menlo, 607 | monospace; 608 | line-height: 10px; 609 | color: #444d56; 610 | vertical-align: middle; 611 | background-color: #fafbfc; 612 | border: 1px solid #d1d5da; 613 | border-radius: 3px; 614 | box-shadow: inset 0 -1px 0 #d1d5da; 615 | } 616 | 617 | .markdown-body:after, 618 | .markdown-body:before { 619 | display: table; 620 | content: ""; 621 | } 622 | 623 | .markdown-body:after { 624 | clear: both; 625 | } 626 | 627 | .markdown-body > :first-child { 628 | margin-top: 0 !important; 629 | } 630 | 631 | .markdown-body > :last-child { 632 | margin-bottom: 0 !important; 633 | } 634 | 635 | .markdown-body a:not([href]) { 636 | color: inherit; 637 | text-decoration: none; 638 | } 639 | 640 | .markdown-body blockquote, 641 | .markdown-body details, 642 | .markdown-body dl, 643 | .markdown-body ol, 644 | .markdown-body p, 645 | .markdown-body pre, 646 | .markdown-body table, 647 | .markdown-body ul { 648 | margin-top: 0; 649 | margin-bottom: 16px; 650 | } 651 | 652 | .markdown-body hr { 653 | height: 0.25em; 654 | padding: 0; 655 | margin: 24px 0; 656 | background-color: #e1e4e8; 657 | border: 0; 658 | } 659 | 660 | .markdown-body blockquote { 661 | padding: 0 1em; 662 | color: #6a737d; 663 | border-left: 0.25em solid #dfe2e5; 664 | } 665 | 666 | .markdown-body blockquote > :first-child { 667 | margin-top: 0; 668 | } 669 | 670 | .markdown-body blockquote > :last-child { 671 | margin-bottom: 0; 672 | } 673 | 674 | .markdown-body h1, 675 | .markdown-body h2, 676 | .markdown-body h3, 677 | .markdown-body h4, 678 | .markdown-body h5, 679 | .markdown-body h6 { 680 | margin-top: 24px; 681 | margin-bottom: 16px; 682 | font-weight: 600; 683 | line-height: 1.25; 684 | } 685 | 686 | .markdown-body h1 { 687 | font-size: 2em; 688 | } 689 | 690 | .markdown-body h1, 691 | .markdown-body h2 { 692 | padding-bottom: 0.3em; 693 | border-bottom: 1px solid #eaecef; 694 | } 695 | 696 | .markdown-body h2 { 697 | font-size: 1.5em; 698 | } 699 | 700 | .markdown-body h3 { 701 | font-size: 1.25em; 702 | } 703 | 704 | .markdown-body h4 { 705 | font-size: 1em; 706 | } 707 | 708 | .markdown-body h5 { 709 | font-size: 0.875em; 710 | } 711 | 712 | .markdown-body h6 { 713 | font-size: 0.85em; 714 | color: #6a737d; 715 | } 716 | 717 | .markdown-body ol, 718 | .markdown-body ul { 719 | padding-left: 2em; 720 | } 721 | 722 | .markdown-body ol ol, 723 | .markdown-body ol ul, 724 | .markdown-body ul ol, 725 | .markdown-body ul ul { 726 | margin-top: 0; 727 | margin-bottom: 0; 728 | } 729 | 730 | .markdown-body li { 731 | word-wrap: break-all; 732 | } 733 | 734 | .markdown-body li > p { 735 | margin-top: 16px; 736 | } 737 | 738 | .markdown-body li + li { 739 | margin-top: 0.25em; 740 | } 741 | 742 | .markdown-body dl { 743 | padding: 0; 744 | } 745 | 746 | .markdown-body dl dt { 747 | padding: 0; 748 | margin-top: 16px; 749 | font-size: 1em; 750 | font-style: italic; 751 | font-weight: 600; 752 | } 753 | 754 | .markdown-body dl dd { 755 | padding: 0 16px; 756 | margin-bottom: 16px; 757 | } 758 | 759 | .markdown-body table { 760 | display: block; 761 | width: 100%; 762 | overflow: auto; 763 | } 764 | 765 | .markdown-body table th { 766 | font-weight: 600; 767 | } 768 | 769 | .markdown-body table td, 770 | .markdown-body table th { 771 | padding: 6px 13px; 772 | border: 1px solid #dfe2e5; 773 | } 774 | 775 | .markdown-body table tr { 776 | background-color: #fff; 777 | border-top: 1px solid #c6cbd1; 778 | } 779 | 780 | .markdown-body table tr:nth-child(2n) { 781 | background-color: #f6f8fa; 782 | } 783 | 784 | .markdown-body img { 785 | max-width: 100%; 786 | box-sizing: initial; 787 | background-color: #fff; 788 | } 789 | 790 | .markdown-body img[align="right"] { 791 | padding-left: 20px; 792 | } 793 | 794 | .markdown-body img[align="left"] { 795 | padding-right: 20px; 796 | } 797 | 798 | .markdown-body code { 799 | padding: 0.2em 0.4em; 800 | margin: 0; 801 | font-size: 85%; 802 | background-color: rgba(27, 31, 35, 0.05); 803 | border-radius: 3px; 804 | } 805 | 806 | .markdown-body pre { 807 | word-wrap: normal; 808 | } 809 | 810 | .markdown-body pre > code { 811 | padding: 0; 812 | margin: 0; 813 | font-size: 100%; 814 | word-break: normal; 815 | white-space: pre; 816 | background: transparent; 817 | border: 0; 818 | } 819 | 820 | .markdown-body .highlight { 821 | margin-bottom: 16px; 822 | } 823 | 824 | .markdown-body .highlight pre { 825 | margin-bottom: 0; 826 | word-break: normal; 827 | } 828 | 829 | .markdown-body .highlight pre, 830 | .markdown-body pre { 831 | padding: 16px; 832 | overflow: auto; 833 | font-size: 85%; 834 | line-height: 1.45; 835 | background-color: #f6f8fa; 836 | border-radius: 3px; 837 | } 838 | 839 | .markdown-body pre code { 840 | display: inline; 841 | max-width: auto; 842 | padding: 0; 843 | margin: 0; 844 | overflow: visible; 845 | line-height: inherit; 846 | word-wrap: normal; 847 | background-color: initial; 848 | border: 0; 849 | } 850 | 851 | .markdown-body .commit-tease-sha { 852 | display: inline-block; 853 | font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, 854 | monospace; 855 | font-size: 90%; 856 | color: #444d56; 857 | } 858 | 859 | .markdown-body .full-commit .btn-outline:not(:disabled):hover { 860 | color: #005cc5; 861 | border-color: #005cc5; 862 | } 863 | 864 | .markdown-body .blob-wrapper { 865 | overflow-x: auto; 866 | overflow-y: hidden; 867 | } 868 | 869 | .markdown-body .blob-wrapper-embedded { 870 | max-height: 240px; 871 | overflow-y: auto; 872 | } 873 | 874 | .markdown-body .blob-num { 875 | width: 1%; 876 | min-width: 50px; 877 | padding-right: 10px; 878 | padding-left: 10px; 879 | font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, 880 | monospace; 881 | font-size: 12px; 882 | line-height: 20px; 883 | color: rgba(27, 31, 35, 0.3); 884 | text-align: right; 885 | white-space: nowrap; 886 | vertical-align: top; 887 | cursor: pointer; 888 | -webkit-user-select: none; 889 | -moz-user-select: none; 890 | -ms-user-select: none; 891 | user-select: none; 892 | } 893 | 894 | .markdown-body .blob-num:hover { 895 | color: rgba(27, 31, 35, 0.6); 896 | } 897 | 898 | .markdown-body .blob-num:before { 899 | content: attr(data-line-number); 900 | } 901 | 902 | .markdown-body .blob-code { 903 | position: relative; 904 | padding-right: 10px; 905 | padding-left: 10px; 906 | line-height: 20px; 907 | vertical-align: top; 908 | } 909 | 910 | .markdown-body .blob-code-inner { 911 | overflow: visible; 912 | font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, 913 | monospace; 914 | font-size: 12px; 915 | color: #24292e; 916 | word-wrap: normal; 917 | white-space: pre; 918 | } 919 | 920 | .markdown-body .pl-token.active, 921 | .markdown-body .pl-token:hover { 922 | cursor: pointer; 923 | background: #ffea7f; 924 | } 925 | 926 | .markdown-body .tab-size[data-tab-size="1"] { 927 | -moz-tab-size: 1; 928 | tab-size: 1; 929 | } 930 | 931 | .markdown-body .tab-size[data-tab-size="2"] { 932 | -moz-tab-size: 2; 933 | tab-size: 2; 934 | } 935 | 936 | .markdown-body .tab-size[data-tab-size="3"] { 937 | -moz-tab-size: 3; 938 | tab-size: 3; 939 | } 940 | 941 | .markdown-body .tab-size[data-tab-size="4"] { 942 | -moz-tab-size: 4; 943 | tab-size: 4; 944 | } 945 | 946 | .markdown-body .tab-size[data-tab-size="5"] { 947 | -moz-tab-size: 5; 948 | tab-size: 5; 949 | } 950 | 951 | .markdown-body .tab-size[data-tab-size="6"] { 952 | -moz-tab-size: 6; 953 | tab-size: 6; 954 | } 955 | 956 | .markdown-body .tab-size[data-tab-size="7"] { 957 | -moz-tab-size: 7; 958 | tab-size: 7; 959 | } 960 | 961 | .markdown-body .tab-size[data-tab-size="8"] { 962 | -moz-tab-size: 8; 963 | tab-size: 8; 964 | } 965 | 966 | .markdown-body .tab-size[data-tab-size="9"] { 967 | -moz-tab-size: 9; 968 | tab-size: 9; 969 | } 970 | 971 | .markdown-body .tab-size[data-tab-size="10"] { 972 | -moz-tab-size: 10; 973 | tab-size: 10; 974 | } 975 | 976 | .markdown-body .tab-size[data-tab-size="11"] { 977 | -moz-tab-size: 11; 978 | tab-size: 11; 979 | } 980 | 981 | .markdown-body .tab-size[data-tab-size="12"] { 982 | -moz-tab-size: 12; 983 | tab-size: 12; 984 | } 985 | 986 | .markdown-body .task-list-item { 987 | list-style-type: none; 988 | } 989 | 990 | .markdown-body .task-list-item + .task-list-item { 991 | margin-top: 3px; 992 | } 993 | 994 | .markdown-body .task-list-item input { 995 | margin: 0 0.2em 0.25em -1.6em; 996 | vertical-align: middle; 997 | } 998 | --------------------------------------------------------------------------------