diff --git a/.github/workflows/apply.yml b/.github/workflows/apply.yml index 15de3fe..2fa2212 100644 --- a/.github/workflows/apply.yml +++ b/.github/workflows/apply.yml @@ -15,6 +15,8 @@ jobs: with: fetch-depth: 30 + - uses: actions/setup-node@v4 + - uses: actions/setup-python@v5 with: python-version: '3.x' diff --git a/.github/workflows/gadget-lint.yaml b/.github/workflows/gadget-lint.yaml index e075452..ea4c5db 100644 --- a/.github/workflows/gadget-lint.yaml +++ b/.github/workflows/gadget-lint.yaml @@ -17,6 +17,8 @@ jobs: steps: - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + - name: Get yarn cache id: yarn-cache run: echo "::set-output name=dir::$(yarn cache dir)" diff --git a/.github/workflows/update_mirrors.yml b/.github/workflows/update-mirrors.yml similarity index 100% rename from .github/workflows/update_mirrors.yml rename to .github/workflows/update-mirrors.yml diff --git a/.prettierrc.yml b/.prettierrc.yml index 467e467..00a628c 100644 --- a/.prettierrc.yml +++ b/.prettierrc.yml @@ -1,4 +1,5 @@ singleQuote: true +trailingComma: es5 overrides: - files: "gadgets/**/{G,g}adget_definition:*" options: diff --git a/gadgets/bookflap/mediawiki%3Agadget-bookflap.js b/gadgets/bookflap/mediawiki%3Agadget-bookflap.js index af82561..27ad7a2 100644 --- a/gadgets/bookflap/mediawiki%3Agadget-bookflap.js +++ b/gadgets/bookflap/mediawiki%3Agadget-bookflap.js @@ -32,13 +32,13 @@ $raws.each(function () { var $title = $(this).find( - '.book-flap-title a, .book-flap-title .mw-selflink', + '.book-flap-title a, .book-flap-title .mw-selflink' ); var $slideBookFlap = $('
') .addClass('book-flap-slide') .html($(this).find('book-flap-raw book-flap-title')) .append( - $(this).find('.book-flap-body').clone().addClass('mw-parser-output'), + $(this).find('.book-flap-body').clone().addClass('mw-parser-output') ) .appendTo($overlay); @@ -85,7 +85,7 @@ .addClass('book-flap-side') .html($(this).find('book-flap-raw book-flap-title')) .append( - $(this).find('.book-flap-body').clone().addClass('mw-parser-output'), + $(this).find('.book-flap-body').clone().addClass('mw-parser-output') ) .appendTo($(this).hasClass('book-flap-left') ? $leftside : $rightside) .hide() diff --git a/gadgets/create-redirect/mediawiki%3Agadget-create-redirect.js b/gadgets/create-redirect/mediawiki%3Agadget-create-redirect.js index 289e589..94a3274 100644 --- a/gadgets/create-redirect/mediawiki%3Agadget-create-redirect.js +++ b/gadgets/create-redirect/mediawiki%3Agadget-create-redirect.js @@ -11,8 +11,8 @@ '#', '여기로 넘겨주기', 'p-createRedirect', - '이 문서로 오는 넘겨주기 문서를 만듭니다.', - ), + '이 문서로 오는 넘겨주기 문서를 만듭니다.' + ) ).on('click', function (e) { e.preventDefault(); target = mw.config.get('wgPageName').replace(/_/g, ' '); @@ -62,7 +62,7 @@ title + '" 문서에서 "' + target + - '" 문서로 넘겨주기를 만드시겠습니까?', + '" 문서로 넘겨주기를 만드시겠습니까?' ) .done(function (confirmed) { if (confirmed) { @@ -75,7 +75,7 @@ '" 문서에서 ' + '"' + target + - '" 문서로 넘겨주기 문서가 생성되었습니다.', + '" 문서로 넘겨주기 문서가 생성되었습니다.' ); }) .fail(function (e) { diff --git a/gadgets/hide-insulting-names/mediawiki%3Agadget-hide-insulting-names.js b/gadgets/hide-insulting-names/mediawiki%3Agadget-hide-insulting-names.js index 211e985..a8bb631 100644 --- a/gadgets/hide-insulting-names/mediawiki%3Agadget-hide-insulting-names.js +++ b/gadgets/hide-insulting-names/mediawiki%3Agadget-hide-insulting-names.js @@ -17,7 +17,7 @@ if (isLinkToSanction) { $(this).html( - '사용자:' + substitute + ' 님에 대한 부적절한 사용자명 변경 건의', + '사용자:' + substitute + ' 님에 대한 부적절한 사용자명 변경 건의' ); } }); diff --git a/gadgets/imageview/mediawiki%3Agadget-imageview.js b/gadgets/imageview/mediawiki%3Agadget-imageview.js index 14bf3f5..b292daf 100644 --- a/gadgets/imageview/mediawiki%3Agadget-imageview.js +++ b/gadgets/imageview/mediawiki%3Agadget-imageview.js @@ -17,9 +17,9 @@ $('') .attr( 'src', - 'https://upload.wikimedia.org/wikipedia/commons/d/de/Ajax-loader.gif', + 'https://upload.wikimedia.org/wikipedia/commons/d/de/Ajax-loader.gif' ) - .addClass('loading-spinner'), + .addClass('loading-spinner') ); $('body').css('overflow', 'hidden'); @@ -29,7 +29,7 @@ titles: decodeURI( $(this) .attr('href') - .match(/\/([^/]+)$/)[1], + .match(/\/([^/]+)$/)[1] ), prop: 'imageinfo', iiprop: 'url', @@ -42,7 +42,7 @@ }); overlay.append( - $('').attr('src', imageSource).addClass('image'), + $('').attr('src', imageSource).addClass('image') ); }); }); diff --git a/gadgets/mute/mediawiki%3Agadget-mute.js b/gadgets/mute/mediawiki%3Agadget-mute.js index 871944b..292e9db 100644 --- a/gadgets/mute/mediawiki%3Agadget-mute.js +++ b/gadgets/mute/mediawiki%3Agadget-mute.js @@ -13,7 +13,7 @@ ' 여러 브라우저로 페미위키를 이용하시는 분들은 각 브라우저별로' + ' 키워드를 등록해주시기 바랍니다.' + '' + - '', + '' ); function _initUI() { @@ -25,8 +25,8 @@ '#', '뮤트', 'p-mute', - '금지어를 설정합니다.', - ), + '금지어를 설정합니다.' + ) ).on('click', function (e) { e.preventDefault(); $editorEl.show(); @@ -58,7 +58,7 @@ $('#mw-content-text').prepend( '