forked from ioBroker/ioBroker.vis
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* (bluefox) jQui Radio widget was migrated to react
- Loading branch information
1 parent
6bbae36
commit c1d4c38
Showing
18 changed files
with
152 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,4 +71,4 @@ | |
"not ie <= 11", | ||
"not op_mini all" | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/** | ||
* ioBroker.vis | ||
* https://github.com/ioBroker/ioBroker.vis | ||
* | ||
* Copyright (c) 2023 Denis Haev https://github.com/GermanBluefox, | ||
* Creative Common Attribution-NonCommercial (CC BY-NC) | ||
* | ||
* http://creativecommons.org/licenses/by-nc/4.0/ | ||
* | ||
* Short content: | ||
* Licensees may copy, distribute, display and perform the work and make derivative works based on it only if they give the author or licensor the credits in the manner specified by these. | ||
* Licensees may copy, distribute, display, and perform the work and make derivative works based on it only for noncommercial purposes. | ||
* (Free for non-commercial use). | ||
*/ | ||
|
||
import PropTypes from 'prop-types'; | ||
|
||
// eslint-disable-next-line import/no-cycle | ||
import JQuiState from './JQuiState'; | ||
|
||
class JQuiRadioList extends JQuiState { | ||
static getWidgetInfo() { | ||
const widgetInfo = JQuiState.getWidgetInfo(); | ||
const newWidgetInfo = { | ||
id: 'tplJquiRadioList', | ||
visSet: 'jqui', | ||
visName: 'Radiobuttons ValueList', | ||
visWidgetLabel: 'jqui_radio_list', | ||
visPrev: 'widgets/jqui/img/Prev_RadioList.png', | ||
visOrder: 15, | ||
visAttrs: widgetInfo.visAttrs, | ||
visDefaultStyle: { | ||
width: 250, | ||
height: 45, | ||
}, | ||
}; | ||
|
||
// Add note | ||
newWidgetInfo.visAttrs[0].fields.unshift({ | ||
name: '_note', | ||
type: 'help', | ||
text: 'jqui_state_note', | ||
}); | ||
|
||
return newWidgetInfo; | ||
} | ||
|
||
// eslint-disable-next-line class-methods-use-this | ||
getWidgetInfo() { | ||
return JQuiRadioList.getWidgetInfo(); | ||
} | ||
} | ||
|
||
JQuiRadioList.propTypes = { | ||
id: PropTypes.string.isRequired, | ||
context: PropTypes.object.isRequired, | ||
view: PropTypes.string.isRequired, | ||
editMode: PropTypes.bool.isRequired, | ||
tpl: PropTypes.string.isRequired, | ||
}; | ||
|
||
export default JQuiRadioList; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters