Mobile Website Template and PWA
Back to Structure DocsThis area is scrollable and includes multiple chapters, scroll to see all chapters.
Each component explained in detail.
If you read the Structure documentation up until this point you will know that you can easily integrate components just by
copy pasting them inside your page-content.
All components, unless specifically mentioned must be placed inside the page-content. Whenever a component requires a part of it
to be placed outside the page-content, we will add a warning so you will know this requires a bit of attention. Not placing them in the correct place
can lead to components not working properly.
To use components as easy as possible, each component is written in a separate page, and added in it's own card.
We strongly
recommend you take copy and paste each component from the .html file you want into your pages, and read this documentation for your desired component to understand how to
customize it even more.
We will explain each component and how to use it, but you will see them even better while using the samples provided.
There are some components we didn't add here, for example, the typography page. These are elements that are simply copy and paste and really don't need any extra explanations. However, if you do not understand something, regardless how small it is, please don't hesitate to contact us. We are always here to assist!
Unless you are using a special card design from the one in the pack, most elements are inserted into cards.
These cards are made to create the nice, rounded and shadow effect, and also to create the margins around the elements inside the card.
1 2 3 4 5 6 | < div class = "card card-style" > < div class = "content UTILITY_SPACING" > < h1 >Hello.</ h1 > < p >I am a card.</ p > < div > </ div > |
Built using the Bootstrap Collapse System - Read more on Bootstrap Collapse Documentation
We will explain each accordion we have in our component-accordions.html page in part, but please check the page as well and use the component by copy pasting it from there and using this documentation as a guideline.
01
02
03
04
05
06
07
08
09
10
11
12
|
< div class = "accordion" id = "accordion-1" > < div > < button class = "btn accordion-btn no-effect" data-bs-toggle = "collapse" data-bs-target = "#collapse1" > < i class = "fa fa-heart color-red2-dark mr-2" ></ i > Accordion Title 1 < i class = "fa fa-plus font-10 accordion-icon" ></ i > </ button > < div id = "collapse1" class = "collapse" data-parent = "#accordion-1" > <!-- add your content here --> </ div > </ div > </ div > |
01
02
03
04
05
06
07
08
09
10
11
12
|
< div class = "accordion" id = "accordion-1" > < div class = "card card-style shadow-0 bg-highlight" > < button class = "btn accordion-btn no-effect" data-bs-toggle = "collapse" data-bs-target = "#collapse1" > < i class = "fa fa-heart color-red2-dark mr-2" ></ i > Accordion Title 1 < i class = "fa fa-plus font-10 accordion-icon" ></ i > </ button > < div id = "collapse1" class = "collapse bg-theme" data-parent = "#accordion-1" > <!-- add your content here --> </ div > </ div > </ div > |
This card works on the same principle as the classic card, but, the button is now a Background Card, as explained in the cards chapter to follow.
Custom built for beautiful effects and interactivity.
The Action Sheet box must be placed outside the page-content
The action sheets function on the Menu principle described in the Menu Structure in the Structure Documentation ( click )
These are in essence simple bottom, top or modal placed menus that get triggered by any button on the screen.
You can place any content you want inside action sheets, give them effects, and place them at the top, bottom or make them modal. Please check the Menu Structure to
understand how to use these. After you understand how to trigger them, just copy and paste or build any component inside them, treating them as a individual entity.
Built and designed using better ad standards.
Ads can be placed inside the page content if the are not fixed or timed. For example, the most popular ads on mobile devices are the 300x50 and 300x250 banners. These can be created by adding the following code inside the page-content whenever you need them
Ad 300x50 - in Content1 2 3 | < div class = "ad-300x50" > <!-- put your ad code here --> </ div > |
1 2 3 | < div class = "ad-300x250" > <!-- put your ad code here --> </ div > |
These are classic boxes that are not fixed, and can be added in between the content area.
The following DIV must be placed outside the page-content
1 2 3 | < div class = "ad-300x50 ad-300x50-fixed" > <!-- put your ad code here --> </ div > |
This ad will stay fixed above the footer bar.
The following DIV must be placed outside the page-content
1 2 3 4 5 6 | < div class = "scroll-ad" > < img src = "img.jpg" class = "shadow-l" > < h1 class = "text-uppercase font-900 font-18 color-white" >Title</ h1 > < em class = "font-12" >Flexibile, fast and fully featured. < br > Pure mobile awesome!</ em > < a href = "#" >Button</ a > </ div > |
This add will appear when you are scrolling, but hide at the top and bottom of the page. This can be found inside component-fixed-ads.html
The code below can be placed anywhere, but the Action Modal for the ad must be placed outside the page content.
1 | data-menu="ad-timed-1" data-timed-ad="5" |
The ad time box itself is simply a modal menu, that is triggered by the above code. The data-timed-ad will represent the timeout until the close button is visible. Please check the component-ad-timed.html to see the modal windows for these ads. Simply copy paste them and replace the content inside with your own.
You can also trigger a timed ad automatically, by adding the following parameter to the code above
1 | data-menu="ad-timed-1" data-timed-ad="5" data-auto-show-ad="10" |
The data auto-show-ad is represented in seconds and will automatically show the ad in 10 seconds. To add this to the page without a button being visible, simply add an empty a href="#" with this data and don't add any color to it. Keep it somewhere on the page.
A simple and useful component
Back to Top badge must be outside the page-content
To use the Back to Top components, simply open component-back-to-top, and take the HTML code you wish for the badge you want and copy it outside the page-content. The code will handle the rest and will hide and show when it's needed.
Navigation depth and returning.
This feature works using the Bootstrap default Breadcrumb component added inside the card. This feature has been requrested by many of our customers in the past. We must warn, that based on Mobile UX standards, your flow should never be so deep that it requires a breadcrumb. Use this component only where it's necessary.
The default Bootstrap Buttons will work perfectly, this is just an enhanced style of the Bootstrap System
The buttons seen in Bootstrap's Documentation are great, but we wanted to give them a more mobile personallity and extend their design to make them look even better. With this being said, you can use any button from Bootstrap, or use the ones found in component-buttons.html
1 | < a href = "#" class = "btn UTILITY_CLASSES_HERE" >Button</ a > |
Our button class is identical to that of Bootstrap, but, with a few utility classes added, we can extend the beauty of these buttons to limitless power. Add any of the following utility / secondary classes to the buttons you want. You can use multiple utility classes combined.
Control Sizes1 | < a href = "#" class = "btn btn-m rounded-sm shadow-xl bg-highlight color-white font-900 text-uppercase" >Button</ a > |
1 | < a href = "#" class = "btn btn-3d btn-m bg-red-dark border-red-light" >Button</ a > |
Icons are pretty much based in the same concept as buttons, the only difference is that icons don't support centering by using an icon class. You can center icons by adding them inside a paragraph
and giving that paragraph the class "text-center".
Beside this, the icons are built in the same way. Let's take an example:
1 | < a href = "#" class = "icon icon-xs rounded-xl bg-facebook" >< i class = "fab fa-facebook" ></ i ></ a > |
Add the class icon, followed by a sizing class, then the background you want. Inside the icon, just place a font-awesome icon
Control SizesThe most flexible Cards in the World.
Our card/caption system has been called by our customers as simply the best solution for creating incredibly powerful cards, while at the same time giving you incredible flexibility.
The classic Bootstrap code for cards still applies if you wish to use their designs.
What we did, is take their code, and slightly enhance it to make it even better than it already is, by
adding options for custom backgrounds, images, lazy loading, rounded borders, shadows, and much, much more.
Using cards, you can create any style of caption you want, in less than 5 minutes. These are incredibly powerful, and we'll explain each part.
There are 2 types of cards. The classic "Expanding Card", that expands depending on the content inside, and the "Height Control" card where you can use extra flexibility in their content.
The expanding card, is the main card style we use for our entire card system. This can support simple styles. Let's explain.
1 2 3 4 5 6 | < div class = "card card-style UTILITY_STYLING" > < div class = "content UTILITY_SPACING" > < h1 >Hello.</ h1 > < p >I am a card.</ p > < div > </ div > |
These are the cards which we used to create the awesome sliders, events pages and more. These have a few extra parameters, but offer incredible flexibility in creating immersive and beautiful elements.
1 2 3 4 | < div class = "card UTILITY_STYLING" data-card-height = "VALUE" > <!--- Card types go here--> < div class = "card-overlay bg-VALUE opacity-VALUE" > </ div > |
This is the basic structure of a card with height control. Let's explain how it works.
Line 1 also has the option of data-card-height. This value can be expressed in pixels, for example, data-card-height="300" or if you want the card to be the full size of the screen, use data-card-height="cover"
Line 2 is where the card types will be added, will be explained below.
Line 3 is the overlay of your card, meaning the background color that will be over the image, but under the text.
In the "Expanding Card", this color was added in the first line, but here, the first line is the background image, and we use the color to place over the image. Replace bg-VALUE with the color you want from
Available Color List and the opacity-VALUE with an opacity you want from the
Available Opacity List to make the background image more or less visible.
Line 4 closes the card itself.
01 02 03 04 05 06 07 08 09 10 11 | < div class = "card-center" > I will appear in the center of the Caption </ div > < div class = "card-top mt-3 ms-3" > I will appear in the top part, pushed from the left and top by 15 pixels </ div > < div class = "card-bottom mb-3 ms-3" > I will appear in the bottom part, pushed from the left and bottom by 15 pixels </ div > |
The card types are added inside the Height Control Cards, in line 2. When using cards with a fixed height, you can use these cards to place content
inside that card, whever you want. You can use as many elements you want, and move them around using the Spacing Utilities.
To see perfect examples of how these cards can be used, please check the component-cards-captions.html, where you will have live examples of multiple variations and also the
component-cards-infinite.html to see an example where the background image is used is an infinite repeating image.
To preload an image in a card, in the starting div of the card, you will have to add this structure
1 | < div class = "card preload-img" data-src = "image.png" data-card-height = "VALUE" > |
In this scenario, you can still use utility styles in your card, but you can no longer use the classes for bg-NUMBER for images. Everything else in the above code stays the same as described before.
Here is a list that allows you to better understand which card is best suited for your needs.
Basic Use ( simple page elements )
Full Screen Elements
Background Image/Infinite
Background Color (gradient/simple)
Content Position - top/center/bottom
Cover Sliders & Walkthroughs
If you want to have full control over your background image, color, opacity, and the position of your text inside the card, then the fixed height card will work perfectly for you.
If you want to use simple text, or elements added inside a card, without caring about their placement, and just want them to flow with the page, then the Expanding classic card is perfect for you.
Slide anything. -> More about our carousel on https://splidejs.com/
For the carousel we're using a pure Vanilla JavaScript slider called Splide. This is one of the most powerful, flexible and most performant sliders out there that has no dependancy requirements. Please do not update the splide script without first getting in touch with us. We've made it in such fashion that the slider is more powerful and less memory hungy, therefore increasing performance even on lower end devices.
Developer Notes: For the full API of the slider, please visit this page -> https://splidejs.com/category/users-guide/
Please open your components-carousles.html or component-sliders.html (names can varry) and check the provided examples. We always shwocase all possible options in that page. However, let's explain the basic structure of a carousel, so we can detail a few elements.
01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 | < div class = "splide SLIDER-TYPE ARROW-OPTIONS DOTS-OPTIONS" id = "UNIQUE-SLIDER-ID-1" > < div class = "splide__track" > < div class = "splide__list" > < div class = "splide__slide" > <!-- Place the content or cards or images you want here this is a slide --> </ div > < div class = "splide__slide" > <!-- Place the content or cards or images you want here this is a slide --> </ div > < div class = "splide__slide" > <!-- Place the content or cards or images you want here this is a slide --> </ div > </ div > </ div > </ div > |
Powered by charts.js - the best chart plugin system.
Charts.js offers the absolute best chart system in the world. You can see the JavaScript required to generate these in the custom.js file by searching (CTRL+F Windows or CMD +F Mac) for charts.
The codes there can be adapted for your use, and a full documentation on how to create your own charts and create simply insanely powereful solutions can be found on
Charts.JS - https://www.chartjs.org/docs/latest/ - Official Documentation
Small pieces of information
Chips are great for showing a tiny button that can house a small piece of information with an icon or an image. Check the component-chips.html page.
These elements are self explanatory, and only require you to copy and paste them.
You can deploy menus from chips by using the data-menu attribute, or anyother snackbar or toast or collapsible as long as you follow the trigger structure mentioned in each chapter.
Built using the Bootstrap Collapse System - Read more on Bootstrap Collapse Documentation
Collapsible elements are designed to house lists of links. These are super useful when you have a lot of listed information available for a single subject. In our example, inside component-collapse.html, we simply created a list group, and added the logic of Bootstrap 5 collapse. You can do the same by following the next logic
1 2 | <a data-bs-toggle= "collapse" href= "#collapse-1" ><!-- Collapse Trigger is Here --></a> <div class = "collapse" id= "collapse-1" ><!-- I will appear when you tap the trigger--></div> |
Any element can be made collapsible, as long as you have the data-bs-toggle="collapse" on the trigger, and the class collapse on what will be shown when pressing the trigger
and make sure your href="UNIQUE_NAME" on the trigger is identical to the id="UNIQUE_NAME" on the element that will be shown when pressing the trigger.
For more advanced uses, please check the Bootstrap Collapse Documentation
Built using the Bootstrap Columns System - Read more on Bootstrap Columns Documentation
Our entire column system is based entirely on the Bootstrap system. Remember, our products are Mobile Templates, so we highly recommend that you don't
exceed 4 columns, since Mobile screens start from about 340px, and having more than 4 columns can lead to text being broken.
This system is also applied for Gallery thumbnails, profile galleries. You can view demos of the columns inside the component-columns.html
Read more on Bootstrap Columns Documentation
Serve content based on Android, iOS or none of these devices.
To show different content for different operating systems the process is incredibly simple. All you have to do is add the class show-android to show for Android devices, or show-ios to show on iOS devices. You can also add the class show-no-device to show only for devices that aren't Android or iOS
Integrating Comment Systems
If you visit the component-disqus-comments.html or component-facebook-comments.html you will find that these systems are integrated by the embed codes provided by Facebook or Diqus.
How to Embed Facebook Comments - https://developers.facebook.com/docs/plugins/embedded-comments/
How to Embed Disqus Comments - https://blog.disqus.com/how-to-embed-disqus-comments-on-your-website
Separating Content Elements.
Dividers serve the purpose of leaving a bit of space between your content elements. These are very simple to use and integrate in your page.
Dividers can use the ultility classes for background colors by attaching the class bg-VALUE, and you can find the colors available in the
Utility Colors Chapter
Dividers are very self explanatory little pieces of code you can find in the component-dividers.html page. If you use a divider and wish it to be full width simply use the divider bg-VLAUE class.
If you want your divider to have the same left and right margin as your content, simply add divider-margins as a utility class.
Embed any content in your site.
There are two main methods to embed content in our product. One and the most classic known is by copying the embed HTML code.
1 2 3 | <div class = "responsive-iframe" > </div> |
The classic embed code above will automatically make the iframe responsive on Mobile Devices. Simply copy your iframe inside the div, and remove the width and height parameters that the iframe embed comes with.
The component-embedly.html uses the most advanced embed system in the world at the moment available to HTML sites. Embedly generates an embed code for most websites you throw at it. You can simply visit https://embed.ly/code to generate an embed code and then copy it in the page.
Upload and decode images using Web API's .
The file upload API allows you to upload images and decript their value, when they were taken, modified, size and file name. This is only a front-end element that can be found inside
custom.js by searching (CTRL+F windows / CMD+F mac) for "upload-file" to find the JS behind it. You can use your own code logic to Programmatically adapt the JS for your needs.
By default, this component is found in component-file-upload.html, and you can use only the file-data div to use only the upload file input or use the upload-file-data
under this as well to get the list information about what the image contains once the user uploads it.
You can learn more about the File Web API here - https://developer.mozilla.org/en-US/docs/Web/API/File/Using_files_from_web_applications
Get device approximate location.
The GeoLocation available to websites uses WebAPI, which triangulates based on WiFi and Cellular towers. This does not give full access to the internal
device GPS like a native application would, meaning, the location outputed will not be 100% accurate.
To get the device location, you will simply have to add get-location class to a button, and add a empty div or paragraph with the class location-coordinates
To output the location on a map, simply embed a responsive map, with any location you want and give it the class location-map.
Once the user taps the get-location button, they will be prompted to approve this ( which is mandatory and cannot be removed ). Once they approve this, the coordinates
will be tracked and outputed to the location-coordinates element. If you use a map as well, our code will automatically add these coordinates to the map.
Built using the Bootstrap Input System - Read more on Bootstrap Input Documentation.
Beside the classic inputs offered by Bootstrap, we created a few styles to complement the existing design found in our product. These are easy to use and you can simply copy paste them from the input-components.html. However, there are a few things to note.
1 2 3 4 5 6 7 8 | < div class = "input-style OPTION-1 OPTION-2 validate-field mb-4" > < i class = "fa fa-user" ></ i > < input type = "name" class = "form-control validate-name" id = "form1" placeholder = "Name" > < label for = "form1" class = "color-highlight" >Name</ label > < i class = "fa fa-times disabled invalid color-red-dark" ></ i > < i class = "fa fa-check disabled valid color-green-dark" ></ i > < em >(required)</ em > </ div > |
Simply open component-inputs.html and copy and paste them in the form you want. The same applies to the checkboxes and radio buttons included.
You can replace:
OPTION-1 with has-borders or no-borders
OPTION-2 with has-icon or no-icon. If you select no-icon you must delete Line 2
VALIDATE-FIELD - if you don't want field validation, be sure you delete this attribute and also the validate-attribute on line 3. When using the fields without validation, lines 5 to 7 must also be deleted.
We use regular expressions (RegEX) to validate the fields. With this being said, in case you require a more extensive plugin for validation, you can include any jQuery plugin you want by following the How do I add my own JavaScript code developer note.
Preloading and styling your img
The image tag supports LazyLoad preloading to make it show after the other more important parts of the page are loaded. This is used to improve page speed and is recommended to be used wherever possible.
1 | < img class = "img-fluid preload-img" src = "images/empty.png" data-src = "location/image.png" alt = "image" > |
Built using the Bootstrap List Groups System - Read more on Bootstrap List Groups Documentation.
List groups from Bootstrap can be used as shown in the documentation example link above. However, to keep the design of our product more in theme with its style, you can use the examples below. These use the same class architecture as bootstrap, but offer more design features, and are also compatible with switches.
A link list is a list of items that include a single line of text or a secondary description line with an icon to the left and right side. These are super simple to use and support the utility classes for colors and also support badges and switches.
01
02
03
04
05
06
07
08
09
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
<div class = "list-group list-custom-SIZE_VALUE" > <a href= "#" > <i class = "fa font-14 fa-cog color-brown1-dark" ></i> <span>Ultra Mobile</span> <strong>Only use this line for large</strong> <i class = "fa fa-angle-right" ></i> </a> <a href= "#" > <i class = "fa font-14 fa-bars rounded-xl shadow-xl bg-blue2-dark" ></i> <span>Azures Mobile</span> <strong>Only use this line for large</strong> <span class = "badge bg-red2-dark font-10" >$ 25 </span> <i class = "fa fa-angle-right" ></i> </a> <a href= "#" > <i class = "fa font-14 fa-check rounded-sm shadow-m bg-green1-dark" ></i> <span>Sticky Mobile</span> <strong>Only use this line for large</strong> <span class = "badge bg-green1-dark" >FRESH</span> <i class = "fa fa-angle-right" ></i> </a> <a data-trigger- switch = "switch-1" class = "border-0" href= "#" > <i class = "fa font-14 fa-star shadow-s bg-yellow1-dark" ></i> <span>Kolor Mobile</span> <strong>Only use this line for large</strong> <div class = "custom-control scale-switch ios-switch" > <input type= "checkbox" class = "ios-input" id= "switch-1" > <label class = "custom-control-label" for = "switch-1" ></label> </div> <i class = "fa fa-angle-right" ></i> </a> </div> |
The above code will generate a list group, let's dive in the code and explain it line by line.
Line 1 defines this as being a list group and also, defines its size. You can replace the SIZE_VALUE with small or large. If you select the
size as being large, then, you can use lines 5, 11,18,25. Otherwise, delete these lines. These are the second line of text in the case of large lists, like
we use in our demo in the component list.
Lines 2 to 7 generate a list, with a colored icon. - the icon is part of the font-awesome group, and uses the color-VALUE
found in the Utility Colors chapter. The last icon in this case is a simple arrow to the right side. This icon must be kept in all styles.
Lines 8 to 14 and 15 to 21 The same principle as the first group applies here, with the exception of the icon, which now has utility classes for rounded borders
and the badge. The badge is a smple span class with a background color and a font size. This can be used to showcase a price, the fact that it's new, hot or other useful tiny messages
Lines 22 to 31 Works on the same principle as the previous ones, with an exception that we have inserted a switch in it. You can learn
all about switches in the Switches chapter. The switch will be triggerable by the list as well by using the "data-trigger="unique-number" that will corespond to the switch input id.
Alerts using the Bootstrap Alerts System - Read more on Bootstrap Alerts Documentation.
Notification boxes using the Bootstrap Toast System - Read more on Bootstrap Toasts Documentation
Using the default alerts of Boostrap means you can use any of the examples shown in the component-notifications.html, which include a span for an icon that can have any font awesome icon included in the pack. Also, you can view more examples of alerts on https://getbootstrap.com/docs/5.0/components/alerts/
The notification that dropdown from the top must be placed outside the page-content
Each notification that comes from the top of the page is placed outside the page content of the component-notifications.html page. These are designed to mimic the design of their mobile counterparts. Let's explain the general code of each these.
This will just explain the general logic of the notification system. Please check after the page-content class is closed in component-notifications.html to view more examples. Each notification includes simple elements inside you can easily modify using the Utility Classes to suit your needs.
1 2 3 4 5 6 7 | <div id= "notification-1" data-bs-dismiss= "notification-1" data-bs-delay= "3000" data-bs-autohide= "true" class = "notification NOTIFICATION_TYPE bg-dark1-dark" > <!-- check the component-notifications.html page, after the page-content closes to see more--> </div> |
Line 1- defines the ID of the notification. This will be used in case you want to trigger the notification from a button on the page. You can
trigger it by adding data-toast="notification-1" .Be sure this is always a unique number. This is also used to dismiss the notification from a button, or in our case, if the user taps it.
Line 2- is the data-bs-dissmiss attribute which shares the same unique ID as line 1. This is used if you want to dismiss the notitifcation by tapping it.
Line 3- is the delay. this is how long the notification will be visible on screen before Line 4, if set to true, will hide it back.
Line 5- is the class used for the notification and the background color you wish to use.
Automatic process of detecting when you are online/offline
The offline detection system is automatic, and shows a small red or green text depending if you're online or not. These messages can be edited from scripts/pwa.js by searching for (CTRL+F windows or CMD+F mac) for "Offline Alerts"
Show a loader before your page loads.
The preloader is automatically added to each page using the AJAX transition system and hidden when the page load is completed.
1 | <div id= "preloader" ><div class = "spinner-border color-highlight" role= "status" ></div></div> |
Possible Cause 1 - If your page shows an infinite preloader loop, you should inspect the console in your browser. This means the JavaScript is not running
correctly and the functions that hide the preloader are not firing.
Possible Cause 2 - Preloaders can also not appear if you test in incompatible browsers that don't support CSS3. For example, internet explorer, but in this case
we recomemnd using the item for it's intented purpose, as browsers that don't support CSS3 will cause sever problems with any modern code.
Generate automatic QR Codes based on current link, or manual generation
We are using an API to instantly generate QR codes, so you don't need complicated PHP api's to generate scripts. This can generate ANY qr code by simply using the following structure. Simply copy and paste the code above and replace the ENTER_YOUR_FULL_URL_HERE with your address. Once you've done this save and render the page, the QR will automatically be displayed.1 | <img class = "generate-qr-auto" src= "" > |
Automatic Link Social Sharing
The automatic social sharing feature works great for your website when used in classic website mode. However, if you plan on using the page as a PWA, we still don't have access to API's to pick up the link of where your PWA is saved and share that link directly.1 | var share_link = window.location.href; |
1 | |
Understanding the Search Component
Our page uses an actual search system built in front end. If you integrate this with PHP and pre-populate it with data you will have a live, functional search system that can be conencted to a back-end. Of course, in the limit of normal use, in case of stronger needs you will require a custom AJAX solution. But let's dive in our search system.The search page, in our example, uses a input field for typing your search query, and a result list that will automatically appear if the word matches. Please use the structure for the input fields and the search results box exactly as shown in the item. You can use Utility Classes to change the design, and you can replace the "found" elements with whatever design you wish as long as you keep them wrapped in the div following the code below.
1 2 3 | < div data-filter-item data-filter-name = "all products eazy mobile" class = "search-result-list" > <!-- your search result --> </ div > |
Shown above is a search result. Inside this, you can add any component/element you want and it will be found if the user searches for any of the words inserted in the data-filter-name="your keywords here". Be sure the keywords are written in lowercase letters and separated with a space.
The most advanced Sidebar System on any Mobile Template
The Action Sheet box must be placed outside the page-content
Our sidebars are built to run smoothly, powered by CSS3 transitions, and automatic screen placement.
1
2
3
4
|
//show menu menu( 'your-menu-id' , //hide menu menu( 'your-menu-id' , |
1
2
3
4
5
6
|
< div id = "MENU_UNIQUE_NAME" class = "menu MENU_BOX_POSITION" data-menu-width = "VALUE_IN_PX" data-menu-effect = "MENU_EFFECT" > <!-- Add what you want in your sidebar here --> </ div > |
Inside your sidebar, add any button that has the class close-menu. That button will close any menu or use the programatic use explained above.
Yes! Inside your sidebar, add a button with the data-menu="your-menu-id" and that menu will be triggered.
Built using the Bootstrap Toast System - Read more on Bootstrap Toast Documentation
The Snackbars box must be placed outside the page-content
Snackbars are in essence larger toasts, so, to avoid adding extra JavaScript and writing extended functions for these, we created the snacbkars using the toasts system offered by Boostrap. This makes it easy for them to be used in Programatic Use and also keep the file size low, as the framework is already heavy on it's own
Simply add data-toast="unique-snackbar-id" to any button you want to use to trigger the snackbar from.
Please check the Programatic Use explained by Bootstrap. Their system will work for Snackbars.
1 | < div id = "UNIQUE_ID" class = "snackbar-toast UTILITY_COLORS" data-bs-delay = "3000" data-bs-autohide = "true" >< i class = "fa fa-check mr-3" ></ i >your text</ div > |
The code above will generate a snackbar. Please be sure this code is placed outside the page-content.
The code must have a unique-id that you will use to trigger the snackbar via programatic use or via the data-toast="unique-id" system. The data-bs-delay is represented in miliseconds
and in the code above, means it will automatically disapear after 3 seconds.
Custom built for maximum flexibility
As Bootstrap doesn't offer an actual tab system, we built a very simple and efficient one, where we used code as simple to use as possible. Let's explain.
.01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 | < div class = "content" id = "tab-group-UNIQUE-1" > < div class = "tab-controls tabs-small tabs-rounded" data-highlight = "bg-highlight" > < a href = "#" data-active data-bs-toggle = "collapse" data-bs-target = "#tab-UNIQUE-NUMBER-1" >Tab 1</ a > < a href = "#" data-bs-toggle = "collapse" data-bs-target = "#tab-UNIQUE-NUMBER-2" >Tab 2</ a > < a href = "#" data-bs-toggle = "collapse" data-bs-target = "#tab-UNIQUE-NUMBER-3" >Tab 3</ a > </ div > < div class = "clearfix mb-3" ></ div > < div data-bs-parent = "#tab-group-UNIQUE-1" class = "collapse show" id = "tab-UNIQUE-NUMBER-1" > <!-- Tab Content 1--> </ div > < div data-bs-parent = "#tab-group-UNIQUE-1" class = "collapse" id = "tab-UNIQUE-NUMBER-2" > <!-- Tab Content 2 --> </ div > < div data-bs-parent = "#tab-group-UNIQUE-1" class = "collapse" id = "tab-UNIQUE-NUMBER-3" > <!-- Tab Content 3 --> </ div > </ div > |
Built using the Bootstrap Toast System - Read more on Bootstrap Toast Documentation
The Toast box itself must be placed outside the page-content
The default Bootstrap toasts can be used and triggered manually or Programmatically using our item by following the instructions mentioned on Bootstrap Toast Documentation.
1 2 3 4 5 6 | < div id = "toast-1" class = "toast toast-tiny toast-top bg-blue2-dark" data-delay = "3000" data-autohide = "true" > < i class = "fa fa-check mr-3" ></ i > All Good! </ div > |
Line 1 - contains the ID of the toast, this will be used to trigger it. Just use data-toast="unique-toast-id" on an element you wish to trigger the toast.
Line 1 - also contains the classes. The class toast is used to identify this for Bootstrap's JS. The toast-tiny is the class we use for styling.
Line 1 - also contains the toast-top or toast-bottom depending where you want your toast to show from and the last element is the background color you want which you can select from the Utility Colors
Line 2 and 3 - is the delay for the toast and the fact that this toast will auto hide. The time is expressed in miliseconds.
Line 4 - is the icon for your toast
Line 5 - is the text for your toast
Line 6 - is the ending of the toast.
Create as many toasts as you need just be sure the ID is unique for each.
Built using the Bootstrap Toggle Switches - Read more on Toggle Switches Documentation
Toggle switches are input elements which can be used to toggle content or to switch a state in the input. These are affected by the checked attribute just like a checkbox for example.
First of all, let's show you the main switches availabe. We use iOS and Android Styled Switches. Let's explain their structure, and then we can get to more complicated use cases for them.
01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | < div class = "d-flex no-effect" data-trigger-switch = "toggle-id-1" data-bs-toggle = "collapse" href = "#collapseExample1" role = "button" aria-expanded = "false" aria-controls = "collapseExample1" > < div class = "pt-1" > < h5 class = "font-600" >Toggle Trigger</ h5 > </ div > < div class = "ms-auto me-4 pe-2" > < div class = "custom-control BRAND-switch" > < input type = "checkbox" class = "BRAND-input" id = "toggle-id-1" > < label class = "custom-control-label" for = "toggle-id-1" ></ label > </ div > </ div > </ div > < div class = "collapse" id = "collapseExample1" > <!-- Content goes here if you want to use the toggle to switch content. If not, simply delete lines 18 to 26 completely and remove line 3, line 6 and line 7. Also, replace href="#collapseExample1" with href="#". After doing this, the toggle will act like a regular input checkbox. --> </ div > |
Notice that the title is connected to the switch using the data-trigger-switch="toggle-id-1" | id="toggle-id-1" | for="toggle-id-1". You can create infinite number of toggles and connect them to a separate button on the screen that will activate them, as long as the above properties match eachother.
Line 1 - Creates a flexbox for the switch, so the icon and text can be aligned properly.
Line 2 - When clicking anywhere on the switch, the icon will still change, this happens because data-trigger-switch="toggle-id-1" is
identical to the input id and for on lines 14 and 15. You can create as many switches as you want, but these ID's must be unique for each switch.
Line 3 - optional - is used when you want to toggle the content on line 19. This must be set to collapse together with the class of line 19
Line 4 - optional - is the unique ID that is used on line 19 as well. When clicking the switch the content on line 19 will show or hide.
Line 5 - Makes the entire line have a pointer hand effect. Easier to determine when working on desktop and editing the page.
Line 6 - Defines if the collapse content should be visible or not by default. If you set this to true, be sure you also add a checked value to line 14 so that the input toggle will show as activated
Line 7 - Defines that this switch will control the element on line 19
Line 8 - Is the closing of the attributes inside the main div. We used separate lines for easier visibility.
Line 9 to Line 11 - Are the toggle text on the starting side.
Line 12 to 17 - Are the actual input itself. You can define it as ios or android styled by replacing BRAND-input with ios-input or android-input. Please be sure your id and for match the value of line 2 and are unique for each switch you create.
Line 18 - Closes the main div that houses the entire switch.
Lines 19 to 26 - are the content that will be shown or hidden if you follow the instructions in Line 20 to 25 and the above mentioned lines to make sure you have unique identifiers for each toggle group. For live examples, be sure you check the component-toggles.html or component-switches.html (file names may differ)
To create an Android type switch or an iOS type switch, simply replace the BRAND-switch | BRAND-input on line 6 and line 7 with ios-switch | ios-input or android-switch | android-input
To modify the checked value of a switch, you must use the Input Checkbox check property (link).
Using Native WebAPI Protocols
To begin with, we must mention that iOS does not allow access to their Taptic / Vibration API. Vibrations will only work for Android devices, and only on buttons, not as a programatic gesture.
This is restricted on certain devices. If you own an Android device, chances are you saw with previous operating systems sites where the phone would start vibrating like crazy for no reason.
This is why the vibration API will only work on a gesture pre-made by the user, and cannot be Programmatically enabled.
To make any button or element the user taps on vibrate, all you have to do is add the attribute data-vibrate="5". The 5 represents 5 miliseconds. By default, mobile devices send vibrations of 5 to 125ms in length.
For the best possible user experience it is recomemnded not to send vibrations longer than this, so the user feels like your app is native to his experience, rather than something new and intrusive.
Thank you for being a awesome customer
If you read the documentation thus far, you're probably a master of our components and can copy paste them to create the perfect interface for you. However, if you get stuck, please know, we are always here to help!
A few tips that we must give. In the component documentation, we have included referrences to the Bootstrap documentation whenever extra features are available. Don't be afraid to experiment with them and
read more about these features on Bootstrap's site. You can furhter enhance the already existing components we have. This will also be good if you are a devloper and know or want to know
JS behavior and how to increase the programatic power of our item.
Don't forget! Always write your Custom Javascript as mentioned in the Developer Notes Section to be sure you avoid issues with code and always place your code in the correct place. Our item will cause
you no stress if these small things are followed.
If there is anything you don't find here, or you require clarifications for any element we have here, please open a support ticket on our forums. We will gladly help you out.
Our support times are blazing fast and we are patient with any question you may have. No question is small and no question is stupid. If you feel you don't understand something, please let us know!
It's an immense pleasure for us to know our customers know and master our products and can place their imagination in our product to make it their own!
So, please, if there is anything we may help you with from our product features, or pages, let us know!
We're always available for you on https://www.enableds.com ( the support page )