1 | <?php |
||
18 | class ResizableColumnsBehavior extends Behavior implements RegistersClientScriptInterface |
||
19 | { |
||
20 | /** |
||
21 | * @var array $clientOptions the options for the underlying resizable jquery plugin. Sets by default the store |
||
22 | * option. These are the options available and its defaults (translated from its js code): |
||
23 | * |
||
24 | * ``` |
||
25 | * [ |
||
26 | * 'selector' => new JsExpression('function selector($table) {... see js code ...}'), |
||
27 | * 'store' => new JsExpression('window.store'), |
||
28 | * 'syncHandlers' => true, |
||
29 | * 'resizeFromBody' => true, |
||
30 | * 'maxWidth' => new JsExpression('null'), |
||
31 | * 'minWidth' => 0.01 |
||
32 | * ] |
||
33 | * ``` |
||
34 | * |
||
35 | * It also has the options for you to configure the callback functions when triggering events. The events are: |
||
36 | * |
||
37 | * - start: When plugin starts resizing |
||
38 | * - resize: When plugin is resizing |
||
39 | * - stop: When plugin ends resizing |
||
40 | * |
||
41 | * To configure do: |
||
42 | * |
||
43 | * ``` |
||
44 | * [ |
||
45 | * 'start' => new JsExpression('function(){ console.log("resizing...");}') |
||
46 | * ] |
||
47 | */ |
||
48 | public $clientOptions = []; |
||
49 | |||
50 | /** |
||
51 | * @inheritdoc |
||
52 | */ |
||
53 | public function registerClientScript() |
||
69 | } |
||
70 |