From b015da6bbc9c757ffc87a1cfa0c216dfd0ba9725 Mon Sep 17 00:00:00 2001 From: Rob Garrison Date: Tue, 12 Jul 2016 05:09:02 -0500 Subject: [PATCH] Docs: Add scroller widget RTL details. See #906 --- docs/example-widget-scroller.html | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/docs/example-widget-scroller.html b/docs/example-widget-scroller.html index c3094184..437dd885 100644 --- a/docs/example-widget-scroller.html +++ b/docs/example-widget-scroller.html @@ -479,6 +479,26 @@ $(function() { + +

RTL Support

+
+ Two things are required to get the fixed column properly aligned on the right side: +
    +
  1. + A class of ts-scroller-rtl must be added to the table +
    <table class="ts-scroller-rtl">...</table>
    + the reason for the weird naming ts instead of tablesorter is because with a class name of tablesorter-scroller-rtl, the code will think you're trying to add a theme named scroller-rtl. +

    If you want to change this class name, use the following code before the document ready function:

    +
    $.tablesorter.css.scrollerRtl = "ts-scroller-rtl";
    +
  2. +
  3. + Whatever element is wrapping the table needs to be set with the css direction:rtl. So if your entire page (body is set, that will work just fine. If you only want the table to be set as rtl, then set this css on the scroller's wrapper: +
    .tablesorter-scroller { direction: rtl; }
    +
  4. +
+ Here is a jsFiddle demo. +
+

CSS