Skip to content
Snippets Groups Projects
  1. Sep 20, 2017
    • aschmitz's avatar
      Change IDs to strings rather than numbers in API JSON output (#5019) · 669fe9ee
      aschmitz authored
      * Fix JavaScript interface with long IDs
      
      Somewhat predictably, the JS interface handled IDs as numbers, which in
      JS are IEEE double-precision floats. This loses some precision when
      working with numbers as large as those generated by the new ID scheme,
      so we instead handle them here as strings. This is relatively simple,
      and doesn't appear to have caused any problems, but should definitely
      be tested more thoroughly than the built-in tests. Several days of use
      appear to support this working properly.
      
      BREAKING CHANGE:
      
      The major(!) change here is that IDs are now returned as strings by the
      REST endpoints, rather than as integers. In practice, relatively few
      changes were required to make the existing JS UI work with this change,
      but it will likely hit API clients pretty hard: it's an entirely
      different type to consume. (The one API client I tested, Tusky, handles
      this with no problems, however.)
      
      Twitter ran into this issue when introducing Snowflake IDs, and decided
      to instead introduce an `id_str` field in JSON responses. I have opted
      to *not* do that, and instead force all IDs to 64-bit integers
      represented by strings in one go. (I believe Twitter exacerbated their
      problem by rolling out the changes three times: once for statuses, once
      for DMs, and once for user IDs, as well as by leaving an integer ID
      value in JSON. As they said, "If you’re using the `id` field with JSON
      in a Javascript-related language, there is a very high likelihood that
      the integers will be silently munged by Javascript interpreters. In most
      cases, this will result in behavior such as being unable to load or
      delete a specific direct message, because the ID you're sending to the
      API is different than the actual identifier associated with the
      message." [1]) However, given that this is a significant change for API
      users, alternatives or a transition time may be appropriate.
      
      1: https://blog.twitter.com/developer/en_us/a/2011/direct-messages-going-snowflake-on-sep-30-2011.html
      
      * Additional fixes for stringified IDs in JSON
      
      These should be the last two. These were identified using eslint to try
      to identify any plain casts to JavaScript numbers. (Some such casts are
      legitimate, but these were not.)
      
      Adding the following to .eslintrc.yml will identify casts to numbers:
      
      ~~~
        no-restricted-syntax:
        - warn
        - selector: UnaryExpression[operator='+'] > :not(Literal)
          message: Avoid the use of unary +
        - selector: CallExpression[callee.name='Number']
          message: Casting with Number() may coerce string IDs to numbers
      ~~~
      
      The remaining three casts appear legitimate: two casts to array indices,
      one in a server to turn an environment variable into a number.
      
      * Back out RelationshipsController Change
      
      This was made to make a test a bit less flakey, but has nothing to
      do with this branch.
      
      * Change internal streaming payloads to stringified IDs as well
      
      Per
      https://github.com/tootsuite/mastodon/pull/5019#issuecomment-330736452
      we need these changes to send deleted status IDs as strings, not
      integers.
      669fe9ee
  2. Sep 16, 2017
  3. Sep 15, 2017
    • unarist's avatar
      Fix invisible load more button (#4962) · 6c81f9d6
      unarist authored
      * Fix behavior while the button is invisible
      e.g. pointer cursor, couldn't open contextmenu
      * Avoid rendering the button to remove blank space if no more items are available or no items are rendered
      6c81f9d6
  4. Sep 14, 2017
    • Eugen Rochko's avatar
      Redesign video player (#4911) · 2bbf987a
      Eugen Rochko authored
      * Redesign video player
      
      * Use new video player on static public pages too
      
      * Use media gallery component on static public pages too
      
      * Pause video when hiding it
      
      * Full-screen sizing on WebKit
      
      * Add aria labels to video player buttons
      
      * Display link card on public status page
      
      * Fix fullscreen from modal sizing issue
      
      * Remove contain: strict property to fix fullscreen from columns
      2bbf987a
  5. Sep 13, 2017
  6. Sep 09, 2017
  7. Sep 08, 2017
  8. Sep 07, 2017
  9. Sep 06, 2017
  10. Sep 02, 2017
  11. Sep 01, 2017
  12. Aug 31, 2017
  13. Aug 28, 2017
  14. Aug 24, 2017
  15. Aug 07, 2017
  16. Aug 04, 2017
  17. Aug 02, 2017
  18. Jul 30, 2017
    • Sorin Davidoi's avatar
      Improve accessibility (part 7) (#4457) · e44f03bc
      Sorin Davidoi authored
      * fix(media_modal): Keyboard navigation
      
      * fix(column_back_button): Use native button
      
      * fix(media_gallery): Keyboard navigation
      
      * fix(status_content): Make CW content focusable
      e44f03bc
  19. Jul 29, 2017
  20. Jul 28, 2017
    • Sorin Davidoi's avatar
      Improve accessibility (part 6) (#4435) · c71874b8
      Sorin Davidoi authored
      * fix(status_action_bar): Use aria-pressed for reblog and favourite button
      
      * fix(column_back_button): Keyboard accessible
      
      * fix(status_content): Make focusable and accessible
      
      * fix(dropdown_menu): Use aria-expanded instead of aria-pressed
      
      * fix(emoji_picker_dropdown): Use aria-expanded instead of aria-hidden
      
      * feat(icon_button): Add aria-expanded
      
      * fix(privacy_dropdown): Use aria-expanded instead of aria-hidden
      c71874b8
    • Sorin Davidoi's avatar
      Accessability fixes (#4432) · 634b71ed
      Sorin Davidoi authored
      * fix(modal_root): Read type from props, not from component
      
      * fix(status_list): Do not user event.path
      634b71ed
    • Sorin Davidoi's avatar
      Improve accessibility (part 5) (#4417) · 534da4f2
      Sorin Davidoi authored
      * fix(status): Add tabIndex=0
      
      * fix(status_list): Make keyboard navigable
      534da4f2
    • Yamagishi Kazutoshi's avatar
      Fix broken PropTypes (#4413) · 58eea598
      Yamagishi Kazutoshi authored
      58eea598
    • Sorin Davidoi's avatar
      Improve accessibility (part 4) (#4408) · b7d47c2a
      Sorin Davidoi authored
      * fix(dropdown_menu): Keyboard navigation
      
      * fix(icon_button): Add aria-pressed attribute
      
      * fix(privacy_dropdown): Make accessible
      
      * fix(emoji_picker_dropdown): Make accessible
      
      * fix(icon_button): Support tabIndex
      
      * fix(actions_modal): Remove icon from tab order
      
      * fix(dropdown_menu): Add role=group
      
      * fix(setting_toggle): Toggle via space key
      
      * fix(dropdown_menu): Remove redundant handling of Space key
      
      * fix(emoji_picker_dropdown): Remove redundant Space key handling
      
      * fix(privacy_dropdown): Remove redundant Space key handling
      
      * fix(status): Switch to article and add aria-posinset, aria-setsize
      
      * fix(status_list): Use role=feed and pass more ARIA props to Status
      
      * chore(eslint): jsx-a11y/role-supports-aria-props
      b7d47c2a
  21. Jul 27, 2017
    • Sorin Davidoi's avatar
      Improve accessibility (part 3) (#4405) · 6884dd79
      Sorin Davidoi authored
      * fix(compose): Add aria-label for the navigation links
      
      * fix(search): Add input label
      
      * fix(navigation_bar): Link description
      
      * fix(autosuggest_textarea): Add input label
      
      * fix(compose_form): Add input label
      
      * fix(upload_button): Add input label
      
      * fix(account/header): Add link content
      
      * fix(column_header): Use h1 tag
      
      * fix(column_header): Labels move buttons moving column
      
      * fix(settings_text): Add label to input
      
      * fix(column_header): Remove role from h1
      
      * fix(modal_root): Use role=dialog
      
      * fix(modal_root): Focus restauration
      
      * fix(modal_root): Apply inert to sibligs
      
      * fix(column_header): Add role=button
      
      * chore(eslint): Disable jsx-a11y/label-has-for
      6884dd79
    • Sorin Davidoi's avatar
      fix(dropdown_menu): Open as modal on mobile (#4295) · 50d38d76
      Sorin Davidoi authored
      * fix(dropdown_menu): Open as modal on mobile
      
      * fix(dropdown_menu): Open modal on touch
      
      * fix(dropdown_menu): Show status
      
      * fix(dropdown_menu): Max dimensions and reduce padding
      
      * chore(dropdown_menu): Test new functionality
      
      * refactor: Use DropdownMenuContainer instead of DropdownMenu
      
      * feat(privacy_dropdown): Open as modal on touch devices
      
      * feat(modal_root): Do not load actions-modal async
      50d38d76
    • Yamagishi Kazutoshi's avatar
  22. Jul 26, 2017
    • Eugen Rochko's avatar
      Fix infinite scroll fluidity (#4381) · 55bee84c
      Eugen Rochko authored
      55bee84c
    • Sorin Davidoi's avatar
      Improve accessibility (part 2) (#4377) · 6a6a62f1
      Sorin Davidoi authored
      * fix(column_header): Invalid ARIA role
      
      * fix(column): Remove hidden nodes from the DOM
      
      * refactor(column_link): Remove unused property hideOnMobile
      
      * fix(column_header): Use aria-pressed
      
      * fix(column_header): Make collapsed content not focusable, add focusable property
      
      * fix(column_loading): Make header non-focusable
      
      * fix(column_settings): Use role to group the toggles
      6a6a62f1
    • Sorin Davidoi's avatar
      Improve accessibility (#4369) · 2f8bfb3d
      Sorin Davidoi authored
      * fix(compose): Use nav and remove redundant aria-label
      
      * fix(tabs_tab): Use nav and add aria-label
      
      * fix(app): Add aria-label for settings toggle button
      
      * chore: Run yarn manage:translations
      2f8bfb3d
  23. Jul 25, 2017
  24. Jul 24, 2017
  25. Jul 23, 2017
  26. Jul 19, 2017
Loading