Skip to content

Commit

Permalink
feat: override code block style using id selector
Browse files Browse the repository at this point in the history
Signed-off-by: DingChil <[email protected]>
  • Loading branch information
DingChil committed Oct 24, 2023
1 parent d6ecdce commit adcbc85
Show file tree
Hide file tree
Showing 22 changed files with 611 additions and 418 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"prettier.endOfLine": "cr",
"files.eol": "\n",
"cSpell.words": ["csui", "openai", "Webpilot"]
"cSpell.words": ["csui", "gettext", "openai", "Webpilot"]
}
58 changes: 26 additions & 32 deletions assets/locales/en/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,9 @@
"_to_use": {
"message": " to use"
},
"About": {
"message": "About"
},
"Account": {
"message": "Account"
},
"Active_Webpilot": {
"message": "Active Webpilot"
},
"Advanced": {
"message": "Advanced"
},
"and_pin_Webpilot_to_your_nav_bar": {
"message": "and pin Webpilot to your nav bar"
},
Expand All @@ -32,8 +23,8 @@
"Change_Shortcut": {
"message": "Change Shortcut"
},
"Choose_prompts": {
"message": "Choose prompts"
"Choose": {
"message": "Choose"
},
"Chrome_s_Settings__History__and_Web_Store_pages": {
"message": "Chrome's Settings, History, and Web Store pages"
Expand All @@ -44,6 +35,9 @@
"Close": {
"message": "Close"
},
"Confirm": {
"message": "Confirm"
},
"Current_Webpage_Not_Supported": {
"message": "Current Webpage Not Supported"
},
Expand All @@ -56,26 +50,26 @@
"Display_Webpilot_icon_when_text_is_selected": {
"message": "Display Webpilot icon when text is selected"
},
"Draw": {
"message": "Draw"
},
"Due_to_Chrome_s_constraints__Webpilot_cannot_be_activated_on_the_following_webpages_": {
"message": "Due to Chrome's constraints, Webpilot cannot be activated on the following webpages:"
},
"Enjoy_Webpilot_AI_for": {
"message": "Enjoy Webpilot AI for"
},
"Esc_to_back": {
"message": "Esc to back"
"Explain": {
"message": "Explain"
},
"Esc_to_close": {
"message": "Esc to close"
"Explain_it_in_English_using_words_a_middle_schooler_can_understand": {
"message": "Explain it in English using words a middle schooler can understand"
},
"Extension_Settings": {
"message": "Extension Settings"
},
"Find_the_questions_todo_on_the_page__analyze_them_step_by_step__and_provide_a_complete_answer__If_a_specified_starting_point_is_given__use_it_directly_without_changing": {
"message": "Find the questions/todo on the page, analyze them step by step, and provide a complete answer. If a specified starting point is given, use it directly without changing"
},
"For_more_usage__you_can_add_a_paid_plan_later": {
"message": "For more usage, you can add a paid plan later"
"Find_the_questions_todo_on_the_page__analyze_them_step_by_step__and_provide_a_complete_solution_in_the_end__If_a_specified_starting_point_is_given__use_it_directly_without_changing_": {
"message": "Find the questions/todo on the page, analyze them step by step, and provide a complete solution in the end. If a specified starting point is given, use it directly without changing."
},
"FREE": {
"message": "FREE"
Expand All @@ -89,27 +83,30 @@
"How_to_Use": {
"message": "How to Use"
},
"Let_s_draw_an_image_about_this__You_need_to_write_in_English_without_word_wraps_and_headlines__without_connection_words__back_to_back_separated_with_commas___1____2____3____4___environment____5____6___style_settings__________Replace__1__with_the_subject__A_image_of____________Replace__2__with_the_sentence_you_mentioned__________Replace__3__with_a_list_of_creative_detailed_descriptions_about__element____________Replace__4__with_a_list_of_detailed_descriptions_about_the_environment_of_the_scene__________Replace__5__with_a_list_of_detailed_descriptions_about_the_mood_feelings_and_atmosphere_of_the_scene__________Replace__6__with_an_appropriate_director_or_artist__If_he_she_is_a_historical_figure__include_his_her_country_and_dynasty__________Simply_write_the_without_explanation__replace_the_content_inside_the_brackets_with_details_about_the_content_word_inside_the_brackets_and_delete_the_brackets__Repeat_that_for_every_bracket_in_the_prompt__complex_prompt_for_an_AI_based_text_to_image_program_that_converts_a_prompt_about_a_topic_into_an_image__The_outcome_depends_on_the_prompt_s_coherence__The_topic_of_the_whole_scene_is_always_dependent_on_the_subject_that_is_replaced_with__element___always_start_the_prompt_with___imagine_prompt____don_t_use_any_line_breaks__Proper_grammar_is_unnecessary_and_details_can_be_listed__________Do_not_show_things_like___1____element___in_your_response_": {
"message": "Let's draw an image about this. You need to write in English without word wraps and headlines, without connection words. back to back separated with commas: [1], [2], [3], [4] {environment}, [5], [6] {style settings}\n Replace [1] with the subject \"A image of \";\n Replace [2] with the sentence you mentioned;\n Replace [3] with a list of creative detailed descriptions about [element]; \n Replace [4] with a list of detailed descriptions about the environment of the scene;\n Replace [5] with a list of detailed descriptions about the mood/feelings and atmosphere of the scene;\n Replace [6] with an appropriate director or artist. If he/she is a historical figure, include his/her country and dynasty.\n Simply write the without explanation, replace the content inside the brackets with details about the content/word inside the brackets and delete the brackets. Repeat that for every bracket in the prompt, complex prompt for an AI-based text to image program that converts a prompt about a topic into an image. The outcome depends on the prompt's coherence. The topic of the whole scene is always dependent on the subject that is replaced with [element], always start the prompt with \"/imagine prompt:\", don't use any line breaks, Proper grammar is unnecessary and details can be listed.\n Do not show things like \"[1]\"\"[element]\" in your response."
},
"New_tab_and_blank_pages": {
"message": "New tab and blank pages"
},
"OpenAI_Credits": {
"message": "OpenAI Credits"
},
"Opensource_AI_Assistant_On_All_Websites": {
"message": "Opensource AI Assistant On All Websites"
},
"Pin_Webpilot": {
"message": "Pin Webpilot"
},
"Pop_Up": {
"message": "Pop Up"
},
"Refine": {
"message": "Refine"
},
"Refine_text__review_and_revise_problems_in_spelling__grammar__punctuation__word_usage__and_sentence_structure": {
"message": "Refine text, review and revise problems in spelling, grammar, punctuation, word usage, and sentence structure"
},
"Save_Changes": {
"message": "Save Changes"
},
"Search": {
"message": "Search"
},
"Select_text__and_press_": {
"message": "Select text, and press "
},
Expand All @@ -122,15 +119,15 @@
"Settings": {
"message": "Settings"
},
"Setup_your_own_API_key__to_enjoy_more": {
"message": "Setup your own API key, to enjoy more"
},
"Side_Bar": {
"message": "Side Bar"
},
"Solve": {
"message": "Solve"
},
"Star_on_Github": {
"message": "Star on Github"
},
"Summarize": {
"message": "Summarize"
},
Expand All @@ -149,9 +146,6 @@
"Webpilot_Credit": {
"message": "Webpilot Credit"
},
"Webpilot_is_open_source": {
"message": "Webpilot is open source"
},
"Webpilot_will_answer_based_on_the_current_page_if_no_text_is_selected": {
"message": "Webpilot will answer based on the current page if no text is selected"
},
Expand Down
104 changes: 49 additions & 55 deletions assets/locales/zh_CN/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,16 @@
"message": "Web copilot for all,免费且开源,贼好用!"
},
"_to_use": {
"message": " to use"
},
"About": {
"message": "About"
},
"Account": {
"message": "Account"
"message": " 就好了"
},
"Active_Webpilot": {
"message": "Active Webpilot"
},
"Advanced": {
"message": "Advanced"
"message": "启用 Webpilot"
},
"and_pin_Webpilot_to_your_nav_bar": {
"message": "and pin Webpilot to your nav bar"
"message": "然后将 Webpilot 固定在导航栏"
},
"API_Settings": {
"message": "API Settings"
"message": "API 设置"
},
"Ask_a_question_about_this_webpage": {
"message": "向这个网页提问"
Expand All @@ -32,53 +23,56 @@
"Change_Shortcut": {
"message": "更改快捷键"
},
"Choose_prompts": {
"message": "Choose prompts"
"Choose": {
"message": "选择"
},
"Chrome_s_Settings__History__and_Web_Store_pages": {
"message": "Chrome 的设置、历史记录和 Web 商店页面"
},
"Click": {
"message": "Click"
"message": "点击"
},
"Close": {
"message": "Close"
"message": "关闭"
},
"Confirm": {
"message": "确认"
},
"Current_Webpage_Not_Supported": {
"message": "当前网页不支持"
},
"Display_Mode": {
"message": "Display Mode"
"message": "展示方式"
},
"Display_Webpilot": {
"message": "Display Webpilot"
"message": "展示 Webpilot"
},
"Display_Webpilot_icon_when_text_is_selected": {
"message": "Display Webpilot icon when text is selected"
"message": "选中文字后,展示悬浮框"
},
"Draw": {
"message": "Draw"
},
"Due_to_Chrome_s_constraints__Webpilot_cannot_be_activated_on_the_following_webpages_": {
"message": "由于 Chrome 的限制,Webpilot 无法在以下网页上启动:"
},
"Enjoy_Webpilot_AI_for": {
"message": "Enjoy Webpilot AI for"
"message": "尽享 WebPilot AI"
},
"Esc_to_back": {
"message": "Esc to back"
"Explain": {
"message": "Explain"
},
"Esc_to_close": {
"message": "Esc to close"
"Explain_it_in_English_using_words_a_middle_schooler_can_understand": {
"message": "用初中生可以懂的话来解释,说中文"
},
"Extension_Settings": {
"message": "Extension Settings"
},
"Find_the_questions_todo_on_the_page__analyze_them_step_by_step__and_provide_a_complete_answer__If_a_specified_starting_point_is_given__use_it_directly_without_changing": {
"message": "在页面上找到问题/待办事项,逐步分析它们,并提供完整的答案。如果给定了特定的开头,不要更改,直接使用"
"message": "插件设置"
},
"For_more_usage__you_can_add_a_paid_plan_later": {
"message": "For more usage, you can add a paid plan later"
"Find_the_questions_todo_on_the_page__analyze_them_step_by_step__and_provide_a_complete_solution_in_the_end__If_a_specified_starting_point_is_given__use_it_directly_without_changing_": {
"message": "在页面上找到问题/待办事项,逐步分析它们,并在最后提供完整的解决方案。如果给定了特定的开头,不要更改,直接使用。"
},
"FREE": {
"message": "FREE"
"message": "免费哒!"
},
"Free_usage_for_this_week_has_been_exhausted__50_times_week___You_can_input_your_OpenAI_API_Key_in_the_settings_page_for_unlimited_use__or_wait_for_the_quota_refresh_at_0_00_UTC_0_on_Monday_": {
"message": "本周免费额度已用尽(50 次/周)。您可在设置页面填写自己的 OpenAI API Key 以实现无限使用,或等待周一 UTC+0 0:00 刷新额度。"
Expand All @@ -87,58 +81,61 @@
"message": "针对该页面,列举10个长尾关键词,用作SEO"
},
"How_to_Use": {
"message": "How to Use"
"message": "如何使用"
},
"Let_s_draw_an_image_about_this__You_need_to_write_in_English_without_word_wraps_and_headlines__without_connection_words__back_to_back_separated_with_commas___1____2____3____4___environment____5____6___style_settings__________Replace__1__with_the_subject__A_image_of____________Replace__2__with_the_sentence_you_mentioned__________Replace__3__with_a_list_of_creative_detailed_descriptions_about__element____________Replace__4__with_a_list_of_detailed_descriptions_about_the_environment_of_the_scene__________Replace__5__with_a_list_of_detailed_descriptions_about_the_mood_feelings_and_atmosphere_of_the_scene__________Replace__6__with_an_appropriate_director_or_artist__If_he_she_is_a_historical_figure__include_his_her_country_and_dynasty__________Simply_write_the_without_explanation__replace_the_content_inside_the_brackets_with_details_about_the_content_word_inside_the_brackets_and_delete_the_brackets__Repeat_that_for_every_bracket_in_the_prompt__complex_prompt_for_an_AI_based_text_to_image_program_that_converts_a_prompt_about_a_topic_into_an_image__The_outcome_depends_on_the_prompt_s_coherence__The_topic_of_the_whole_scene_is_always_dependent_on_the_subject_that_is_replaced_with__element___always_start_the_prompt_with___imagine_prompt____don_t_use_any_line_breaks__Proper_grammar_is_unnecessary_and_details_can_be_listed__________Do_not_show_things_like___1____element___in_your_response_": {
"message": "Let's draw an image about this. You need to write in English without word wraps and headlines, without connection words. back to back separated with commas: [1], [2], [3], [4] {environment}, [5], [6] {style settings}\n Replace [1] with the subject \"A image of \";\n Replace [2] with the sentence you mentioned;\n Replace [3] with a list of creative detailed descriptions about [element]; \n Replace [4] with a list of detailed descriptions about the environment of the scene;\n Replace [5] with a list of detailed descriptions about the mood/feelings and atmosphere of the scene;\n Replace [6] with an appropriate director or artist. If he/she is a historical figure, include his/her country and dynasty.\n Simply write the without explanation, replace the content inside the brackets with details about the content/word inside the brackets and delete the brackets. Repeat that for every bracket in the prompt, complex prompt for an AI-based text to image program that converts a prompt about a topic into an image. The outcome depends on the prompt's coherence. The topic of the whole scene is always dependent on the subject that is replaced with [element], always start the prompt with \"/imagine prompt:\", don't use any line breaks, Proper grammar is unnecessary and details can be listed.\n Do not show things like \"[1]\"\"[element]\" in your response."
},
"New_tab_and_blank_pages": {
"message": "新标签页和空白页"
},
"OpenAI_Credits": {
"message": "OpenAI Credits"
},
"Opensource_AI_Assistant_On_All_Websites": {
"message": "Opensource AI Assistant On All Websites"
},
"Pin_Webpilot": {
"message": "Pin Webpilot"
"message": " Webpilot 置顶"
},
"Pop_Up": {
"message": "Pop Up"
"message": "弹窗"
},
"Save_Changes": {
"message": "Save Changes"
"Refine": {
"message": "Refine"
},
"Search": {
"message": "Search"
"Refine_text__review_and_revise_problems_in_spelling__grammar__punctuation__word_usage__and_sentence_structure": {
"message": "润色该段文字,修正语法、错字和段落结构,使其更通顺、易读"
},
"Save_Changes": {
"message": "保存"
},
"Select_text__and_press_": {
"message": "Select text, and press "
"message": "先选中文字,再按 "
},
"SEO": {
"message": "SEO"
},
"Set_up_API": {
"message": "Set up API"
"message": "设置 API"
},
"Settings": {
"message": "Settings"
"message": "设置"
},
"Setup_your_own_API_key__to_enjoy_more": {
"message": "设置自己的 API key, 无限使用"
},
"Side_Bar": {
"message": "Side Bar"
"message": "侧边栏"
},
"Solve": {
"message": "解题"
},
"Star_on_Github": {
"message": "Star on Github"
},
"Summarize": {
"message": "总结"
},
"Summarize_in_English__concise_and_clear": {
"message": "用中文总结,简明扼要"
},
"up_to_50_times_week": {
"message": "up to 50 times/week"
"message": "每周 50 "
},
"Use_my_OpenAI_API_key": {
"message": "使用我自己的 OpenAI API key"
Expand All @@ -149,13 +146,10 @@
"Webpilot_Credit": {
"message": "Webpilot Credit"
},
"Webpilot_is_open_source": {
"message": "Webpilot is open source"
},
"Webpilot_will_answer_based_on_the_current_page_if_no_text_is_selected": {
"message": "Webpilot will answer based on the current page if no text is selected"
"message": "Webpilot 将对选中文字进行问答"
},
"when_text_is_selected": {
"message": "when text is selected"
"message": "当文字被选中时"
}
}
Loading

0 comments on commit adcbc85

Please sign in to comment.