Commit graph

206 commits

Author SHA1 Message Date
Sherfin Shamsudeen
93287a46cb
Add on change event for text input (#1622) 2021-12-22 12:03:59 +05:30
Arpit
57d89e76b8
[improvement] Widget components #1475 - toggle widget (#1484)
* new implementation/toggle-btn

* Make ToggleSwitch expose its value on load itself

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-12-14 16:47:40 +05:30
Arpit
1069320120
[improvement] Widget components #1475 - range-picker widget (#1486)
* new implementation/daterange-picker

* resolved

* Bump default width of range picker from 8 to 10

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-12-14 16:47:02 +05:30
Arpit
f1457a1905
[improvement] Widget components #1475 - multi-select widget (#1535)
* upddated to new api & multiselect labels fixed

* backfill properties

* Expose default value of multiselect once the component is loaded

* Make multiselect reset to empty whenever option set is changed

* Whenever option set of multiselect changes, set it to default value if default value fits inside the new set of options

* Avoid crash in multiselect using ? operator.

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-12-13 21:43:09 +05:30
Gandharv
6c90a1667b
Feature: undo/redo for canvas 🔥 (#1446)
* feat: add restore shortcut when component is deleted

* change toast messages to hot toast from toastify

* change toast messages to hot toast from toastify

* change toast messages to hot toast from toastify

* on key press match clear the pressed keys

* add react hotkeys hook and delete use-shortcuts custom hook

* change toast messages to hot toast from toastify

* add immer lib

* applyPatches from immer + add undo redo on appdefination changes

* remove notification on undo

* add can-undo + can-redo checks

* add missing can-redo to handlePatchAdd

* add component versioning on componentDefinitionChanged

* set default value of loading state to interpolated boolean false for table

* set canUndo on initial load to false

* fix last element not getting removed on undo

* Remove console log

* add migration to change loadingState for existing tables

* set loadingstate value based on the previous value

* fix: app crash on inspector opening

* add check for selectedComponentId inside components def

* update template definitions for loadingState

* fix alert for success, error, info for button notifications
2021-12-11 04:41:24 +05:30
navaneeth
5ff6b5170b Update default button color to match new theme 2021-12-04 23:37:41 +05:30
Sherfin Shamsudeen
2b308b2f3a
Fix width for iFrame and PasswordInput (#1463) 2021-11-25 19:34:47 +05:30
Sherfin Shamsudeen
64ec3e5b20
Set code editor default width to 15 (#1459) 2021-11-25 17:33:31 +05:30
Sherfin Shamsudeen
f804706de2
Expose current view of calendar component (#1447)
* Expose current view of calendar component

* Rename exposed variable 'view' of calendar to 'currentView'

* Document currentView variable of calendar
2021-11-23 20:38:40 +05:30
Sherfin Shamsudeen
72ec5d786d
Add option to display day names as headers of calendar week view (#1444) 2021-11-23 15:46:10 +05:30
Navaneeth Pk
ae02ec49a9
Feature/calendar popover (#1442)
* Calendar popover

* Cleanup

* Fix scroll

* Resize issue fix

* Make calendar event popover optional

* Fix lint issues on CalendarPopOver.jsx

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-11-23 13:29:22 +05:30
Navaneeth Pk
354ccd7786
Tabs widget (#1438)
* Feature: Tab widget

* Fix container in container crash

* Container inside tabs

* props

* Fix

* Add icon

* Default tab property

* Fix lint issues with Tabs.jsx

* Introduce tab id to select between tabs

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-11-22 21:41:26 +05:30
Arpit
cfde7ccb85
Read file as dataURL or textString (#1415)
* Read file as dataURL or textString

* adds new properties to the file picker docs

* url -> URL encoded string

* typo fix

* docs update

* remove file reading options, and default file reading as textSting and dataURL

* remove docs: definations

* name variable should be empty string too by default

* data (exposed variable) updated to dataURL

* data (exposed variable) updated to dataURL
2021-11-22 09:19:27 +05:30
Navaneeth Pk
20cccd1df7
Responsive canvas (#1363)
* Better canvas

* Better canvas

* Better canvas

* Fix for resize

* Fix for drag

* Fix for drag

* Fix for drag

* Adjust width of components by # of grid lines

* Adjust components to comply with gridline based width

* Fix the width of rigth sidebar

* Fix for subcontainer resize issue

* Fix for dropped widget width (sc)

* Fix subcontainer drag width

* Fix grid for sub container

* Fix viewer

* Fix

* Fix

* Use RnD for dragging within canvas

* bounds for subcontainers

* fix for subcontainers

* Fix for mouseover issue

* Fix

* Fix widget widths

* Fixes chart

* Fixes qr scanner and divider

* Remove scaleValue

* Mmerge fix

* Mmerge fix

* Fix for ormconfig

* Fixes for comments

* Add comment where the user clicked

* Disable dragging on viewer

* Max width for canvas

* Fix for widget click events

* Fix for radio button

* Rebase widget width and left offset for responsive canvas

* Fix

* Fix the width of file picker

* Fix for calendar widget

* Disable zoom selector

* Fixes comment positions

* css fixes

* Fix

* Recompute width and offset of subcontainer widgets based on its parent's width

* Calculate container width separately for modal children while migrating to responsive

* Refactor migration to responsive canvas whereinwhich all mutations are done only after all required changes are computed

Co-authored-by: Sherfin Shamsudeen <[email protected]>
2021-11-16 17:14:09 +05:30
Arpit
7663147525
Feature: Code editor widget (#1381)
* Code Editor Widget

* code editor docs added

* updated to Code Mirror

* updated to Code Mirror

* Language resources do not need to be importe in @codemirror-v3.x

* code editor docs: updated with language mode info and link

* comment pkg.json for future ref - @uiw/react-codemirror versions

* docs: supported lang

* widget reference sidebar alphabetical order

* removed comment form pkg.json
2021-11-15 12:12:02 +05:30
Arpit
a203253131
Feature: adds code preview for codeboxes (#1011)
* preview codeHinter default=true

* adding preview code for codeHinter for table widgets

* previw for codeHinter in eventManager and RestAPI headers tab fixed

* added classes to header tabs

* fixed preview for transformations

* widgets preview for title

* preview for advance tab QueryManager

* preview box for datasource queryeditor

* sql code hinter UI spaces fixed
2021-11-15 11:48:09 +05:30
Arpit
df88790dab
Feature: IFrame widget (#1402)
* feature: iframe widget

* iframe docs - added

* explicitly set frame-src directive

* explicitly set frame-src directive

* typos fixes
2021-11-15 10:09:56 +05:30
Sherfin Shamsudeen
8bbbbfc869
Feature: Calendar widget 🗓 (#1368)
* Insert required boilerplate code for Calendar widget

* Display basic calendar

* Display events on calendar widget

* Pass JS date object as calendar default event date

* Add resource scheduling to Calendar widget

* Add icon for Calendar widget

* Allow configuration of views and default view for calendar

* Add onEventSelect event to Calendar widget

* Accept date as string for Calendar

* Option to disable/enable toolbar in Calendar

* Add default date to Calendar

* Add support for setting color of calendar events

* Set calendar cell size to 50px

* Allow spacious and compact cell sizes for Calendar

* Add support for "select slots" event for calendar

* Add support for custom event tooltip for Calendar

* Add support to not highlight today and now in Calendar

* Add visible border for Calendar events

* Set 14px font size for calendar toolbar

* Add dark mode styles for calendar

* Make calendar view mode controllable with logic

* Add documentation for calendar widget

* Add additional documentation for calendar events

* Expose default view instead of view for calendar

* Add documentation for changes in calendar

* Style updates to calendar

* Increase padding for calendar events
2021-11-04 14:23:50 +05:30
Arpit
a6f99f6fba
Feature: File Picker Widget (#1274)
* File Picker Widget inital commit

* Merged develop

* add file picker icon

* dropzone

* added file picker widget

* does notrequires* babel-import

* fixed styles and removed button to open file selector

* updatedbthe fle picker icon

* style fixes

* added event: onFileSelected

* seperated the concerns and made it more flexible

* fixed handling file types for the picker

* handle - file reject

* file picker description

* text color updates

* Reads contents of the file as a text string

* display list of accepted files

* filepicker docs

* read multiple files-fixed

* style fixes

* added filepicker gif for docs

* typo fixed: docs

* selected files should be inside the widget bound & clear button to clear the selected files

* remove btn for files and selected files should always remain inside the widget bound

* display files bg style and multi-files resolved

* fixed typos
2021-11-04 11:11:10 +05:30
Ksathwik03
5c17d64463
add new markers if addNewMarkers is set to true by default (#1323)
* add new markers if addNewMarkers is set to true by default

* Update components.js
2021-10-29 07:53:53 +05:30
Arpit
e3087f737d
revert/fix default value for dropdown (#1142) 2021-10-25 17:25:40 +05:30
SAI SUMANTH KUMAR
c258016fba
Bugfix: The search box should be displayed on the map if canSearch is set to true by default (#1243)
* Update components.js

* Update components.js
2021-10-24 19:50:27 +05:30
SAI SUMANTH KUMAR
522baf32fb
Feature: border radius property for buttons (#1152)
* Update Button.jsx

* Update components.js

* Update components.js

* Update Button.jsx

* Update components.js

* Update Button.jsx

* Update Button.jsx

* Update Button.jsx
2021-10-23 15:29:33 +05:30
Sherfin Shamsudeen
a7502e5f03
Feature/cell types (#1194)
* Add custom spacing for table cells

* Add migration to set every tables cell spacing compact

* Rename cellSpacing to cellSize

* Add documentation for table cellSize
2021-10-22 07:49:51 +05:30
Arpit
cb78a73105
Password input widget (#1172)
* password input widget

* revert: textinput default value
2021-10-21 21:53:11 +05:30
nik
8a51fe36ad
Add default value for text widget (#1179)
* Add default value for text widget

* Revert "Add default value for text widget"

This reverts commit fc03b3bdcf.

t

* Remove extra space and add text widget

* add value at proper place and remove from display
2021-10-21 21:29:47 +05:30
Arpit
1776ae85ea
Set textinput default value (#1148)
* revert textinput default value

* default value
2021-10-19 16:05:41 +05:30
Tulsi Prasad
d7a6948619
Add default value to RichTextEditor component (#1115)
- Update DraftEditor component only when default value is changed
2021-10-19 09:53:39 +05:30
vedanth bora
18a0f34e16
Updated default value for date picker. (#1110) 2021-10-18 09:03:04 +05:30
Sai Deepesh
269ac0f191
add default value for textarea (#1111) 2021-10-18 09:02:33 +05:30
Mohammad Farhan
1170fcfe19
default values for text widget props (#1103) 2021-10-16 08:40:04 +05:30
Trevor Bayless
ea77528472
Give the Number Input widget a default value (#1105) 2021-10-16 08:39:06 +05:30
Idan Moral
c7d2b604a9
Changed default value of TextInput (#1090) 2021-10-15 19:56:32 +05:30
Arpit
6c4f1c48ef
Feature: Divider widget (#970)
* feature: divider widget

* fixes
2021-10-11 14:41:17 +05:30
Sagar Choudhary
5a70d996fb
Feature: color selector for checkbox (#930) 2021-10-08 13:50:11 +05:30
Arpit
22cfe0af89
Follow up PR to #869: update widgets size (#877)
* widgets dimensions updated: follow up PR-#869

* removed unwanted console.log

* toggle widget minor tweaks

* Fixes the padding of dropdown & multi-select dropdown

* Minor corrections

* Fix padding of datepicker and date range picker

* Fix for toggle switch

* fix checkbox and removed duplicate classname in radio widget

* multi-select width update

Co-authored-by: navaneeth <[email protected]>
2021-10-07 12:22:02 +05:30
Viraj Bahulkar
eeb15db665
Feature: label color property for star widget (#900) 2021-10-07 08:47:29 +05:30
Sherfin Shamsudeen
01d2559ccd
Default highlightSelectedRow to false (#910)
* Default highlightSelectedRow to false for table

* Move location of highlightSelectedRow option in components.js
2021-10-06 13:04:54 +05:30
Sherfin Shamsudeen
c2e97af003
Selected row should be highlighted for table widget (#902)
* Add functionality to highlight selected row

* Add migration to set highlightSelectRow to false for existing tables

* Add documentation for highlighting selected row

* Support highlighting selected row for striped table
2021-10-05 19:36:30 +05:30
Sherfin Shamsudeen
eaaccc247e
Bulk selection for table widget 🔥
* Functional implementation of checkbox selector for table

* Add inspector toggle to display bulk selector checkboxes

* Expose selectedRows variable of Table

* Refactor select-all checkbox into a separate function

* Remove unnecessary import of v4 package

* Add TODO comment for adding checkbox color

* Revert typo that accidentally got committed

* Add explanatory comment in selectedRows data generation code

* Combine original row data and displayed row data for selectedRows

* Show only original data in selectedRows

* Use useRowSelect hook to for implementing table selector

* Show selector column only when it is enable from inspector

* Add migration to set showBulkSelector to false for all tables

* Add documentation for bulk selection

* Set label of toggle that (en/dis)ables bulk selection: 'Bulk selection'
2021-10-05 12:37:17 +05:30
Maurits Lourens
f6aa39fdff
Remove question mark from labels (#895) 2021-10-05 12:31:57 +05:30
Viraj Bahulkar
91761722f0
Add color to toggle switch (#875)
* Add color to toggle switch

* Remove uneccessary comment from code
2021-09-30 08:42:42 +05:30
Arpit
2db5ad52c8
canvas grid layout update and widgets fits the grids (#869)
* component's dimensions should fit according to the grid layout

* components size updated and fit according to the grid layout
2021-09-30 08:40:59 +05:30
Arpit
6cd75fab47
Table cell color do not change according to theme nor color is enforced from the table color picker (#831)
* Table widget: data on inspector is readable in dark mode

* table body colors

* removed repeated properties in the widget ispector or table widget
2021-09-27 09:12:22 +05:30
Mohini Dahiya
9894afb175
Fix default data of charts (#803)
Interchanged X and Y values.
2021-09-22 11:56:51 +05:30
Arpit
26c9cc655c
Fix linting errors across the app (#785)
* eslint-setup: rules for frontend and server

* setup pre-commit:hook

* frontend:eslint fixes

* frontend eslint errors and warning fixed

* eslint:fix for ./server

* fix server/test: expectatin string lint/error

* pre-commit:updated

* removed unwanted install cmd from docker file

* recommended settings and extension for vscode

* husky prepare script added

* updated extension recommendations

* added prettier as recommended extension

* added pre-commit to package.json

* remove .prettierrc file

* resolve changes

* resolve changes
2021-09-21 19:18:28 +05:30
Sherfin Shamsudeen
c238265159
Add default value option to date-picker component (#801) 2021-09-21 07:49:31 +05:30
Arpit
48bcfdd47f
Feature: default values for text/number inputs (#736)
* Order of state computation

* default values for textInput and numberInput widgets

* number input value should be an integer

Co-authored-by: navaneeth <[email protected]>
2021-09-13 23:34:07 +05:30
Sherfin Shamsudeen
a56aa9c954
Add property to show or hide bulk update actions on Table (#739) 2021-09-13 15:37:07 +05:30
navaneeth
de6d3d0251 input validation for datepicker widget 2021-09-08 00:19:06 +05:30
Navaneeth Pk
c55cad0f24
Show/hide table buttons (#682)
* Show/hide table buttons

* clientSide pagination

* Remove unwanted comment

Co-authored-by: arpitnath <[email protected]>
2021-09-07 11:01:10 +05:30
Navaneeth Pk
8fd05bd779
Add validation for dropdowns (#696)
* Validation for dropdowns

* fix

* fix

* fix
2021-09-06 20:02:09 +05:30
Navaneeth Pk
b12cc7f309
Input validation for widgets (#693)
* Validations

* Fix

* Validation for table cells

* fix
2021-09-06 14:20:38 +05:30
Navaneeth Pk
d8e643e4cb
Widget: number input (#689) 2021-09-05 11:51:35 +05:30
navaneeth
ab375398db Correct the dimensions of dropdowns for UI consistency 2021-09-05 10:42:03 +05:30
Arpit
b06b869090
Alignment issue fixed: checkbox widget (#677) 2021-09-05 10:25:30 +05:30
Arpit
67ca8f1461
Feature: disable widgets (#653)
* widgets can be disabled

* removed whitespace

* move to styles definitions

* default values fixed with nullish operator

* proper data attributes

* generic resolver function for widget value

* renamed the style property
2021-09-02 19:41:59 +05:30
navaneeth
3a090de2d7 Default for customObjects and default color for table text 2021-09-02 13:55:10 +05:30
Arpit
cc737393ff
Set default value for radio buttons (#665) 2021-09-01 17:49:59 +05:30
Akshay
6703244857
Fixes map marker (#648) 2021-08-31 22:06:31 +05:30
Arpit
d6f5fd17dd
Feature: Show or hide widgets (#638) 2021-08-30 17:13:05 +05:30
Navaneeth Pk
15e58c0b26
Feature: types for tables (#632) 2021-08-28 21:40:45 +05:30
Gandharv
64131825d9
Feature: Star rating widget ️ (#535)
* feat: add star rating widget

* add events, properties

* add the number of stars as variable

* fix animation

* add half star logic, properties, definations

* add hover index property

* on dismiss show star outline

* show tooltip on hover + fix half icon display on click

* make text inline

* feat: add import svg as react component

* update star rating component for managing color change

* fix: conflicts

* Delete half-star.svg

* Delete star.svg

* change default color to gold

* fix widget settings events

* add default selection of stars

* change default selection to 5

* css changes

* add star rating onchange fix
2021-08-25 20:44:55 +05:30
Navaneeth Pk
eec59e597c
Feature: Multiple handlers for events (#571)
* Multiple handlers for each events

* Fixes

* Migration

* ormconfig to use entities in migrations

* use connection object to build queries

* fixes for bulk update

* Fix for table action button

* use query runner to wrap migration in same transaction

Co-authored-by: Akshay Sasidharan <[email protected]>
2021-08-24 12:21:09 +05:30
navaneeth
2d1745e38d Change default value for textinput 2021-08-24 07:43:43 +05:30
Sherfin Shamsudeen
64db1a2a03
Feature: toggle table header / search bar (#581)
* Add option to enable/disable search bar in Table

This commit also makes the app hide the entire top bar of table
if server pagination is enabled and search bar is disabled.

* Display server-side search option only if search is enabled

* Add documentation for search box enable/disable toggler
2021-08-23 17:00:33 +05:30
navaneeth
3022322bd3 Fix alignment of radio button 2021-08-21 20:34:36 +05:30
navaneeth
c3b30860f6 Set default data for new tables 2021-08-21 20:24:04 +05:30
Navaneeth Pk
3ad6e6b617
Fix the default margins of toggle switch widget (#568) 2021-08-20 23:06:11 +05:30
Navaneeth Pk
c46d57edba
Fix the margins of dropdown and multiselect widgets (#566) 2021-08-20 22:52:37 +05:30
Arpit Nath
1fdd9eb765
fixes react-table duplicate column keys (#538)
* fixes react-table duplicate column keys

* uuid for column id

Co-authored-by: Arpit Nath <[email protected]>
2021-08-19 10:32:46 +05:30
Sherfin Shamsudeen
a53cac24b2
Feature: QR scanner widget (#519)
* Add QR code scanner widget

This commit adds QR code scanner widget which
  * Displays a viewfinder that can be activated or deactivated
  * Exposes a variable named lastDetectedValue which holds the
    data contained in the last QR code it was able to scan
  * Defines an event onDetect which is fired whenever a QR code
    is successfully scanned

* Add documentation for QR scanner widget

* Supply missing newline

* Supply missing newline for qrscanner.svg

* Supply missing newlines and semicolons

* Update error modal content

* Remove `active` property from QrScanner

* Add blob: to content security policy

* Disable content security policy

* Add content security policy that allows self, unsafe-eval and blob
2021-08-18 22:15:43 +05:30
Arpit Nath
b7f1f403ee
Feature: toggle switch widget (#500)
* feature: toggle component for widget

* relsolvers for PR

* lable and default size update

* fixes alignment
2021-08-13 20:56:56 +05:30
Arpit Nath
200cd9f402
Feature: radio button widget (#485)
* feature: radio button for widget

* Revert "feature: radio button for widget"

This reverts commit 99cb80be6a.

* radio button for widget

* icon from svg-repo.com

* radio button widget

* remove unwanted comment

* resolves changes

* component description updated

* radio component properties update

* fixed alignment
2021-08-13 12:00:53 +05:30
Navaneeth Pk
4635db9102
Fixes default value inconsistency of dropdown widget (#361) 2021-07-01 12:17:16 +05:30
Prasad Walvekar
cf4b9ce8ee
Fix text widget alignment (#260) 2021-06-22 20:02:22 +05:30
navaneeth
3dd9292280 Feature: Minor UI improvements 2021-06-10 07:54:11 +05:30
navaneeth
2b7a469dc0 Feature: Text color option for checkboxes 2021-06-05 18:50:10 +05:30
navaneeth
f00f59d1fc Feature: Add device properties to all widgets 2021-06-03 21:31:53 +05:30
navaneeth
94bede4269 Feature: Switch visibility on devices 2021-06-03 20:36:49 +05:30
navaneeth
9629e698e9 Feature: Server-side search for table widget 🎉 2021-06-01 16:54:37 +05:30
navaneeth
efbc428daa Global search of table should be triggered only on enter 2021-06-01 13:39:17 +05:30
navaneeth
ab03d55d50 Remove external svg dependencies 2021-05-31 16:08:18 +05:30
navaneeth
883306a056 Remove visibility property 2021-05-27 07:14:04 +05:30
navaneeth
5bdc399226 Feature: Pie charts 2021-05-26 11:52:40 +05:30
navaneeth
0763cc85ce Fix default values of dropdown widget 2021-05-22 20:09:44 +05:30
navaneeth
d776e6d20e Change default width of datepicker widget 2021-05-22 20:08:25 +05:30
navaneeth
4bb5f6205d Fix for unwanted scroll of codehinter in query editor 2021-05-22 10:44:33 +05:30
navaneeth
f4e4c23c4b Use newly designed icons for widgets 2021-05-20 10:20:48 +05:30
navaneeth
abf3379977 Feature: Toggle map place search 2021-05-17 21:19:18 +05:30
navaneeth
01c482a243 Minor bug fixes for maps widget 2021-05-16 23:43:57 +05:30
navaneeth
c9ace3d1e7 Signup page 2021-05-16 22:21:04 +05:30
navaneeth
39c3247659 Feature: onMarkerClick event for maps 2021-05-16 15:41:55 +05:30
navaneeth
87f4d0fdf6 Feature: onCreateMarker event for maps 2021-05-16 15:23:54 +05:30
navaneeth
a65ee1de09 Feature: onBoundsChange event for maps 2021-05-16 14:39:24 +05:30
navaneeth
f3380622ca Toggle add marker feature of maps 2021-05-16 14:26:18 +05:30
navaneeth
b82277a5df Feature: Default markers for maps 2021-05-16 11:55:48 +05:30
navaneeth
49edc3cc92 Feature: Maps widget 2021-05-16 10:56:31 +05:30
navaneeth
18543112ff Feature: Loading state for charts 2021-05-15 18:41:18 +05:30
navaneeth
c2ee24662a Feature: Ability to toggle chart grid lines 2021-05-15 18:35:01 +05:30