# SOME DESCRIPTIVE TITLE.
# Copyright (C) WangWeimin
# This file is distributed under the same license as the PyWebIO package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2021.
#
msgid ""
msgstr ""
"Project-Id-Version: PyWebIO 1.1.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-10-05 00:44+0800\n"
"PO-Revision-Date: 2021-04-14 21:17+0800\n"
"Last-Translator: WangWeimin <wang0.618@qq.com>\n"
"Language: zh_CN\n"
"Language-Team: \n"
"Plural-Forms: nplurals=1; plural=0\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.8.0\n"

#: ../../misc.rst:2
msgid "Miscellaneous"
msgstr "其他"

#: ../../misc.rst:7
msgid "Commonly used Codemirror options"
msgstr "常用的Codemirror选项"

#: ../../misc.rst:9
msgid ""
"``mode`` (str): The language of code. For complete list, see "
"https://codemirror.net/mode/index.html"
msgstr "``mode`` (str): 代码语言。支持的语言有：https://codemirror.net/mode/index.html"

#: ../../misc.rst:10
msgid ""
"``theme`` (str): The theme to style the editor with. For all available "
"theme, see https://codemirror.net/demo/theme.html"
msgstr "``theme`` (str): 编辑器主题。可使用的主题：https://codemirror.net/demo/theme.html"

#: ../../misc.rst:11
msgid ""
"``lineNumbers`` (bool): Whether to show line numbers to the left of the "
"editor."
msgstr "``lineNumbers`` (bool): 是否显示行号"

#: ../../misc.rst:12
msgid ""
"``indentUnit`` (int): How many spaces a block (whatever that means in the "
"edited language) should be indented. The default is 2."
msgstr "``indentUnit`` (int): 缩进使用的空格数"

#: ../../misc.rst:13
msgid "``tabSize`` (int): The width of a tab character. Defaults to 4."
msgstr "``tabSize`` (int): 制表符宽度"

#: ../../misc.rst:14
msgid ""
"``lineWrapping`` (bool): Whether CodeMirror should scroll or wrap for long "
"lines. Defaults to false (scroll)."
msgstr "``lineWrapping`` (bool): 是否换行以显示长行"

#: ../../misc.rst:16
msgid ""
"For complete Codemirror options, please visit: "
"https://codemirror.net/doc/manual.html#config"
msgstr "完整的Codemirror选项请见 https://codemirror.net/doc/manual.html#config"

#: ../../misc.rst:21
msgid "Nginx WebSocket Config Example"
msgstr "Nginx WebSocket配置示例"

#: ../../misc.rst:23
msgid ""
"Assuming that the PyWebIO application is running at the ``localhost:5000`` "
"address, if you want to access your PyWebIO application via "
"``http://server_ip/some_path/tool``, a sample Nginx configuration is as "
"follows::"
msgstr ""
"假设PyWebIO应用运行在 ``localhost:5000`` 地址，如果你想通过 "
"``http://server_ip/some_path/tool`` 来访问应用，需要的Nginx配置如下::"

#: ../../misc.rst:25
msgid ""
"map $http_upgrade $connection_upgrade {\n"
"    default upgrade;\n"
"    '' close;\n"
"}\n"
"\n"
"server {\n"
"    listen 80;\n"
"\n"
"    location /some_path/ {\n"
"        alias /path/to/pywebio/static/dir/;\n"
"    }\n"
"    location /some_path/tool {\n"
"         proxy_read_timeout 300s;\n"
"         proxy_send_timeout 300s;\n"
"         proxy_http_version 1.1;\n"
"         proxy_set_header Host $http_host;\n"
"         proxy_set_header Upgrade $http_upgrade;\n"
"         proxy_set_header Connection $connection_upgrade;\n"
"         proxy_pass http://localhost:5000/;\n"
"    }\n"
"}"
msgstr ""

#: ../../misc.rst:48
msgid ""
"The above configuration file hosts the static files of PyWebIO on the "
"``/some_path/`` path, and reverse proxy ``/some_path/tool`` to "
"``localhost:5000``."
msgstr ""
"以上配置文件将PyWebIO的静态文件托管到 ``/some_path/`` 目录下， 并将 ``/some_path/tool`` 反向代理到 "
"``localhost:5000``"

#: ../../misc.rst:50
msgid ""
"The path of the static file of PyWebIO can be obtained with the command "
"``python3 -c \"import pywebio; print(pywebio.STATIC_PATH)\"``, you can also "
"copy the static file to other directories::"
msgstr ""
"PyWebIO的静态文件的路径可使用命令 ``python3 -c \"import pywebio; "
"print(pywebio.STATIC_PATH)\"`` 获得，你也可以将静态文件复制到其他目录下::"

#: ../../misc.rst:52
msgid "cp -r `python3 -c \"import pywebio; print(pywebio.STATIC_PATH)\"` ~/web"
msgstr ""

#~ msgid ""
#~ "Assuming that the backend server is "
#~ "running at the ``localhost:5000`` address, "
#~ "and the backend API of PyWebIO is "
#~ "bind to the ``/tool`` path, the "
#~ "configuration of Nginx is as follows::"
#~ msgstr ""
#~ "假设后端服务器运行在 ``localhost:5000`` 地址，并将PyWebIO的后端接口绑定到 "
#~ "``/tool`` 路径上，则通过Nginx访问PyWebIO服务的配置如下::"

#~ msgid ""
#~ "map $http_upgrade $connection_upgrade {\n"
#~ "    default upgrade;\n"
#~ "    '' close;\n"
#~ "}\n"
#~ "\n"
#~ "server {\n"
#~ "    listen 80;\n"
#~ "\n"
#~ "    location /some_path/ {\n"
#~ "        alias /path/to/pywebio/static/dir/;\n"
#~ "    }\n"
#~ "    location /some_path/tool {\n"
#~ "         proxy_read_timeout 300s;\n"
#~ "         proxy_send_timeout 300s;\n"
#~ "         proxy_http_version 1.1;\n"
#~ "         proxy_set_header Host $host:$server_port;\n"
#~ "         proxy_set_header Upgrade $http_upgrade;\n"
#~ "         proxy_set_header Connection $connection_upgrade;\n"
#~ "         proxy_pass http://localhost:5000/;\n"
#~ "    }\n"
#~ "}"
#~ msgstr ""

