Page Centering

ウェブページを中央配置

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(У мене вже є менеджер скриптів, дайте мені встановити його!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Автор
kengo321
Щоденних встановлень
0
Всього встановлень
100
Рейтинги
2 0 0
Версія
4
Створено
30.12.2015
Оновлено
12.11.2017
Size
13,3 кБ
Ліцензія
MIT
Відноситься до
Всі сайти

ユーザースクリプトコマンドに「Page Centering 設定」を追加します。

一致する URL が複数あるときは、一番長い URL の設定を使用します。

html 要素の style 属性に max-width: [設定した最大幅]; position: relative; margin: 0px auto; を設定して中央配置します。

正しく中央配置されるかどうかはウェブページによります。

動作確認環境

  • Firefox + Greasemonkey
  • Google Chrome + Tampermonkey

更新履歴

  • 2017-11-12 v4

    • Greasemonkey4.0 に対応
    • このページのスクリプト名の最後に設定ボタンを追加
  • 2016-01-03 v3

    • セットボタンをクリックしたときに、最大幅の入力欄をフォーカスするように変更した
  • 2016-01-02 v2

    • 無効な値を最大幅に設定できないようにした