From a3554379689c169754eac1ccd2eb69c113fe1ce8 Mon Sep 17 00:00:00 2001 From: Darren Burns Date: Fri, 25 Oct 2024 16:56:11 +0100 Subject: [PATCH 1/4] Bump Textual version --- pyproject.toml | 8 +++++--- src/posting/app.py | 6 +++--- uv.lock | 34 ++++++++++++++++++++++++++++------ 3 files changed, 36 insertions(+), 12 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 6f45fa75..cc30424c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "posting" -version = "2.0.0" +version = "2.0.1" description = "The modern API client that lives in your terminal." authors = [ { name = "Darren Burns", email = "darrenb900@gmail.com" } @@ -15,8 +15,10 @@ dependencies = [ "pyyaml>=6.0.2,<7.0.0", "pydantic-settings>=2.4.0,<3.0.0", "python-dotenv>=1.0.1,<2.0.0", - "textual[syntax]==0.83.0", # pinned intentionally - "textual-autocomplete==3.0.0a12", # pinned intentionally + "textual[syntax]==0.85.0", + # pinned intentionally + "textual-autocomplete==3.0.0a12", + # pinned intentionally "watchfiles>=0.24.0", ] readme = "README.md" diff --git a/src/posting/app.py b/src/posting/app.py index 2216768b..97acd26b 100644 --- a/src/posting/app.py +++ b/src/posting/app.py @@ -176,7 +176,7 @@ class MainScreen(Screen[None]): selected_method: Reactive[HttpRequestMethod] = reactive("GET", init=False) """The currently selected method of the request.""" - layout: Reactive[PostingLayout] = reactive("vertical", init=False) + current_layout: Reactive[PostingLayout] = reactive("vertical", init=False) """The current layout of the app.""" expanded_section: Reactive[Literal["request", "response"] | None] = reactive( None, init=False @@ -197,7 +197,7 @@ def __init__( self.settings = SETTINGS.get() def on_mount(self) -> None: - self.layout = self._initial_layout + self.current_layout = self._initial_layout # Set the initial focus based on the settings. focus_on_startup = self.settings.focus.on_startup @@ -1000,7 +1000,7 @@ def get_css_variables(self) -> dict[str, str]: return {**super().get_css_variables(), **color_system} def command_layout(self, layout: Literal["vertical", "horizontal"]) -> None: - self.main_screen.layout = layout + self.main_screen.current_layout = layout def command_theme(self, theme: str) -> None: self.theme = theme diff --git a/uv.lock b/uv.lock index 8993ff8d..e233b9b2 100644 --- a/uv.lock +++ b/uv.lock @@ -156,8 +156,14 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/80/d6/0bd38d758d1afa62a5524172f0b18626bb2392d717ff94806f741fcd5ee9/Brotli-1.1.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:19c116e796420b0cee3da1ccec3b764ed2952ccfcc298b55a10e5610ad7885f9", size = 2813051 }, { url = "https://files.pythonhosted.org/packages/14/56/48859dd5d129d7519e001f06dcfbb6e2cf6db92b2702c0c2ce7d97e086c1/Brotli-1.1.0-cp311-cp311-musllinux_1_1_ppc64le.whl", hash = "sha256:510b5b1bfbe20e1a7b3baf5fed9e9451873559a976c1a78eebaa3b86c57b4265", size = 2938172 }, { url = "https://files.pythonhosted.org/packages/3d/77/a236d5f8cd9e9f4348da5acc75ab032ab1ab2c03cc8f430d24eea2672888/Brotli-1.1.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a1fd8a29719ccce974d523580987b7f8229aeace506952fa9ce1d53a033873c8", size = 2933023 }, + { url = "https://files.pythonhosted.org/packages/f1/87/3b283efc0f5cb35f7f84c0c240b1e1a1003a5e47141a4881bf87c86d0ce2/Brotli-1.1.0-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:c247dd99d39e0338a604f8c2b3bc7061d5c2e9e2ac7ba9cc1be5a69cb6cd832f", size = 2935871 }, + { url = "https://files.pythonhosted.org/packages/f3/eb/2be4cc3e2141dc1a43ad4ca1875a72088229de38c68e842746b342667b2a/Brotli-1.1.0-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:1b2c248cd517c222d89e74669a4adfa5577e06ab68771a529060cf5a156e9757", size = 2847784 }, + { url = "https://files.pythonhosted.org/packages/66/13/b58ddebfd35edde572ccefe6890cf7c493f0c319aad2a5badee134b4d8ec/Brotli-1.1.0-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:2a24c50840d89ded6c9a8fdc7b6ed3692ed4e86f1c4a4a938e1e92def92933e0", size = 3034905 }, + { url = "https://files.pythonhosted.org/packages/84/9c/bc96b6c7db824998a49ed3b38e441a2cae9234da6fa11f6ed17e8cf4f147/Brotli-1.1.0-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:f31859074d57b4639318523d6ffdca586ace54271a73ad23ad021acd807eb14b", size = 2929467 }, { url = "https://files.pythonhosted.org/packages/e7/71/8f161dee223c7ff7fea9d44893fba953ce97cf2c3c33f78ba260a91bcff5/Brotli-1.1.0-cp311-cp311-win32.whl", hash = "sha256:39da8adedf6942d76dc3e46653e52df937a3c4d6d18fdc94a7c29d263b1f5b50", size = 333169 }, { url = "https://files.pythonhosted.org/packages/02/8a/fece0ee1057643cb2a5bbf59682de13f1725f8482b2c057d4e799d7ade75/Brotli-1.1.0-cp311-cp311-win_amd64.whl", hash = "sha256:aac0411d20e345dc0920bdec5548e438e999ff68d77564d5e9463a7ca9d3e7b1", size = 357253 }, + { url = "https://files.pythonhosted.org/packages/5c/d0/5373ae13b93fe00095a58efcbce837fd470ca39f703a235d2a999baadfbc/Brotli-1.1.0-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:32d95b80260d79926f5fab3c41701dbb818fde1c9da590e77e571eefd14abe28", size = 815693 }, + { url = "https://files.pythonhosted.org/packages/8e/48/f6e1cdf86751300c288c1459724bfa6917a80e30dbfc326f92cea5d3683a/Brotli-1.1.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:b760c65308ff1e462f65d69c12e4ae085cff3b332d894637f6273a12a482d09f", size = 422489 }, { url = "https://files.pythonhosted.org/packages/06/88/564958cedce636d0f1bed313381dfc4b4e3d3f6015a63dae6146e1b8c65c/Brotli-1.1.0-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:316cc9b17edf613ac76b1f1f305d2a748f1b976b033b049a6ecdfd5612c70409", size = 873081 }, { url = "https://files.pythonhosted.org/packages/58/79/b7026a8bb65da9a6bb7d14329fd2bd48d2b7f86d7329d5cc8ddc6a90526f/Brotli-1.1.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:caf9ee9a5775f3111642d33b86237b05808dafcd6268faa492250e9b78046eb2", size = 446244 }, { url = "https://files.pythonhosted.org/packages/e5/18/c18c32ecea41b6c0004e15606e274006366fe19436b6adccc1ae7b2e50c2/Brotli-1.1.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:70051525001750221daa10907c77830bc889cb6d865cc0b813d9db7fefc21451", size = 2906505 }, @@ -168,8 +174,24 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/76/58/5c391b41ecfc4527d2cc3350719b02e87cb424ef8ba2023fb662f9bf743c/Brotli-1.1.0-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:4093c631e96fdd49e0377a9c167bfd75b6d0bad2ace734c6eb20b348bc3ea180", size = 2814452 }, { url = "https://files.pythonhosted.org/packages/c7/4e/91b8256dfe99c407f174924b65a01f5305e303f486cc7a2e8a5d43c8bec3/Brotli-1.1.0-cp312-cp312-musllinux_1_1_ppc64le.whl", hash = "sha256:7e4c4629ddad63006efa0ef968c8e4751c5868ff0b1c5c40f76524e894c50248", size = 2938751 }, { url = "https://files.pythonhosted.org/packages/5a/a6/e2a39a5d3b412938362bbbeba5af904092bf3f95b867b4a3eb856104074e/Brotli-1.1.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:861bf317735688269936f755fa136a99d1ed526883859f86e41a5d43c61d8966", size = 2933757 }, + { url = "https://files.pythonhosted.org/packages/13/f0/358354786280a509482e0e77c1a5459e439766597d280f28cb097642fc26/Brotli-1.1.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:87a3044c3a35055527ac75e419dfa9f4f3667a1e887ee80360589eb8c90aabb9", size = 2936146 }, + { url = "https://files.pythonhosted.org/packages/80/f7/daf538c1060d3a88266b80ecc1d1c98b79553b3f117a485653f17070ea2a/Brotli-1.1.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:c5529b34c1c9d937168297f2c1fde7ebe9ebdd5e121297ff9c043bdb2ae3d6fb", size = 2848055 }, + { url = "https://files.pythonhosted.org/packages/ad/cf/0eaa0585c4077d3c2d1edf322d8e97aabf317941d3a72d7b3ad8bce004b0/Brotli-1.1.0-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:ca63e1890ede90b2e4454f9a65135a4d387a4585ff8282bb72964fab893f2111", size = 3035102 }, + { url = "https://files.pythonhosted.org/packages/d8/63/1c1585b2aa554fe6dbce30f0c18bdbc877fa9a1bf5ff17677d9cca0ac122/Brotli-1.1.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:e79e6520141d792237c70bcd7a3b122d00f2613769ae0cb61c52e89fd3443839", size = 2930029 }, { url = "https://files.pythonhosted.org/packages/5f/3b/4e3fd1893eb3bbfef8e5a80d4508bec17a57bb92d586c85c12d28666bb13/Brotli-1.1.0-cp312-cp312-win32.whl", hash = "sha256:5f4d5ea15c9382135076d2fb28dde923352fe02951e66935a9efaac8f10e81b0", size = 333276 }, { url = "https://files.pythonhosted.org/packages/3d/d5/942051b45a9e883b5b6e98c041698b1eb2012d25e5948c58d6bf85b1bb43/Brotli-1.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:906bc3a79de8c4ae5b86d3d75a8b77e44404b0f4261714306e3ad248d8ab0951", size = 357255 }, + { url = "https://files.pythonhosted.org/packages/0a/9f/fb37bb8ffc52a8da37b1c03c459a8cd55df7a57bdccd8831d500e994a0ca/Brotli-1.1.0-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:8bf32b98b75c13ec7cf774164172683d6e7891088f6316e54425fde1efc276d5", size = 815681 }, + { url = "https://files.pythonhosted.org/packages/06/b3/dbd332a988586fefb0aa49c779f59f47cae76855c2d00f450364bb574cac/Brotli-1.1.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:7bc37c4d6b87fb1017ea28c9508b36bbcb0c3d18b4260fcdf08b200c74a6aee8", size = 422475 }, + { url = "https://files.pythonhosted.org/packages/bb/80/6aaddc2f63dbcf2d93c2d204e49c11a9ec93a8c7c63261e2b4bd35198283/Brotli-1.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3c0ef38c7a7014ffac184db9e04debe495d317cc9c6fb10071f7fefd93100a4f", size = 2906173 }, + { url = "https://files.pythonhosted.org/packages/ea/1d/e6ca79c96ff5b641df6097d299347507d39a9604bde8915e76bf026d6c77/Brotli-1.1.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:91d7cc2a76b5567591d12c01f019dd7afce6ba8cba6571187e21e2fc418ae648", size = 2943803 }, + { url = "https://files.pythonhosted.org/packages/ac/a3/d98d2472e0130b7dd3acdbb7f390d478123dbf62b7d32bda5c830a96116d/Brotli-1.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a93dde851926f4f2678e704fadeb39e16c35d8baebd5252c9fd94ce8ce68c4a0", size = 2918946 }, + { url = "https://files.pythonhosted.org/packages/c4/a5/c69e6d272aee3e1423ed005d8915a7eaa0384c7de503da987f2d224d0721/Brotli-1.1.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:f0db75f47be8b8abc8d9e31bc7aad0547ca26f24a54e6fd10231d623f183d089", size = 2845707 }, + { url = "https://files.pythonhosted.org/packages/58/9f/4149d38b52725afa39067350696c09526de0125ebfbaab5acc5af28b42ea/Brotli-1.1.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:6967ced6730aed543b8673008b5a391c3b1076d834ca438bbd70635c73775368", size = 2936231 }, + { url = "https://files.pythonhosted.org/packages/5a/5a/145de884285611838a16bebfdb060c231c52b8f84dfbe52b852a15780386/Brotli-1.1.0-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:7eedaa5d036d9336c95915035fb57422054014ebdeb6f3b42eac809928e40d0c", size = 2848157 }, + { url = "https://files.pythonhosted.org/packages/50/ae/408b6bfb8525dadebd3b3dd5b19d631da4f7d46420321db44cd99dcf2f2c/Brotli-1.1.0-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:d487f5432bf35b60ed625d7e1b448e2dc855422e87469e3f450aa5552b0eb284", size = 3035122 }, + { url = "https://files.pythonhosted.org/packages/af/85/a94e5cfaa0ca449d8f91c3d6f78313ebf919a0dbd55a100c711c6e9655bc/Brotli-1.1.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:832436e59afb93e1836081a20f324cb185836c617659b07b129141a8426973c7", size = 2930206 }, + { url = "https://files.pythonhosted.org/packages/c2/f0/a61d9262cd01351df22e57ad7c34f66794709acab13f34be2675f45bf89d/Brotli-1.1.0-cp313-cp313-win32.whl", hash = "sha256:43395e90523f9c23a3d5bdf004733246fba087f2948f87ab28015f12359ca6a0", size = 333804 }, + { url = "https://files.pythonhosted.org/packages/7e/c1/ec214e9c94000d1c1974ec67ced1c970c148aa6b8d8373066123fc3dbf06/Brotli-1.1.0-cp313-cp313-win_amd64.whl", hash = "sha256:9011560a466d2eb3f5a6e4929cf4a09be405c64154e12df0dd72713f6500e32b", size = 358517 }, ] [[package]] @@ -380,7 +402,7 @@ wheels = [ [package.optional-dependencies] toml = [ - { name = "tomli", marker = "python_full_version == '3.11'" }, + { name = "tomli", marker = "python_full_version <= '3.11'" }, ] [[package]] @@ -847,7 +869,7 @@ wheels = [ [[package]] name = "posting" -version = "2.0.0b1" +version = "2.0.0" source = { editable = "." } dependencies = [ { name = "click" }, @@ -886,7 +908,7 @@ requires-dist = [ { name = "pyperclip", specifier = ">=1.9.0,<2.0.0" }, { name = "python-dotenv", specifier = ">=1.0.1,<2.0.0" }, { name = "pyyaml", specifier = ">=6.0.2,<7.0.0" }, - { name = "textual", extras = ["syntax"], specifier = "==0.83.0" }, + { name = "textual", extras = ["syntax"], specifier = "==0.85.0" }, { name = "textual-autocomplete", specifier = "==3.0.0a12" }, { name = "watchfiles", specifier = ">=0.24.0" }, { name = "xdg-base-dirs", specifier = ">=6.0.1,<7.0.0" }, @@ -1319,7 +1341,7 @@ wheels = [ [[package]] name = "textual" -version = "0.83.0" +version = "0.85.0" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "markdown-it-py", extra = ["linkify", "plugins"] }, @@ -1327,9 +1349,9 @@ dependencies = [ { name = "rich" }, { name = "typing-extensions" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/cf/0b/58ec0dbcd92a5121fdae972f09de71b5bc38d389bab53a638e24349f904d/textual-0.83.0.tar.gz", hash = "sha256:fc3b97796092d9c7e685e5392f38f3eb2007ffe1b3b1384dee6d3f10d256babd", size = 1449378 } +sdist = { url = "https://files.pythonhosted.org/packages/f0/ef/d498d5eb07ebe63299517bbee7e4be2fe8e1b4f0835763446cef1c4eaed0/textual-0.85.0.tar.gz", hash = "sha256:645c0fd0b4f61cd19383df78a1acd4f3b555e2c514cfa2f454e20692dffc10a0", size = 1461202 } wheels = [ - { url = "https://files.pythonhosted.org/packages/18/39/6cec279ca41dcacb1c92ad6e4467c9e88db4eb4d2f02300c66218ec432de/textual-0.83.0-py3-none-any.whl", hash = "sha256:d6efc1e5c54086fd0a4fe274f18b5638ca24a69325c07e1b4400a7d0a1a14c55", size = 600387 }, + { url = "https://files.pythonhosted.org/packages/9c/d5/0f35e93d1343fd8a4a1571c104dd6f0a9d038aa89d203146f22b9beed725/textual-0.85.0-py3-none-any.whl", hash = "sha256:8e75d023f06b242fb88233926dfb7801792f867643493096dd45dd216dc950f3", size = 614318 }, ] [package.optional-dependencies] From 261fb2fa5dec4f4307a2f07579ec446475ce5a11 Mon Sep 17 00:00:00 2001 From: Darren Burns Date: Fri, 25 Oct 2024 17:03:10 +0100 Subject: [PATCH 2/4] Fixes --- .coverage | Bin 53248 -> 53248 bytes src/posting/app.py | 4 ++-- src/posting/commands.py | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.coverage b/.coverage index 0ac6f55669d8c0ba9e38178f1b768a8994de0744..8902c8cc666fbf05ea75f0c1e99e374a20010cc4 100644 GIT binary patch delta 1524 zcmZ|Ndu&rx90%}o`|I=e-rH;Gw(ikxYexs`*uxEB1X_tEMnv&7~>pIS~V;mn$`5%&0Jd~>E z$o?~mKVIxvI~qF7&wDi#2(+09kz2B_JaQy1ezf=ZUj|RTbMm{;(0w*;D|_PkWrURV zM&QD|X_v|6h5Qtv<9s_o%bCKyUG-WY&BKz;Rna7CJ-td_+z~N0e>=E;@Xn^m>Kh4V zS06-jXB;EOMnhC&3*~19EEXDORbJuA3QhCy*Khx|5A<|1OQihIM7n|%Ib$}KT)F#b zR;f|gOH6F3J8Yoa)!k#ya~8T)-R%x@1J{NJ_9pH+&2$S(?5^amTv)fdUr*PwR&sCx zUB`;7oD#V1=SD!LYgy~c9;qO`@ub11J*PF%H7v4a1%0P0tu(}Hk3D(rsQ=pcefRIQ zCWdqdx{8Hz+H9Xpm#e$2NiVG%DXj?}9QE7jGUY~lri<3I8A;|0bcwoHnvurS#jHvf z&%QAwU+boe6m8t?%%BTdSY{4hJ;2K(F*ITDz3YX&{%d|ii;XT&yzyBX|9=@JkU{H| zmpkk(TFXwc8a)RzRvKib$8ff?f+J*T24PR5g9emn2m4QI*qo%}U39+kNryX^&SSj{ z4L&`cqcxdiO*gw9o-@5t)vxtLWhK!uuGFHQJo)34k&jBOOrLcA!SO%A6ct!wn^73CH8XA)9$_3()kAVf7R$?_(vPE8wK0`@4UcssM~goQ=pKaat| zhUx0BW5d?ypb;g|>F~<5iA}pafA>N1OoF7o7|yiPZ7lK>NZQM(ROE-_56Ru1IS1XO z+~{;_=thO>nv_X5sE0a}P0s7JVSfzRHyEh1yh$6C*Se~UXak#_nUQ>OGdcWlil8B6 z>f==Zoo|}LMXje4)~cgnX@IU)ZnYK4#ZQ9&p1n#|y9dhYO65XVIXLN3Mc0vggzNT6 zkxm0USW^zW(PC&t3n7fUU<>Mi^{5>}=onamO0WdwVF7A_I@AcYr~!hg9s;NiYEUiA zMUEYX2V)E3)Y~S w(1>P01DX!2RiD?S!72=FuoAVxa`Y)!hRRTnT3{(E!eUf_MW`7T9_lIk7qTXPcK`qY delta 1544 zcmXZbdu&rx90%}w@2}nMeYK@@YrCx-YqxfE>_rFLa9cs}wJ4B)#2{smh?po3qj3?l zc5}dq?g>|U=#a@nL3vM@IQBqA9^;`V1Pr5XFfa+&jV-u!X1AUmyno!!_xJmqo|Bxm zHEmGS1}!PHWlQQ@+H!owob;4^xh0Z19>uABj&lVUy z$_M#AzEgXJKhA}<`}tPwe7=RR=GXG8v_+C41^H#tuTr;kP}(guNE@W3(p)J^vPi5r zAohwUMI^o}E*8r~kLVJuqFz)B{nV4E-K;O+ruu3%YT8%3LG7!{RQonARMVVq6Nlfm zzD*y*i_L}cH*(7Jn_c=ty{qVA%i1)_u374Q?oO`BAbfl^xBHV1T;y-aeAf& zpTNs4lBGcvlq457*aVb_XIeFHM@D&NgF{4V zMNi9<8ql>Yx?n%au(w2Ia|trXmZ<#WS}}skVhH{oV$^2m4m&7Ne>1wWgQd$c3jbnv}si zN_1$J$WT=2L@YRPzS{4u>uK+v9e(L;@J1p9C__HdTmTM~Dm&{Ps#+sTmRHv=Fm^$%SY*Qq+Xg+jtuw!KciH>e&G?*A8s9ZKNvmz_tLA! zuC%W?wdSo?NAHc+QEd}Be|6j(X&o7;Dvo~zVt)T%Ag$sQrCEQX#j6ec!s1Ps0ys;Y z24{#a=pfqR1knnIiDo!JoD6%3TKIy1?Ii8;_k%!W>) z8-5@Lrow3wvfz876HXB`;UqBwz9TxIotO^CiBsShF%6CqZE%E`3Wta(@GUVJz9CxR xAkhS06O-Vpxbv7q*iRZp*he(L9^xeUlBkC^q7HTwCD=t2p_M4W=X=`n{{vJ@r2qf` diff --git a/src/posting/app.py b/src/posting/app.py index 97acd26b..fb1d50f1 100644 --- a/src/posting/app.py +++ b/src/posting/app.py @@ -581,8 +581,8 @@ async def action_new_request(self) -> None: """Open the new request flow.""" await self.collection_tree.new_request_flow(None) - def watch_layout(self, layout: Literal["horizontal", "vertical"]) -> None: - """Update the layout of the app to be horizontal or vertical.""" + def watch_current_layout(self, layout: Literal["horizontal", "vertical"]) -> None: + """Update the current layout of the app to be horizontal or vertical.""" classes = {"horizontal", "vertical"} other_class = classes.difference({layout}).pop() self.app_body.add_class(f"layout-{layout}") diff --git a/src/posting/commands.py b/src/posting/commands.py index 7ab1f049..d904a0d5 100644 --- a/src/posting/commands.py +++ b/src/posting/commands.py @@ -24,7 +24,7 @@ def commands( if isinstance(screen, MainScreen): # Only show the option to change to the layout which isn't the current one. - if screen.layout == "horizontal": + if screen.current_layout == "horizontal": commands_to_show.append( ( "layout: vertical", @@ -33,7 +33,7 @@ def commands( True, ), ) - elif screen.layout == "vertical": + elif screen.current_layout == "vertical": commands_to_show.append( ( "layout: horizontal", From 424cac2559ea09e55de78390301fd7afbc1705ac Mon Sep 17 00:00:00 2001 From: Darren Burns Date: Fri, 25 Oct 2024 17:36:13 +0100 Subject: [PATCH 3/4] CSS fixes --- .coverage | Bin 53248 -> 53248 bytes src/posting/posting.scss | 6 +++--- src/posting/widgets/key_value.py | 1 + .../widgets/request/request_options.py | 15 ++++++--------- 4 files changed, 10 insertions(+), 12 deletions(-) diff --git a/.coverage b/.coverage index 8902c8cc666fbf05ea75f0c1e99e374a20010cc4..f9c095acc90d15f8b049fcd8f68579770bb5461c 100644 GIT binary patch delta 448 zcmZozz}&Eac>_~JJr9E==V=C>eVnIxw(#`xwDF|z1oF7?=x|TruHp{icIUR`mf;rW z`oZ;->nhhmuIc;>_$#=Y_!YUzxRSX-xV*Vc_+Idx;L_%j<=e)$kV}}akFSO=hR>Bx zi%*)5llLX>A>Qr0oxEkdVZ8Rdro5WG^1MR4>^%1vAYikEz$OlsMv<1<$?4sG5(0ar zZ-14&e|7D&mp4D}pSkaB{`YqvFnMC9;^cSToGd38ZX`{<*6C=^bDV*lkyC)Zt%e0i zsh(rxZmR^cB$WO=WvpYp$JSN>V6Xe-nJ~Dyo_*}-t9ME{q;E}U+prVe7|3DGEcWB(+Bp+;ob4#_#L%cM4XY+&+;Bi z0}BHag96ZBEI>SYL60LBdpj@CZ~?PV{F5K{oELl$V}HN;9sk>gjfM=OAMW0joqVvj zSct!^4yZ^$eV;MVX-6l0oX$Miq)!7VTm=$Vu4DXk_vfc+_ut4(j_He>e5UXIq6rQF D3{<05 delta 492 zcmZozz}&Eac>_~Jy$^#W=QReNUe0Sg%{*~Dp**HM3Ou6RzqymSJ-L;+#khI+?{hPA zz2LgaWy8Ok>omVNzcSZ0zB62_xTbS;aMkl|<*VU~;WFkb5L3>PEKCat)o`-JAXY_R6u@gY$qoJgFvJ7?XR-;udbc;^5*CLGxwd% z|NagLo=yJOt*FAlU~r(G`NCV<8w@v+xU3jh8SPq_Sr|F%>{`=V?AjDS%*m%a9W&V5 zd4X&Jvrqi|ZFNAFg8DvVriPzKCw-jG%+^)`6ya0c#M_nyWXK4Y>D_+w)nA{3XBq=1 zP^oeqds_`ix9T}Y{?A@-eZ}3ug7t+X771HhUdS2-Yc%pVDIT=T+#6U-Mh)0 zeZ`ae`ZOk==!+B=X)6WVr6u>TR_;N3oqZ28&??@wOXWinZ&TXE3@2LO#H BwgvzI diff --git a/src/posting/posting.scss b/src/posting/posting.scss index 298bf77f..d1791e77 100644 --- a/src/posting/posting.scss +++ b/src/posting/posting.scss @@ -86,7 +86,7 @@ AppBody { & KeyValueInput { layout: vertical; & Button { - width: 1fr; + width: 100%; } } @@ -134,11 +134,11 @@ Footer { } RichLog { - background: $surface; + background: $surface 50%; padding-left: 1; &:focus { - background: $surface-lighten-1; + background: $surface-lighten-1 50%; border-left: wide $accent; padding-left: 0; } diff --git a/src/posting/widgets/key_value.py b/src/posting/widgets/key_value.py index 1469ea6c..0be0b124 100644 --- a/src/posting/widgets/key_value.py +++ b/src/posting/widgets/key_value.py @@ -19,6 +19,7 @@ class KeyValueInput(Horizontal): border: none; width: 1fr; margin-left: 1; + margin-right: 1; &:focus { border: none; padding: 0 1; diff --git a/src/posting/widgets/request/request_options.py b/src/posting/widgets/request/request_options.py index 5aa54924..649b7f50 100644 --- a/src/posting/widgets/request/request_options.py +++ b/src/posting/widgets/request/request_options.py @@ -15,7 +15,6 @@ class RequestOptions(VerticalScroll): Checkbox { height: 1; - margin: 0 2 1 2; padding: 0 1; border: none; background: transparent; @@ -32,15 +31,13 @@ class RequestOptions(VerticalScroll): } #proxy-option { - padding-left: 3; - margin-bottom: 1; - height: auto; + padding: 0 1 0 2; + height: 2; } #timeout-option { - padding-left: 3; - height: auto; - margin-bottom: 1; + padding: 0 1 0 2; + height: 2; } & #option-description { @@ -98,11 +95,11 @@ def compose(self) -> ComposeResult: ) with Vertical(id="proxy-option"): - yield Label("Proxy URL") + yield Label("Proxy URL:") yield VariableInput(id="proxy-url") with Vertical(id="timeout-option"): - yield Label("Timeout") + yield Label("Timeout:") yield VariableInput( value=str(self.options.timeout), id="timeout", From b6e3594cd05107eee24d15e2ed26eff1d08c7641 Mon Sep 17 00:00:00 2001 From: Darren Burns Date: Fri, 25 Oct 2024 17:38:02 +0100 Subject: [PATCH 4/4] Snapshot test updates --- .coverage | Bin 53248 -> 53248 bytes ..._set_on_startup_and_in_command_palette.svg | 190 ++++++------- .../TestJumpMode.test_click_switch.svg | 182 ++++++------ ...test_request_loaded_into_view__options.svg | 264 +++++++++--------- ..._tree_correctly_and_notification_shown.svg | 178 ++++++------ .../TestScripts.test_script_runs.svg | 221 +++++++-------- 6 files changed, 518 insertions(+), 517 deletions(-) diff --git a/.coverage b/.coverage index f9c095acc90d15f8b049fcd8f68579770bb5461c..223c4c6114670f7ee72029e4768acd0e15b0de28 100644 GIT binary patch delta 1439 zcmXBTeQXnD90%~b`*m&a>Gg%K+uCi{ZQa(v-bcsSV6>Yc3dE2IVla;J&oF92&=`p^ zTL&6`!F3FF2q-U(fr^SuK$tT20*a28j9@enfwf8ym1WEkg^hUg>CgM)KHuN>o_n6O zX`4HsxdXPQiJoog^F`0m)t%vRg-|6Ai>%0EW;x}naXZd_^*W%ca< zzgMgHn6|Q24Lh-%kNzB+;o8(x_)7PfFmhE?u#lIj>BSHWiIZT$L_RuTZP0AQX$Dz# zNL%?KOq89KN2bj9B!5cDgbU*fE5_|6To6y?<0dnP;*U#y%QKj8R=ms|5{+2KlP&95 z*oZ~(q>3`;^WaKd6+BaJ!rb`6q!mFcX7iMu_uZjv(Kp)Y+5~8^8BiO zk3vSwX ze1gA_JbUO~_g#?jaXz?a72gsbx^OUnoyGb0sIWfK?I^wn9Oy0PC`faf(VOYgdK2>Mx4Seg^ZaweZnfQk1-$m9O$LO4Hr-@4Trw=j z8Cp);a<>zw^GANSe(6N$=H-i{cixIVNXW%J?aj6{>+!yt*i)}SXmqp={n~-HJjdaI z261fckCcaF&g|Ij%U89Z+x$?5IoiQ@%DisO;(N`UrUzo-(VIPb?!&&IC>VrQ1K`CB zEu+N?*_f_9+ma(;n%3CjkuX);)v`>i(?(iqCG=<|krYrdS$i>}f)8C- zvH*I>d^kmhXTaAKro&gHA5N0FaDvQ%FUf2;PG-STG84WaGoXv~!VxkZ4wGr{8JP;7 zk{+j!nUYeB!gib0;BBoXLgd_&+qsB-JaXr zo^TI@d!RdmbG(=NGUxcT@p336k#h48k^0R;(&tiCqEfT;mh_sGZ~4G-+){0M-Lle> zX-O8Ji4Vlv;wACCwa0o?JZ;SpTg9znwYWwsRsK+Jh(6J&e5qU#la+{aQmIv5RlG`u zVwV4uzmu=Z?Q*MJBm3ntd9j=&+hjqCk>~3(hkC`tpR%8A)8%NDQSHmP`_!p#j#daa z$ek^fbb}skuMA1oiNKjvfu7_Ui*9iidW=;Lcl-etOo|!lQPwFrSM2mKE4;3Fn`^Wo z=FDEM{=EX3(JZu_4h7_6T-;Uk|!UH<_-Gq`-M|>x|zMPbzI_Qt*W4niTlifEL)fq z^*4}OGB`j;xOa_-Hn54!t{v`+7jI@u4aWkV%Nbkj|G zEb3k&(2XomAy8?g>v^+THFUFoYyoGkDv$ADo)}0r>v{I^XsW)p!}GRDvnC$3{F8Z; zs41*WU3P2y>SGWzIkD5yNvm0tSYD~$h8I6x@+}(HN z@oj@sGwZ*$J5yE7#K!L8N+85I*Viy3$UaTbzv}QQCe6r3w!(*be6E(HKkV>uye@ZU zxq-#m`LQ%Yy!U#qT?0uouq53VFCSPr+XN1c)2lku9fXD6#b0;A#lWh>+hEJS&q+gi zxYHG)!Newc{Uz)SegFR7=hireCX$^6J+cc z&PtCbzPT{SP2QiL{BUH<<)lYgQjr~RVo#WOV}5*YHrDWyFvz;OftF_#OKB^c2eKxg zOwG;(2S&yjy06QsySh?%e>L5w@93)bEusN-*V+Z~@!#Up6DuSGAr*7;u}9b2g5EO& zI%^Xv&|F9N>i>4-srk=?|F463NyKxd+pmPW1h$W%7|x;ja0bnTAnJx=s1pvM4roD> zVHc`E6Dq=H)C`TN2^vrV>QN)qp-E7S@~{bo5NyQ402_?#U>RV24ff^GjV^~Mx(p&{ z8FZqh(1Dh~yXZ^MjuwH276L^J;2m@coJD - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Posting + Posting - - - - -Posting                                                                    - -GET Send  -anothertest -╭─ Collection── Request ─╮ - GET echo  theme: anothertestriptsOptio -GET get ranSet the theme to anothertest━━━━━━━━━━━━ -POS echo po╱╱╱╱╱╱╱╱╱╱╱╱ -▼ jsonplaceholder/╱╱╱╱╱╱╱╱╱╱╱╱╱╱There are no headers.╱╱╱╱╱╱╱╱╱╱╱╱╱╱ -▼ posts/╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ -GET get all      NameValue Add header  -GET get one      ╰─────────────────────────────────────────────────╯ -POS create       ╭────────────────────────────────────── Response ─╮ -DEL delete a postBodyHeadersCookiesScriptsTrace -───────────────────────━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -This is an echo  -server we can use to  -see exactly what  -request is being  -sent.1:1read-onlyJSONWrap X -╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ - d Dupe  ⌫ Delete  ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump + + + + +Posting                                                                    + +GET Send  +anothertest +╭─ Collection── Request ─╮ + GET echo  theme: anothertestriptsOptio +GET get ranSet the theme to anothertest━━━━━━━━━━━━ +POS echo po╱╱╱╱╱╱╱╱╱╱╱╱ +▼ jsonplaceholder/╱╱╱╱╱╱╱╱╱╱╱╱╱╱There are no headers.╱╱╱╱╱╱╱╱╱╱╱╱╱╱ +▼ posts/╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ +GET get all      NameValue Add header  +GET get one      ╰─────────────────────────────────────────────────╯ +POS create       ╭────────────────────────────────────── Response ─╮ +DEL delete a postBodyHeadersCookiesScriptsTrace +───────────────────────━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ +This is an echo  +server we can use to  +see exactly what  +request is being  +sent.1:1read-onlyJSONWrap X +╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ + d Dupe  ⌫ Delete  ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump diff --git a/tests/__snapshots__/test_snapshots/TestJumpMode.test_click_switch.svg b/tests/__snapshots__/test_snapshots/TestJumpMode.test_click_switch.svg index edf831c0..b805c28a 100644 --- a/tests/__snapshots__/test_snapshots/TestJumpMode.test_click_switch.svg +++ b/tests/__snapshots__/test_snapshots/TestJumpMode.test_click_switch.svg @@ -19,167 +19,167 @@ font-weight: 700; } - .terminal-3341743032-matrix { + .terminal-54336171-matrix { font-family: Fira Code, monospace; font-size: 20px; line-height: 24.4px; font-variant-east-asian: full-width; } - .terminal-3341743032-title { + .terminal-54336171-title { font-size: 18px; font-weight: bold; font-family: arial; } - .terminal-3341743032-r1 { fill: #dfdfe1 } -.terminal-3341743032-r2 { fill: #c5c8c6 } -.terminal-3341743032-r3 { fill: #ff93dd } -.terminal-3341743032-r4 { fill: #15111e;text-decoration: underline; } -.terminal-3341743032-r5 { fill: #15111e } -.terminal-3341743032-r6 { fill: #43365c } -.terminal-3341743032-r7 { fill: #737387 } -.terminal-3341743032-r8 { fill: #e1e1e6 } -.terminal-3341743032-r9 { fill: #efe3fb } -.terminal-3341743032-r10 { fill: #9f9fa5 } -.terminal-3341743032-r11 { fill: #632e53 } -.terminal-3341743032-r12 { fill: #ff69b4 } -.terminal-3341743032-r13 { fill: #dfdfe1;font-weight: bold } -.terminal-3341743032-r14 { fill: #e3e3e8;font-weight: bold } -.terminal-3341743032-r15 { fill: #0f0f1f } -.terminal-3341743032-r16 { fill: #6a6a74 } -.terminal-3341743032-r17 { fill: #0ea5e9 } -.terminal-3341743032-r18 { fill: #873c69 } -.terminal-3341743032-r19 { fill: #22c55e } -.terminal-3341743032-r20 { fill: #30303b } -.terminal-3341743032-r21 { fill: #00fa9a;font-weight: bold } -.terminal-3341743032-r22 { fill: #8b8b93 } -.terminal-3341743032-r23 { fill: #8b8b93;font-weight: bold } -.terminal-3341743032-r24 { fill: #0d0e2e } -.terminal-3341743032-r25 { fill: #00b85f } -.terminal-3341743032-r26 { fill: #ef4444 } -.terminal-3341743032-r27 { fill: #2e2e3c;font-weight: bold } -.terminal-3341743032-r28 { fill: #2e2e3c } -.terminal-3341743032-r29 { fill: #a0a0a6 } -.terminal-3341743032-r30 { fill: #191928 } -.terminal-3341743032-r31 { fill: #b74e87 } -.terminal-3341743032-r32 { fill: #87878f } -.terminal-3341743032-r33 { fill: #a3a3a9 } -.terminal-3341743032-r34 { fill: #777780 } -.terminal-3341743032-r35 { fill: #1f1f2d } -.terminal-3341743032-r36 { fill: #04b375;font-weight: bold } -.terminal-3341743032-r37 { fill: #ff7ec8;font-weight: bold } -.terminal-3341743032-r38 { fill: #dbdbdd } + .terminal-54336171-r1 { fill: #dfdfe1 } +.terminal-54336171-r2 { fill: #c5c8c6 } +.terminal-54336171-r3 { fill: #ff93dd } +.terminal-54336171-r4 { fill: #15111e;text-decoration: underline; } +.terminal-54336171-r5 { fill: #15111e } +.terminal-54336171-r6 { fill: #43365c } +.terminal-54336171-r7 { fill: #737387 } +.terminal-54336171-r8 { fill: #e1e1e6 } +.terminal-54336171-r9 { fill: #efe3fb } +.terminal-54336171-r10 { fill: #9f9fa5 } +.terminal-54336171-r11 { fill: #632e53 } +.terminal-54336171-r12 { fill: #ff69b4 } +.terminal-54336171-r13 { fill: #dfdfe1;font-weight: bold } +.terminal-54336171-r14 { fill: #e3e3e8;font-weight: bold } +.terminal-54336171-r15 { fill: #0f0f1f } +.terminal-54336171-r16 { fill: #6a6a74 } +.terminal-54336171-r17 { fill: #0ea5e9 } +.terminal-54336171-r18 { fill: #873c69 } +.terminal-54336171-r19 { fill: #22c55e } +.terminal-54336171-r20 { fill: #30303b } +.terminal-54336171-r21 { fill: #00fa9a;font-weight: bold } +.terminal-54336171-r22 { fill: #8b8b93 } +.terminal-54336171-r23 { fill: #8b8b93;font-weight: bold } +.terminal-54336171-r24 { fill: #0d0e2e } +.terminal-54336171-r25 { fill: #00b85f } +.terminal-54336171-r26 { fill: #ef4444 } +.terminal-54336171-r27 { fill: #2e2e3c;font-weight: bold } +.terminal-54336171-r28 { fill: #2e2e3c } +.terminal-54336171-r29 { fill: #a0a0a6 } +.terminal-54336171-r30 { fill: #191928 } +.terminal-54336171-r31 { fill: #b74e87 } +.terminal-54336171-r32 { fill: #87878f } +.terminal-54336171-r33 { fill: #a3a3a9 } +.terminal-54336171-r34 { fill: #777780 } +.terminal-54336171-r35 { fill: #1f1f2d } +.terminal-54336171-r36 { fill: #04b375;font-weight: bold } +.terminal-54336171-r37 { fill: #ff7ec8;font-weight: bold } +.terminal-54336171-r38 { fill: #dbdbdd } - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Posting + Posting - - - - -Posting                                                                    - -GETEnter a URL... Send  - -╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ - GET echoadersBodyQueryAuthInfoScriptsOptions -GET get random user━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━ -POS echo postX Follow redirects -▼ jsonplaceholder/ -▼ posts/X Verify SSL certificates -GET get all -GET get one╰─────────────────────────────────────────────────╯ -POS create│╭────────────────────────────────────── Response ─╮ -DEL delete a post││BodyHeadersCookiesScriptsTrace -│───────────────────────││━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -This is an echo ││ -server we can use to ││ -see exactly what ││ -request is being ││ -sent.││1:1read-onlyJSONWrap X -╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ - ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help + + + + +Posting                                                                    + +GETEnter a URL... Send  + +╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ + GET echoadersBodyQueryAuthInfoScriptsOptions +GET get random user━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━ +POS echo postX Follow redirects +▼ jsonplaceholder/X Verify SSL certificates +▼ posts/X Attach cookies +GET get allProxy URL:                                    +GET get one╰─────────────────────────────────────────────────╯ +POS create│╭────────────────────────────────────── Response ─╮ +DEL delete a post││BodyHeadersCookiesScriptsTrace +│───────────────────────││━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ +This is an echo ││ +server we can use to ││ +see exactly what ││ +request is being ││ +sent.││1:1read-onlyJSONWrap X +╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ + ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help diff --git a/tests/__snapshots__/test_snapshots/TestLoadingRequest.test_request_loaded_into_view__options.svg b/tests/__snapshots__/test_snapshots/TestLoadingRequest.test_request_loaded_into_view__options.svg index 7fb06380..ab194dc6 100644 --- a/tests/__snapshots__/test_snapshots/TestLoadingRequest.test_request_loaded_into_view__options.svg +++ b/tests/__snapshots__/test_snapshots/TestLoadingRequest.test_request_loaded_into_view__options.svg @@ -19,248 +19,248 @@ font-weight: 700; } - .terminal-3129341904-matrix { + .terminal-3604297493-matrix { font-family: Fira Code, monospace; font-size: 20px; line-height: 24.4px; font-variant-east-asian: full-width; } - .terminal-3129341904-title { + .terminal-3604297493-title { font-size: 18px; font-weight: bold; font-family: arial; } - .terminal-3129341904-r1 { fill: #dfdfe1 } -.terminal-3129341904-r2 { fill: #c5c8c6 } -.terminal-3129341904-r3 { fill: #ff93dd } -.terminal-3129341904-r4 { fill: #15111e;text-decoration: underline; } -.terminal-3129341904-r5 { fill: #15111e } -.terminal-3129341904-r6 { fill: #43365c } -.terminal-3129341904-r7 { fill: #ff69b4 } -.terminal-3129341904-r8 { fill: #9393a3 } -.terminal-3129341904-r9 { fill: #a684e8 } -.terminal-3129341904-r10 { fill: #e1e1e6 } -.terminal-3129341904-r11 { fill: #efe3fb } -.terminal-3129341904-r12 { fill: #9f9fa5 } -.terminal-3129341904-r13 { fill: #632e53 } -.terminal-3129341904-r14 { fill: #dfdfe1;font-weight: bold } -.terminal-3129341904-r15 { fill: #0ea5e9 } -.terminal-3129341904-r16 { fill: #6a6a74 } -.terminal-3129341904-r17 { fill: #58d1eb;font-weight: bold } -.terminal-3129341904-r18 { fill: #873c69 } -.terminal-3129341904-r19 { fill: #e3e3e8;font-weight: bold } -.terminal-3129341904-r20 { fill: #30303b } -.terminal-3129341904-r21 { fill: #00fa9a;font-weight: bold } -.terminal-3129341904-r22 { fill: #8b8b93 } -.terminal-3129341904-r23 { fill: #8b8b93;font-weight: bold } -.terminal-3129341904-r24 { fill: #00b85f } -.terminal-3129341904-r25 { fill: #22c55e } -.terminal-3129341904-r26 { fill: #ef4444 } -.terminal-3129341904-r27 { fill: #f59e0b } -.terminal-3129341904-r28 { fill: #2e2e3c;font-weight: bold } -.terminal-3129341904-r29 { fill: #2e2e3c } -.terminal-3129341904-r30 { fill: #a0a0a6 } -.terminal-3129341904-r31 { fill: #191928 } -.terminal-3129341904-r32 { fill: #b74e87 } -.terminal-3129341904-r33 { fill: #87878f } -.terminal-3129341904-r34 { fill: #a3a3a9 } -.terminal-3129341904-r35 { fill: #777780 } -.terminal-3129341904-r36 { fill: #1f1f2d } -.terminal-3129341904-r37 { fill: #04b375;font-weight: bold } -.terminal-3129341904-r38 { fill: #ff7ec8;font-weight: bold } -.terminal-3129341904-r39 { fill: #dbdbdd } + .terminal-3604297493-r1 { fill: #dfdfe1 } +.terminal-3604297493-r2 { fill: #c5c8c6 } +.terminal-3604297493-r3 { fill: #ff93dd } +.terminal-3604297493-r4 { fill: #15111e;text-decoration: underline; } +.terminal-3604297493-r5 { fill: #15111e } +.terminal-3604297493-r6 { fill: #43365c } +.terminal-3604297493-r7 { fill: #ff69b4 } +.terminal-3604297493-r8 { fill: #9393a3 } +.terminal-3604297493-r9 { fill: #a684e8 } +.terminal-3604297493-r10 { fill: #e1e1e6 } +.terminal-3604297493-r11 { fill: #efe3fb } +.terminal-3604297493-r12 { fill: #9f9fa5 } +.terminal-3604297493-r13 { fill: #632e53 } +.terminal-3604297493-r14 { fill: #dfdfe1;font-weight: bold } +.terminal-3604297493-r15 { fill: #0ea5e9 } +.terminal-3604297493-r16 { fill: #6a6a74 } +.terminal-3604297493-r17 { fill: #58d1eb;font-weight: bold } +.terminal-3604297493-r18 { fill: #873c69 } +.terminal-3604297493-r19 { fill: #e3e3e8;font-weight: bold } +.terminal-3604297493-r20 { fill: #30303b } +.terminal-3604297493-r21 { fill: #00fa9a;font-weight: bold } +.terminal-3604297493-r22 { fill: #8b8b93 } +.terminal-3604297493-r23 { fill: #8b8b93;font-weight: bold } +.terminal-3604297493-r24 { fill: #00b85f } +.terminal-3604297493-r25 { fill: #22c55e } +.terminal-3604297493-r26 { fill: #ef4444 } +.terminal-3604297493-r27 { fill: #f59e0b } +.terminal-3604297493-r28 { fill: #2e2e3c;font-weight: bold } +.terminal-3604297493-r29 { fill: #2e2e3c } +.terminal-3604297493-r30 { fill: #a0a0a6 } +.terminal-3604297493-r31 { fill: #191928 } +.terminal-3604297493-r32 { fill: #b74e87 } +.terminal-3604297493-r33 { fill: #87878f } +.terminal-3604297493-r34 { fill: #a3a3a9 } +.terminal-3604297493-r35 { fill: #777780 } +.terminal-3604297493-r36 { fill: #1f1f2d } +.terminal-3604297493-r37 { fill: #04b375;font-weight: bold } +.terminal-3604297493-r38 { fill: #ff7ec8;font-weight: bold } +.terminal-3604297493-r39 { fill: #dbdbdd } - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Posting + Posting - - - - -Posting                                                                    - -POSThttps://postman-echo.com/post                       Send  - -╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ -GET echorsBodyQueryAuthInfoScriptsOptions -GET get random user━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━ -█ POS echo postX Follow redirects -▼ jsonplaceholder/ -▼ posts/X Verify SSL certificates -GET get all -GET get oneX Attach cookies -POS create -DEL delete a postProxy URL                                      -▼ comments/ -GET get comments -GET get commentsTimeout                                        -PUT edit a comme0.2                                      -▼ todos/ -GET get all -GET get one -▼ users/╰─────────────────────────────────────────────────╯ -GET get a user│╭────────────────────────────────────── Response ─╮ -GET get all users││BodyHeadersCookiesScriptsTrace -POS create a user││━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -PUT update a user││ -DEL delete a user││ -││ -││ -││ -││ -││ -││ -││ -││ -││ -││ -│───────────────────────││ -Echo server for post ││ -requests.││1:1read-onlyJSONWrap X -╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ - ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help + + + + +Posting                                                                    + +POSThttps://postman-echo.com/post                       Send  + +╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ +GET echorsBodyQueryAuthInfoScriptsOptions +GET get random user━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━ +█ POS echo postX Follow redirects +▼ jsonplaceholder/X Verify SSL certificates +▼ posts/X Attach cookies +GET get allProxy URL:                                     +GET get one +POS createTimeout:                                       +DEL delete a post0.2                                          +▼ comments/ +GET get comments +GET get comments +PUT edit a comme +▼ todos/ +GET get all +GET get one +▼ users/╰─────────────────────────────────────────────────╯ +GET get a user│╭────────────────────────────────────── Response ─╮ +GET get all users││BodyHeadersCookiesScriptsTrace +POS create a user││━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ +PUT update a user││ +DEL delete a user││ +││ +││ +││ +││ +││ +││ +││ +││ +││ +││ +│───────────────────────││ +Echo server for post ││ +requests.││1:1read-onlyJSONWrap X +╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ + ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help diff --git a/tests/__snapshots__/test_snapshots/TestNewRequest.test_new_request_added_to_tree_correctly_and_notification_shown.svg b/tests/__snapshots__/test_snapshots/TestNewRequest.test_new_request_added_to_tree_correctly_and_notification_shown.svg index 7386178e..8ef6854a 100644 --- a/tests/__snapshots__/test_snapshots/TestNewRequest.test_new_request_added_to_tree_correctly_and_notification_shown.svg +++ b/tests/__snapshots__/test_snapshots/TestNewRequest.test_new_request_added_to_tree_correctly_and_notification_shown.svg @@ -19,165 +19,165 @@ font-weight: 700; } - .terminal-4182121337-matrix { + .terminal-2975144355-matrix { font-family: Fira Code, monospace; font-size: 20px; line-height: 24.4px; font-variant-east-asian: full-width; } - .terminal-4182121337-title { + .terminal-2975144355-title { font-size: 18px; font-weight: bold; font-family: arial; } - .terminal-4182121337-r1 { fill: #dfdfe1 } -.terminal-4182121337-r2 { fill: #c5c8c6 } -.terminal-4182121337-r3 { fill: #ff93dd } -.terminal-4182121337-r4 { fill: #15111e;text-decoration: underline; } -.terminal-4182121337-r5 { fill: #15111e } -.terminal-4182121337-r6 { fill: #43365c } -.terminal-4182121337-r7 { fill: #737387 } -.terminal-4182121337-r8 { fill: #e1e1e6 } -.terminal-4182121337-r9 { fill: #efe3fb } -.terminal-4182121337-r10 { fill: #9f9fa5 } -.terminal-4182121337-r11 { fill: #ff69b4 } -.terminal-4182121337-r12 { fill: #dfdfe1;font-weight: bold } -.terminal-4182121337-r13 { fill: #632e53 } -.terminal-4182121337-r14 { fill: #0ea5e9 } -.terminal-4182121337-r15 { fill: #0f0f1f } -.terminal-4182121337-r16 { fill: #6a6a74 } -.terminal-4182121337-r17 { fill: #252532 } -.terminal-4182121337-r18 { fill: #22c55e } -.terminal-4182121337-r19 { fill: #252441 } -.terminal-4182121337-r20 { fill: #8b8b93 } -.terminal-4182121337-r21 { fill: #8b8b93;font-weight: bold } -.terminal-4182121337-r22 { fill: #00b85f } -.terminal-4182121337-r23 { fill: #210d17;font-weight: bold } -.terminal-4182121337-r24 { fill: #918d9d } -.terminal-4182121337-r25 { fill: #0d0e2e } -.terminal-4182121337-r26 { fill: #2e2e3c;font-weight: bold } -.terminal-4182121337-r27 { fill: #2e2e3c } -.terminal-4182121337-r28 { fill: #a0a0a6 } -.terminal-4182121337-r29 { fill: #ef4444 } -.terminal-4182121337-r30 { fill: #191928 } -.terminal-4182121337-r31 { fill: #b74e87 } -.terminal-4182121337-r32 { fill: #0cfa9f } -.terminal-4182121337-r33 { fill: #0ce48c;font-weight: bold } -.terminal-4182121337-r34 { fill: #e3e3e6 } -.terminal-4182121337-r35 { fill: #ff7ec8;font-weight: bold } -.terminal-4182121337-r36 { fill: #dbdbdd } + .terminal-2975144355-r1 { fill: #dfdfe1 } +.terminal-2975144355-r2 { fill: #c5c8c6 } +.terminal-2975144355-r3 { fill: #ff93dd } +.terminal-2975144355-r4 { fill: #15111e;text-decoration: underline; } +.terminal-2975144355-r5 { fill: #15111e } +.terminal-2975144355-r6 { fill: #43365c } +.terminal-2975144355-r7 { fill: #737387 } +.terminal-2975144355-r8 { fill: #e1e1e6 } +.terminal-2975144355-r9 { fill: #efe3fb } +.terminal-2975144355-r10 { fill: #9f9fa5 } +.terminal-2975144355-r11 { fill: #ff69b4 } +.terminal-2975144355-r12 { fill: #dfdfe1;font-weight: bold } +.terminal-2975144355-r13 { fill: #632e53 } +.terminal-2975144355-r14 { fill: #0ea5e9 } +.terminal-2975144355-r15 { fill: #0f0f1f } +.terminal-2975144355-r16 { fill: #6a6a74 } +.terminal-2975144355-r17 { fill: #252532 } +.terminal-2975144355-r18 { fill: #22c55e } +.terminal-2975144355-r19 { fill: #252441 } +.terminal-2975144355-r20 { fill: #8b8b93 } +.terminal-2975144355-r21 { fill: #8b8b93;font-weight: bold } +.terminal-2975144355-r22 { fill: #00b85f } +.terminal-2975144355-r23 { fill: #210d17;font-weight: bold } +.terminal-2975144355-r24 { fill: #918d9d } +.terminal-2975144355-r25 { fill: #0d0e2e } +.terminal-2975144355-r26 { fill: #2e2e3c;font-weight: bold } +.terminal-2975144355-r27 { fill: #2e2e3c } +.terminal-2975144355-r28 { fill: #a0a0a6 } +.terminal-2975144355-r29 { fill: #ef4444 } +.terminal-2975144355-r30 { fill: #191928 } +.terminal-2975144355-r31 { fill: #b74e87 } +.terminal-2975144355-r32 { fill: #0cfa9f } +.terminal-2975144355-r33 { fill: #0ce48c;font-weight: bold } +.terminal-2975144355-r34 { fill: #e3e3e6 } +.terminal-2975144355-r35 { fill: #ff7ec8;font-weight: bold } +.terminal-2975144355-r36 { fill: #dbdbdd } - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Posting + Posting - - - - -Posting                                                                    - -GETEnter a URL... Send  - -╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ -GET echoHeadersBodyQueryAuthInfoScriptsOptio -GET get random user━━━━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -POS echo post╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ -▼ jsonplaceholder/╱╱╱╱╱╱╱╱╱╱╱╱╱╱There are no headers.╱╱╱╱╱╱╱╱╱╱╱╱╱╱ -▼ posts/╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ -█ GET fooNameValue Add header  -GET get all╰─────────────────────────────────────────────────╯ -GET get one╭────────────────────────────────────── Response ─╮ -POS createBodyHeadersCookiesScriptsTrace -DEL delete a post━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -▼ comments/ -GET get comment -GET get comment -───────────────────────Request saved -barjsonplaceholder/posts/foo.posting.ya -╰── sample-collections ─╯╰────────────ml - d Dupe  ⌫ Delete  ^j Send  ^t Method  + + + + +Posting                                                                    + +GETEnter a URL... Send  + +╭─ Collection ──────────╮╭─────────────────────────────────────── Request ─╮ +GET echoHeadersBodyQueryAuthInfoScriptsOptio +GET get random user━━━━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ +POS echo post╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ +▼ jsonplaceholder/╱╱╱╱╱╱╱╱╱╱╱╱╱╱There are no headers.╱╱╱╱╱╱╱╱╱╱╱╱╱╱ +▼ posts/╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱ +█ GET fooNameValue Add header  +GET get all╰─────────────────────────────────────────────────╯ +GET get one╭────────────────────────────────────── Response ─╮ +POS createBodyHeadersCookiesScriptsTrace +DEL delete a post━━━━╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ +▼ comments/ +GET get comment +GET get comment +───────────────────────Request saved +barjsonplaceholder/posts/foo.posting.ya +╰── sample-collections ─╯╰───────────ml + d Dupe  ⌫ Delete  ^j Send  ^t Method diff --git a/tests/__snapshots__/test_snapshots/TestScripts.test_script_runs.svg b/tests/__snapshots__/test_snapshots/TestScripts.test_script_runs.svg index 5bb54f21..5cb2ed7c 100644 --- a/tests/__snapshots__/test_snapshots/TestScripts.test_script_runs.svg +++ b/tests/__snapshots__/test_snapshots/TestScripts.test_script_runs.svg @@ -19,206 +19,207 @@ font-weight: 700; } - .terminal-3563060270-matrix { + .terminal-2287657932-matrix { font-family: Fira Code, monospace; font-size: 20px; line-height: 24.4px; font-variant-east-asian: full-width; } - .terminal-3563060270-title { + .terminal-2287657932-title { font-size: 18px; font-weight: bold; font-family: arial; } - .terminal-3563060270-r1 { fill: #dfdfe1 } -.terminal-3563060270-r2 { fill: #c5c8c6 } -.terminal-3563060270-r3 { fill: #ff93dd } -.terminal-3563060270-r4 { fill: #15111e;text-decoration: underline; } -.terminal-3563060270-r5 { fill: #15111e } -.terminal-3563060270-r6 { fill: #43365c } -.terminal-3563060270-r7 { fill: #ff69b4 } -.terminal-3563060270-r8 { fill: #9393a3 } -.terminal-3563060270-r9 { fill: #a684e8 } -.terminal-3563060270-r10 { fill: #e1e1e6 } -.terminal-3563060270-r11 { fill: #00fa9a } -.terminal-3563060270-r12 { fill: #efe3fb } -.terminal-3563060270-r13 { fill: #9f9fa5 } -.terminal-3563060270-r14 { fill: #632e53 } -.terminal-3563060270-r15 { fill: #dfdfe1;font-weight: bold } -.terminal-3563060270-r16 { fill: #002014;font-weight: bold } -.terminal-3563060270-r17 { fill: #e3e3e8;font-weight: bold } -.terminal-3563060270-r18 { fill: #0f0f1f } -.terminal-3563060270-r19 { fill: #6a6a74 } -.terminal-3563060270-r20 { fill: #0ea5e9 } -.terminal-3563060270-r21 { fill: #873c69 } -.terminal-3563060270-r22 { fill: #22c55e } -.terminal-3563060270-r23 { fill: #8b8b93 } -.terminal-3563060270-r24 { fill: #8b8b93;font-weight: bold } -.terminal-3563060270-r25 { fill: #00b85f } -.terminal-3563060270-r26 { fill: #9393a3;font-weight: bold } -.terminal-3563060270-r27 { fill: #98e024 } -.terminal-3563060270-r28 { fill: #ef4444 } -.terminal-3563060270-r29 { fill: #f4005f } -.terminal-3563060270-r30 { fill: #fd971f } -.terminal-3563060270-r31 { fill: #f59e0b } -.terminal-3563060270-r32 { fill: #58d1eb;font-weight: bold } -.terminal-3563060270-r33 { fill: #0d0e2e } -.terminal-3563060270-r34 { fill: #1e1e3f } -.terminal-3563060270-r35 { fill: #552956 } -.terminal-3563060270-r36 { fill: #ff7ec8;font-weight: bold } -.terminal-3563060270-r37 { fill: #dbdbdd } + .terminal-2287657932-r1 { fill: #dfdfe1 } +.terminal-2287657932-r2 { fill: #c5c8c6 } +.terminal-2287657932-r3 { fill: #ff93dd } +.terminal-2287657932-r4 { fill: #15111e;text-decoration: underline; } +.terminal-2287657932-r5 { fill: #15111e } +.terminal-2287657932-r6 { fill: #43365c } +.terminal-2287657932-r7 { fill: #ff69b4 } +.terminal-2287657932-r8 { fill: #9393a3 } +.terminal-2287657932-r9 { fill: #a684e8 } +.terminal-2287657932-r10 { fill: #e1e1e6 } +.terminal-2287657932-r11 { fill: #00fa9a } +.terminal-2287657932-r12 { fill: #efe3fb } +.terminal-2287657932-r13 { fill: #9f9fa5 } +.terminal-2287657932-r14 { fill: #632e53 } +.terminal-2287657932-r15 { fill: #dfdfe1;font-weight: bold } +.terminal-2287657932-r16 { fill: #002014;font-weight: bold } +.terminal-2287657932-r17 { fill: #e3e3e8;font-weight: bold } +.terminal-2287657932-r18 { fill: #0f0f1f } +.terminal-2287657932-r19 { fill: #6a6a74 } +.terminal-2287657932-r20 { fill: #0ea5e9 } +.terminal-2287657932-r21 { fill: #873c69 } +.terminal-2287657932-r22 { fill: #22c55e } +.terminal-2287657932-r23 { fill: #8b8b93 } +.terminal-2287657932-r24 { fill: #8b8b93;font-weight: bold } +.terminal-2287657932-r25 { fill: #00b85f } +.terminal-2287657932-r26 { fill: #8f8f9b;font-weight: bold } +.terminal-2287657932-r27 { fill: #e0e0e3 } +.terminal-2287657932-r28 { fill: #98e024 } +.terminal-2287657932-r29 { fill: #ef4444 } +.terminal-2287657932-r30 { fill: #f4005f } +.terminal-2287657932-r31 { fill: #fd971f } +.terminal-2287657932-r32 { fill: #f59e0b } +.terminal-2287657932-r33 { fill: #58d1eb;font-weight: bold } +.terminal-2287657932-r34 { fill: #0d0e2e } +.terminal-2287657932-r35 { fill: #16162f } +.terminal-2287657932-r36 { fill: #552956 } +.terminal-2287657932-r37 { fill: #ff7ec8;font-weight: bold } +.terminal-2287657932-r38 { fill: #dbdbdd } - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Posting + Posting - - - - -Posting                                                                    - -GEThttps://postman-echo.com/get              ■■■■■■■ Send  - -╭─ Collection ──────────╮╭───────────────────────────── Response  200 OK ─╮ -█ GET echoBodyHeadersCookiesScriptsTrace -GET get random user━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━╺━━━━━━━━━━━━━━━━ -POS echo postSetup          Pre-request    Post-response   -▼ jsonplaceholder/SuccessSuccessSuccess -▼ posts/ -GET get allScript output                                 -GET get oneRunning my_script.py:setup -POS createout Hello from my_script.py:setup!         -DEL delete a posterr error from setup!                      -▼ comments/Running my_script.py:on_request -GET get commentout Set header:                            -GET get commentoutname='X-Custom-Header'value='Foo-Bar- -PUT edit a commerr Hello from my_script.py:on_request - i -▼ todos/Running my_script.py:on_response -GET get allout200 -GET get oneout foo                                    -▼ users/out Hello from my_script.py!               -GET get a usererr Hello from my_script.py:on_response -  -GET get all users -│───────────────────────│ -This is an echo  -server we can use to  -see exactly what  -request is being  -sent. -╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ - ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help + + + + +Posting                                                                    + +GEThttps://postman-echo.com/get              ■■■■■■■ Send  + +╭─ Collection ──────────╮╭───────────────────────────── Response  200 OK ─╮ +█ GET echoBodyHeadersCookiesScriptsTrace +GET get random user━━━━━━━━━━━━━━━━━━━━━━━━╸━━━━━━━╺━━━━━━━━━━━━━━━━ +POS echo postSetup          Pre-request    Post-response   +▼ jsonplaceholder/SuccessSuccessSuccess +▼ posts/ +GET get allScript output                                 +GET get oneRunning my_script.py:setup +POS createout Hello from my_script.py:setup!         +DEL delete a posterr error from setup!                      +▼ comments/Running my_script.py:on_request +GET get commentout Set header:                            +GET get commentoutname='X-Custom-Header'value='Foo-Bar- +PUT edit a commerr Hello from my_script.py:on_request - i +▼ todos/Running my_script.py:on_response +GET get allout200 +GET get oneout foo                                    +▼ users/out Hello from my_script.py!               +GET get a usererr Hello from my_script.py:on_response -  +GET get all users +│───────────────────────│ +This is an echo  +server we can use to  +see exactly what  +request is being  +sent. +╰── sample-collections ─╯╰─────────────────────────────────────────────────╯ + ^j Send  ^t Method  ^s Save  ^n New  ^p Commands  ^o Jump  ^c Quit  f1 Help