Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@zambezi/grid

Package Overview
Dependencies
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zambezi/grid - npm Package Compare versions

Comparing version 0.1.0 to 0.2.0

src/column-drag-target-layout.js

7

package.json
{
"name": "@zambezi/grid",
"version": "0.1.0",
"version": "0.2.0",
"description": "D3 component for drawing financial grids.",

@@ -42,6 +42,11 @@ "keywords": [

"@zambezi/fun": "^2.0.0-1",
"d3-array": "^1.0.1",
"d3-dispatch": "^1.0.1",
"d3-ease": "^1.0.1",
"d3-format": "^1.0.2",
"d3-selection": "^1.0.0",
"d3-timer": "^1.0.2",
"d3-transition": "^1.0.1",
"underscore": "^1.8.3"
}
}

@@ -0,0 +0,0 @@ Zambezi Grid

@@ -13,4 +13,8 @@ import babel from 'rollup-plugin-babel'

, '@zambezi/fun'
, 'd3-array'
, 'd3-ease'
, 'd3-format'
, 'd3-selection'
, 'd3-timer'
, 'd3-transition'
, 'underscore'

@@ -31,6 +35,10 @@ ]

, '@zambezi/fun': 'fun'
, 'd3-array': 'd3'
, 'd3-ease': 'd3'
, 'd3-format': 'd3'
, 'd3-selection': 'd3'
, 'd3-timer': 'd3'
, 'd3-transition': 'd3'
, 'underscore': '_'
, 'd3-selection': 'd3'
, 'd3-format': 'd3'
}
}
export const defaultTemplate = `
<section class="zambezi-grid-headers"></section>
<section class="zambezi-grid-body"></section>
<ul class="zambezi-grid-resizers"></ul>
<ul class="zambezi-grid-column-drop"></ul>
`

@@ -0,0 +0,0 @@ import { format } from 'd3-format'

@@ -0,0 +0,0 @@ export function createBodyBlockLayout() {

@@ -0,0 +0,0 @@ import { basicPrecisionPxFormatter as px } from './basic-precision-px-formatter'

@@ -0,0 +0,0 @@ import { select } from 'd3-selection'

@@ -0,0 +0,0 @@ import { appendFromTemplate, selectionChanged } from '@zambezi/d3-utils'

@@ -0,0 +0,0 @@ import { emptyIfUndefinedFormat } from '@zambezi/d3-utils'

@@ -0,0 +0,0 @@ import { find, isUndefined } from 'underscore'

@@ -0,0 +0,0 @@ import { select } from 'd3-selection'

@@ -0,0 +0,0 @@ import { select } from 'd3-selection'

@@ -0,0 +0,0 @@ import { selectionChanged, appendIfMissing } from '@zambezi/d3-utils'

@@ -0,0 +0,0 @@ import { appendIfMissing } from '@zambezi/d3-utils'

import { calculateColumnLayout } from './calculate-column-layout'
import { compose, wrap } from 'underscore'
import { createBody } from './body'
import { createColumnDrag } from './column-drag'
import { createColumnSizers } from './column-sizers'
import { createEnsureColumns } from './ensure-columns'

@@ -13,2 +15,4 @@ import { createHeaders } from './headers'

import { createSetupGridTemplate } from './setup-grid-template'
import { createSortRowHeaders } from './sort-row-headers'
import { createSortRows } from './sort-rows'
import { ensureData } from './ensure-data'

@@ -26,7 +30,13 @@ import { ensureId } from './ensure-id'

, processSizeAndClipping = createProcessSizeAndClipping()
, columnDrag = createColumnDrag()
, resize = createResize()
, columnSizers = createColumnSizers()
, body = createBody()
, sortRowHeaders = createSortRowHeaders()
, grid = compose(
each(() => console.groupEnd('draw'))
call(createScrollers())
, call(sortRowHeaders)
, call(createScrollers())
, call(columnSizers)
, call(columnDrag)
, call(createHeaders())

@@ -38,2 +48,3 @@ , call(body)

, call(createMarkRowIndices())
, call(createSortRows())
, call(processRowData)

@@ -46,5 +57,5 @@ , call(resize)

, each(ensureId)
, each(() => console.group('draw'))
)
, api = rebind()
.from(columnSizers, 'resizeColumnsByDefault')
.from(ensureColumns, 'columns')

@@ -54,5 +65,7 @@ .from(processRowData, 'filters', 'filtersUse', 'skipRowLocking')

.from(resize, 'wait:resizeWait')
.from(sortRowHeaders, 'sortableByDefault')
.from(columnDrag, 'dragColumnsByDefault', 'acceptColumnDrop')
.from(setupTemplate, 'template')
return api(redraw(throttle(grid)))
return api(redraw(throttle(grid, 10)))
}

@@ -0,0 +0,0 @@ export function headerBlockLayout(d) {

@@ -0,0 +0,0 @@ import { functor, property } from '@zambezi/fun'

export { createGrid } from './grid'
export const isIE = navigator.userAgent.indexOf('MSIE ') > -1 || navigator.userAgent.indexOf('Trident/') > -1

@@ -0,0 +0,0 @@ import { basicPrecisionPxFormatter as px } from './basic-precision-px-formatter'

@@ -0,0 +0,0 @@ import { select } from 'd3-selection'

@@ -0,0 +0,0 @@ import { createGridSheet } from './grid-sheet'

@@ -0,0 +0,0 @@ export function nestedRowsFilter(filter) {

@@ -0,0 +0,0 @@ import { nestedRowsFilter } from './nested-rows-filter'

@@ -0,0 +0,0 @@ import { fromDetail, fromTarget } from '@zambezi/d3-utils'

@@ -0,0 +0,0 @@ import { basicPrecisionPxFormatter as px } from './basic-precision-px-formatter'

@@ -0,0 +0,0 @@ import { defaultTemplate } from './basic-grid-template'

@@ -0,0 +0,0 @@ export function styleForSelector(selector, sheet) {

@@ -0,0 +0,0 @@ import { functor } from '@zambezi/fun'

@@ -0,0 +0,0 @@ // Create a new proxy object on which we'll set the grid's transient properties.

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc