Download the PHP package tobento/app-card without Composer
On this page you can find all versions of the php package tobento/app-card. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package app-card
App Card
The card app provides interfaces to create cards to be displayed on a dashboard page for instance. It comes with a default implementation and basic cards.
Table of Contents
- Getting Started
- Requirements
- Documentation
- App
- Card Boot
- Card Config
- Cards
- Adding Cards
- Cards Methods
- Displaying Cards In Views
- Creating Specific Cards
- Available Cards
- Group Card
- Html Card
- KeyedList Card
- Table Card
- Available Card Factories
- Group Card Factory
- Html Card Factory
- KeyedList Card Factory
- Table Card Factory
- Filterable Cards
- Credits
Getting Started
Add the latest version of the app card project running this command.
Requirements
- PHP 8.0 or greater
Documentation
App
Check out the App Skeleton if you are using the skeleton.
You may also check out the App to learn more about the app in general.
Card Boot
The card boot does the following:
- migrates card config, view and asset files
- implements cards interfaces based on the card config file
Card Config
The configuration for the card is located in the file at the default App Skeleton config location where you can configure the implemented card interfaces for your application.
Cards
Adding Cards
You may use the implemented adding cards to create your own cards specific to a resource.
Furthermore, it is recommended to use the App on method to add cards only if requested.
Check out the Available Card Factories.
Cards Methods
Filter Methods
You may filter added cards using the following methods returning a new instance:
Retrieving Methods
Displaying Cards In Views
In your view file, use the render method to display the cards:
Check out the App View to learn more about it.
Creating Specific Cards
Instead of using the implemented to add cards, you may create cards specific to a resource by simply extend the :
Adding cards
Available Cards
Group Card
The card may be used to group cards being displayed in smaller sizes:
You may use the add the card.
Html Card
The card may be used to add HTML:
You may use the add the card.
KeyedList Card
The card may be used to add items being displayed as a keyed list:
You may use the add the card.
Table Card
The card may be used to add items being displayed in a table:
You may use the add the card.
Available Card Factories
Group Card Factory
The card factory creates a Group Card:
Html Card Factory
The card factory creates a Html Card:
KeyedList Card Factory
The card factory creates a KeyedList Card:
Table Card Factory
The card factory creates a Table Card:
Filterable Cards
You may create filterable cards by using the implemented storing filtered data in cookies (default) using the App Http Cookies Boot. You may consider encrypting cookies in addition.
The view file:
Make sure the names of the form elements are like . In addition, make sure you have added the asset in your main view which will update the cards content while filtering. See Displaying Cards In Views
This example uses Form Service which can be integrated by the Form Boot.
Credits
- Tobias Strub
- All Contributors
All versions of app-card with dependencies
tobento/app Version ^1.0.7
tobento/app-http Version ^1.0
tobento/app-migration Version ^1.0
tobento/app-view Version ^1.0
tobento/service-collection Version ^1.0
tobento/service-support Version ^1.0