curlkun commited on
Commit
69dce3c
·
verified ·
1 Parent(s): e2a02a3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -17
app.py CHANGED
@@ -973,23 +973,6 @@ with gr.Blocks(title="ファイル比較") as demo:
973
  # ---------- タブ1: ファイル比較 ----------
974
  with gr.TabItem("ファイル比較"):
975
  gr.Markdown("### 設定 & ファイル入力")
976
- file_color_select = gr.Dropdown(
977
- choices=list(COLOR_PRESETS.keys()),
978
- value="赤 / 青 (標準)",
979
- label="ハイライト配色",
980
- interactive=True,
981
- )
982
- file_mode_select = gr.Radio(
983
- choices=["そのまま (Strict)", "正規化 (Normalize)", "無視 (Ignore)"],
984
- value="無視 (Ignore)",
985
- label="空白文字の扱い (PDF同士のみ有効)",
986
- info="PDF以外のファイルは常に「無視」で処理されます。",
987
- )
988
- file_page_range = gr.Textbox(
989
- label="ページ / スライド指定(PDF・pptx のみ有効)",
990
- placeholder="例: 1,3-5,7 空欄または all で全ページ",
991
- value="",
992
- )
993
  file_input1 = gr.File(
994
  label="元ファイル",
995
  file_types=[".pdf", ".txt", ".html", ".htm", ".rtf", ".docx", ".xlsx", ".pptx"],
@@ -1010,6 +993,23 @@ with gr.Blocks(title="ファイル比較") as demo:
1010
  label="修正ファイル シート選択(xlsx のみ)",
1011
  visible=False,
1012
  )
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1013
  with gr.Row():
1014
  file_clear_btn = gr.Button("クリア", variant="secondary")
1015
  file_run_btn = gr.Button("比較を実行", variant="primary")
 
973
  # ---------- タブ1: ファイル比較 ----------
974
  with gr.TabItem("ファイル比較"):
975
  gr.Markdown("### 設定 & ファイル入力")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
976
  file_input1 = gr.File(
977
  label="元ファイル",
978
  file_types=[".pdf", ".txt", ".html", ".htm", ".rtf", ".docx", ".xlsx", ".pptx"],
 
993
  label="修正ファイル シート選択(xlsx のみ)",
994
  visible=False,
995
  )
996
+ file_page_range = gr.Textbox(
997
+ label="ページ / スライド指定(PDF・pptx のみ有効)",
998
+ placeholder="例: 1,3-5,7 空欄または all で全ページ",
999
+ value="",
1000
+ )
1001
+ file_color_select = gr.Dropdown(
1002
+ choices=list(COLOR_PRESETS.keys()),
1003
+ value="赤 / 青 (標準)",
1004
+ label="ハイライト配色",
1005
+ interactive=True,
1006
+ )
1007
+ file_mode_select = gr.Radio(
1008
+ choices=["そのまま (Strict)", "正規化 (Normalize)", "無視 (Ignore)"],
1009
+ value="無視 (Ignore)",
1010
+ label="空白文字の扱い (PDF同士のみ有効)",
1011
+ info="PDF以外のファイルは常に「無視」で処理されます。",
1012
+ )
1013
  with gr.Row():
1014
  file_clear_btn = gr.Button("クリア", variant="secondary")
1015
  file_run_btn = gr.Button("比較を実行", variant="primary")