Sha256: e99e3678d5965dcb298d53a6ad86f11280d7c6efb5ded6a3f25f05a675a59679

Contents?: true

Size: 756 Bytes

Versions: 10

Compression:

Stored size: 756 Bytes

Contents

console.log("Yeah! The dashboard has started!")

MyDashboard.on 'ready', ->
  MyDashboard.widget_margins ||= [5, 5]
  MyDashboard.widget_base_dimensions ||= [300, 360]
  MyDashboard.numColumns ||= 4

  contentWidth = (MyDashboard.widget_base_dimensions[0] + MyDashboard.widget_margins[0] * 2) * MyDashboard.numColumns

  Batman.setImmediate ->
    $('.gridster').width(contentWidth)
    $('.gridster ul:first').gridster
      widget_margins: MyDashboard.widget_margins
      widget_base_dimensions: MyDashboard.widget_base_dimensions
      avoid_overlapped_widgets: !MyDashboard.customGridsterLayout
      draggable:
        stop: MyDashboard.showGridsterInstructions
        start: -> MyDashboard.currentWidgetPositions = MyDashboard.getWidgetPositions()

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
my_dashboard-0.6.0 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.10 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.9 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.8 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.7 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.6 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.5 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.4 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.3 app/assets/javascripts/my_dashboard/my_dashboard.coffee
my_dashboard-0.5.2 app/assets/javascripts/my_dashboard/my_dashboard.coffee