Skip to content

'Tweet Feedback' window does not save its state properly on reopen #100897

Closed
@nlchar

Description

@nlchar

Issue Type: Bug

  1. Click 'Tweet Feedback' button at the right bottom corner of the Visual Studio Code window.
  2. Type some text in the text box in the appeared floating window.
  3. Current state: character counter is less than 270, 'Tweet' button is active and clickable.
  4. Close the floating window either using ESC key or by tapping the 'Close' button at the top of the window.
  5. Click 'Tweet Feedback' button again to reopen the window.
    The state is incorrectly restored:
  • The text is restored, it is in the text box as it should be.
  • The character counter is not restored and is equal to 270 characters.
  • The 'Tweet' button is not active and is not clickable.
    Any change in the text box or selection of any of the smiles will result in state update to the expected values.
    standard

Also, if you choose 'Happy Feedback Sentiment' at any point, the default value of the character counter on the window reopen would be 257, not 270 (because the 'Happy Feedback Sentiment' mode adds the '#HappyCoding' hashtag to the resulting tweet status), so the Feedback Sentiment selection state persists properly on the window reopen.
happy
Possible solution
The code responsible for the feature is located in the file. The updateCharCountText function does the job of updating the counter & the 'Tweet' button state, so its call in the window reopen function may be sufficient to resolve the issue. I think the show function is called on window reopen, so it may be used for that purpose.

VS Code version: Code 1.46.1 (cd9ea64, 2020-06-17T21:13:20.174Z)
OS version: Windows_NT x64 10.0.18363

System Info
Item Value
CPUs Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz (4 x 2712)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: enabled
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off_ok
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 7.88GB (2.95GB free)
Process Argv
Screen Reader no
VM 0%
Extensions: none

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedIssues identified as good community contribution opportunitiesinsiders-releasedPatch has been released in VS Code InsiderspolishCleanup and polish issue

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions