Download the PHP package ubc-web-services/kraken-vpr without Composer

On this page you can find all versions of the php package ubc-web-services/kraken-vpr. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package kraken-vpr

UBC CLF 10 DRUPAL THEME (aka Kraken)

A responsive UBC CLF (Common Look and Feel) theme for Drupal 10 using Tailwind and Bootstrap 5. Created by the UBC IT Web Services Department.

Kraken is a theme for Drupal 10+, providing UBC-branded units with the basic structure of the UBC CLF (Common Look and Feel).

IE Support

This theme does not support Internet Explorer. If older browser support is required, it must be added separately or galactus, an earlier version of the CLF, can be used.

Rationale

Why another theme? Why not extend the Galactus Drupal 10 theme?

As a web developer in Web Services, you should be able to expect that CSS and Javascript are added in a single consistent way in any project. The Galactus theme works as is, however it is intended for general-purpose use by the broader UBC community. Kraken's goal is to add proper dependency management and workflow for Web Service's theme layer in the same way we have done for the application layer. It is intentionally biased and uses specific CSS and Javascript frameworks (Tailwindcss and Vuejs). Both of these are well-supported and flexible enough to work on any web project (CLF or not) and provide a consistent set of features and functionality. The benefits are improved reusability, improved ramp up time and improved optics. There should be no hidden features only understood by a single developer.

Using the theme

To make changes to the theme CSS and Javascript, you will need to use the command-line tools.

Requirements

Ensure that you have node.js installed, version 18 or higher. To confirm your version, navigate to the Kraken theme directory in your command-line and type node -v.

Installation

From the theme root, install the theme dependencies:

This will install everything required to work with the CSS and Javascript:

Running the commands

There are four main node.js commands defined in in /package.json.

The two most common commands to run:

There are also additional commands for CSS property sorting:

And there are commands to build the CSS or JS assets separately (both development and production versions):


Tailwindcss

The theme makes extensive use of utility classes provided by Tailwind.

All configuration for Tailwind utilities are set in /tailwind.config.js. The configuration uses UBC default colours, fonts, regular spacing, etc. More details about this file can be found in the Tailwind documentation.

Two very important places where it diverges fro the documentation:

When running the production build script (npm run prod), PurgeCSS is used to scan all Twig, Vue and Javascript files and remove any Tailwind utilities that are not in use. This allows for us to deliver a considerably smaller set of CSS classes. Note that classes not provided by Tailwind are never purged.

Additionally, all vendor prefixes for supported browsers are added automatically with Autoprefixer, so there is no need to add these (e.g. -webkit).

I highly recommend installing the Tailwind VS Code extension. It provides code completion for Tailwind utility classes as defined in the tailwind.config.js file. Another useful utility is the Headwind VS Code extension, that sorts classes in your markup based on an opinionated order.

Vue.js

Much of the javascript this theme uses is powered by the Vue.js library. This does have some exceptions where native javascript is used instead (e.g. /src/js/kraken.dismiss.js, /src/js/kraken.misc.js, /src/js/kraken.scroll.js). All attempts have been made to remove jQuery as a dependency.

For ease of integration, there is a single vue instance called - #main-content. Vue can work with any markup in the templates inside of this wrapper.

When running the build scripts, the package despendencies (including the vue.js library) are split from custom vue code, resulting in /js/vue[.min].js and /js/vendors~vue[.min].js. Settings in /webpack.common.js

The primary file is at /src/js/vue.js, which imports all dependencies, components and defines the main vue instance. Custom single file components are stored in the /src/js/components/ directory.

To ease working with Vue, there is an excellent dev tools extension for Chrome to assist with debugging.

Kraken theme settings

Once installed and set to default, you can adjust the following theme settings:

Planned settings (not yet feature complete)


All versions of kraken-vpr with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package ubc-web-services/kraken-vpr contains the following files

Loading the files please wait ....