Skip to content

Commit

Permalink
public repository
Browse files Browse the repository at this point in the history
  • Loading branch information
gianpiero.di.blasi authored and gianpiero.di.blasi committed May 23, 2022
1 parent 7321590 commit 71ace0a
Show file tree
Hide file tree
Showing 8 changed files with 74 additions and 89 deletions.
24 changes: 24 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
This is free and unencumbered software released into the public domain.

Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.

In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

For more information, please refer to <https://unlicense.org>
47 changes: 47 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# BootstrapCollectionWidget
An extension to show a Bootstrap style collection.

## Description
This extension provides a widget to show a Bootstrap style collection. The collection is described by the ds_BootstrapCollection DataShape (see below); the DataShape structure is mandatory, but it can be extended with additional fields.

## Properties
- debugMode - BOOLEAN (default = false): if set to true it sends to the browser's JS console a set of information useful for debugging the widget
- headerMashup - MASHUPNAME (no default value): the mashup name of the (optional) header
- headerHeight - NUMBER (default = 100): the mashup height of the (optional) header
- headerData - INFOTABLE (no default value): the mashup data source of the (optional) header
- footerMashup - MASHUPNAME (no default value): the mashup name of the (optional) footer
- footerHeight - NUMBER (default = 100): the mashup height of the (optional) footer
- footerData - INFOTABLE (no default value): the mashup data source of the (optional) footer
- data - INFOTABLE (no default value): the collection data source (use or duplicate & extend the Data Shape ds_BootstrapCollection, see below)
- scrollToSelected - BOOLEAN (default = false): true to scroll to the selected item after data loading
- scrollToPreviousPosition - BOOLEAN (default = false): true to scroll to the previous position after data reloading
- selectedItems - INFOTABLE (no default value): the selected items
- clickedItem - INFOTABLE (no default value): the last clicked item
- clickedDataItem - INFOTABLE (no default value): the infotable data of the last clicked item

## Events
- ItemWasClicked: event to notify that an item has been clicked

## DataShapes
- ds_BootstrapCollection
- uid: an unique id to identify the item - STRING
- parent_uid: an optional parent uid - STRING
- bootstrap_class: the bootstrap class to assign to this cell - STRING
- height: the height of this cell - NUMBER
- is_mashup: true if this is a mashup, false otherwise (it is an empty cell) - BOOLEAN
- mashup_name: the mashup name - MASHUPNAME
- mashup_data: the mashup data - INFOTABLE
- mashup_selection_group: an optional string to manage selection group (only one mashup can be selected into the same selection group) - STRING
- mashup_selected: true if the mashup is selected - BOOLEAN
- mashup_clickable: true id the mashup is clickable - BOOLEAN
- mashup_selection_background: the background color for selection - STRING
- mashup_hover_background: the background color for hovering - STRING
- mashup_active_background: the background color for active mashup - STRING
- mashup_folded_height: the optional height of a folded mashup - STRING
- mashup_folding_class: the optional CSS class to detect the folding area - STRING
- mashup_accordion_group: an optional string to manage accordion group (only one mashup can be open into the same accordion group) - STRING
- container_scroll_to_selected: true if the container should scroll to this cell when selected - BOOLEAN
- container_scroll_to_previous_position: true if the container should scroll to this cell when after data reloading - BOOLEAN

## Donate
If you would like to support the development of this and/or other extensions, consider making a [donation](https://www.paypal.com/donate/?business=HCDX9BAEYDF4C&no_recurring=0&currency_code=EUR).
68 changes: 2 additions & 66 deletions build-extension.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,13 @@
<property name="localization" value="Localization" />
<property name="src.dir" value="${basedir}/src" />
<property name="build.dir" value="${user.home}/builds/${ant.project.name}/bin" />
<property name="minify.dir" value="${user.home}/builds/${ant.project.name}/minify" />
<property name="custom.dir" value="${user.home}/builds/${ant.project.name}/custom" />
<property name="config.dir" value="${basedir}/configfiles" />
<property name="ui.dir" value="${basedir}/${ui}" />
<property name="lib.dir" value="${basedir}/${lib}" />
<property name="zip.dir" value="${user.home}/builds/${ant.project.name}/build/distributions" />
<property name="entity.dir" value="${basedir}/Entities" />
<property name="localization.dir" value="${basedir}/${localization}" />

<property file="${user.home}/vendor-custom.txt"/>
<property file="extension.properties" />

<!-- ExtensionPackage directory structure props -->
Expand All @@ -33,8 +30,6 @@

<!-- Extension file info -->
<property name="zip.file.name" value="${ant.project.name}.zip" />
<property name="minify-zip.file.name" value="${ant.project.name}-min.zip" />
<property name="minify-custom-zip.file.name" value="${ant.project.name}-min-custom.zip" />

<tstamp>
<format property="NOW" pattern="yyyy-MM-dd HH:mm:ss" />
Expand All @@ -50,8 +45,6 @@
<target name="clean">
<delete dir="${build.dir}" />
<delete dir="${zip.dir}" />
<delete dir="${minify.dir}" />
<delete dir="${custom.dir}" />
</target>

<target name="init" depends="clean">
Expand Down Expand Up @@ -100,28 +93,6 @@
</jar>
</target>

<target name="copy-minify">
<copy todir="${minify.dir}">
<fileset dir="${basedir}" includes="${ui}/**/*.min.*" excludes="${ui}/**/jslibrary/*.*"/>
<fileset dir="${basedir}" includes="${ui}/**/*.png" />
</copy>

<move todir="${minify.dir}">
<fileset dir="${minify.dir}" includes="${ui}/**/*.min.*" />
<mapper>
<mapper type="regexp" from="(.*).min.(.*)" to="\1.\2" />
</mapper>
</move>
</target>

<target name="metadata-custom">
<copy todir="${custom.dir}">
<fileset dir="${config.dir}" includes="metadata.xml" />
</copy>

<replace file="${custom.dir}/metadata.xml" token="Accenture Italy - Industry X" value="${vendor-custom}"/>
</target>

<target name="package-extension" depends="build-jars">
<zip destfile="${zip.dir}/${zip.file.name}">
<mappedresources>
Expand All @@ -133,47 +104,12 @@

<zipfileset dir="${basedir}" includes="${entities}/**/*.xml" />
<zipfileset dir="${basedir}" includes="${localization}/**/*.json" />
<zipfileset dir="${basedir}" includes="${ui}/**/*.*" excludes="${ui}/**/*.min.*,${ui}/**/jslibrary/*.*" />
<zipfileset dir="${basedir}" includes="${ui}/**/jslibrary/*.*" />
<zipfileset dir="${basedir}" includes="${ui}/**/*.*" />
<zipfileset dir="${lib.dir}" includes="**/*.jar" prefix="${package.common.lib.dir}/"/>
</zip>
</target>

<target name="package-extension-minify" depends="build-jars,copy-minify">
<zip destfile="${zip.dir}/${minify-zip.file.name}">
<mappedresources>
<fileset dir="${build.dir}" includes="${extension.jar}" />
<globmapper from="*" to="${package.common.lib.dir}/*" />
</mappedresources>

<zipfileset dir="${config.dir}" includes="metadata.xml" />

<zipfileset dir="${basedir}" includes="${entities}/**/*.xml" />
<zipfileset dir="${basedir}" includes="${localization}/**/*.json" />
<zipfileset dir="${minify.dir}" includes="**/*.*" />
<zipfileset dir="${basedir}" includes="${ui}/**/jslibrary/*.*" />
<zipfileset dir="${lib.dir}" includes="**/*.jar" prefix="${package.common.lib.dir}/"/>
</zip>
</target>

<target name="package-extension-minify-custom" depends="build-jars,copy-minify,metadata-custom">
<zip destfile="${zip.dir}/${minify-custom-zip.file.name}">
<mappedresources>
<fileset dir="${build.dir}" includes="${extension.jar}" />
<globmapper from="*" to="${package.common.lib.dir}/*" />
</mappedresources>

<zipfileset dir="${custom.dir}" includes="metadata.xml" />

<zipfileset dir="${basedir}" includes="${entities}/**/*.xml" />
<zipfileset dir="${basedir}" includes="${localization}/**/*.json" />
<zipfileset dir="${minify.dir}" includes="**/*.*" />
<zipfileset dir="${basedir}" includes="${ui}/**/jslibrary/*.*" />
<zipfileset dir="${lib.dir}" includes="**/*.jar" prefix="${package.common.lib.dir}/"/>
</zip>
</target>

<target name="build" depends="package-extension,package-extension-minify,package-extension-minify-custom">
<target name="build" depends="package-extension">
<echo message="Building ${ant.project.name} extension package..."/>
</target>

Expand Down
2 changes: 1 addition & 1 deletion configfiles/metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<ExtensionPackage
name="BootstrapCollectionWidget"
packageVersion="1.1.0"
vendor="Accenture Italy - Industry X"
vendor="Gianpiero Di Blasi"
description="Extension to show a Bootstrap style collection"
minimumThingWorxVersion="8.3.0"
dependsOn="">
Expand Down
Empty file.
6 changes: 0 additions & 6 deletions ui/bootstrapcollection/bootstrapcollection.ide.min.js

This file was deleted.

Loading

0 comments on commit 71ace0a

Please sign in to comment.