Get the FREE Ultimate OpenClaw Setup Guide →

magento-luma-specialist

Scanned
npx machina-cli add skill maxnorm/magento2-agent-skills/magento-luma-specialist --openclaw
Files (1)
SKILL.md
4.9 KB

Magento 2 Luma Specialist

Expert specialist in creating sophisticated customizations and extensions to Magento's default Luma theme, leveraging traditional Magento frontend technologies while maintaining compatibility and performance.

When to Use

  • Customizing Luma theme
  • Working with LESS preprocessing
  • Developing RequireJS modules
  • Building KnockoutJS components
  • Implementing traditional Magento frontend patterns

Luma Theme Architecture

  • Theme Inheritance: Master Luma's parent-child theme structure and fallback mechanisms
  • LESS Architecture: Expert in Luma's LESS variable system and mixins
  • RequireJS Integration: Advanced module loading and dependency management
  • KnockoutJS Components: Build dynamic UI components and data binding
  • Layout System: Deep understanding of XML layout instructions and containers

Traditional Magento Frontend Stack

  • LESS Preprocessing: Advanced LESS compilation and optimization
  • RequireJS: Asynchronous module loading and configuration
  • KnockoutJS: MVVM pattern implementation for dynamic interfaces
  • jQuery: Legacy JavaScript functionality and plugin integration
  • UI Components: Magento's knockout-based UI component library

Luma Development Process

1. Theme Setup & Customization

  • Child Theme Creation: Set up proper theme inheritance structure
  • Variable Customization: Modify LESS variables for brand consistency
  • Layout Modifications: Customize page layouts and component placement
  • Template Overrides: Create custom template files while maintaining upgradability
  • Asset Organization: Organize custom CSS, JavaScript, and images

2. LESS Development

  • Variable Management: Efficiently manage theme variables and overrides
  • Mixin Development: Create custom mixins for repeated patterns
  • Component Styling: Style individual components with BEM methodology
  • Responsive Patterns: Implement consistent responsive design patterns
  • Performance Optimization: Optimize compiled CSS output

3. JavaScript Development

  • RequireJS Modules: Create custom JavaScript modules and widgets
  • KnockoutJS Components: Build interactive UI components
  • jQuery Integration: Integrate jQuery plugins and custom functionality
  • Event Handling: Implement proper event delegation and management
  • AJAX Implementation: Create seamless AJAX interactions

4. UI Components Integration

  • Custom Components: Build custom UI components using Magento's framework
  • Component Configuration: Configure existing components for specific needs
  • Data Binding: Implement sophisticated data binding patterns
  • Validation: Create custom validation rules and messages
  • Form Handling: Enhance form functionality and user experience

LESS Mastery

Advanced Variables

  • Implement complex variable systems and calculations
  • Use LESS functions for dynamic values
  • Create theme-specific variable overrides
  • Manage variable inheritance and scope

Mixins & Functions

  • Create reusable mixins for common patterns
  • Use LESS functions for calculations
  • Implement responsive mixins
  • Build component-specific mixins

RequireJS Development

Module Configuration

  • Configure RequireJS for optimal loading
  • Manage module dependencies
  • Create custom module paths
  • Optimize module loading order

Widget Development

  • Create Magento widgets
  • Implement widget initialization
  • Handle widget options and configuration
  • Build reusable widget patterns

KnockoutJS Components

Component Development

  • Build KnockoutJS components
  • Implement data binding
  • Handle component communication
  • Create reusable component patterns

Data Binding

  • Two-way data binding
  • Computed observables
  • Observable arrays
  • Custom bindings

Best Practices

Performance

  • Asset Optimization: Minimize and compress CSS/JS files
  • Lazy Loading: Implement lazy loading for images and content
  • Caching: Leverage browser and CDN caching
  • Code Splitting: Split JavaScript into logical chunks

Code Organization

  • Modular Structure: Organize code in logical modules
  • BEM Methodology: Use BEM for CSS class naming
  • Component Reusability: Create reusable components
  • Documentation: Maintain clear documentation

References

Focus on creating maintainable Luma customizations that leverage Magento's traditional frontend architecture effectively.

Source

git clone https://github.com/maxnorm/magento2-agent-skills/blob/main/skills/magento-luma-specialist/SKILL.mdView on GitHub

Overview

Expert in creating sophisticated customizations and extensions to Magento's default Luma theme, leveraging traditional frontend technologies while maintaining compatibility and performance. Specializes in LESS preprocessing, RequireJS configuration, and KnockoutJS components to deliver responsive, upgrade-safe interfaces.

How This Skill Works

Work begins with analyzing Luma's theme structure, LESS variable system, and layout. Then it configures RequireJS, builds custom KnockoutJS components, and applies template overrides with XML layout changes to extend or replace UI without sacrificing upgradeability.

When to Use It

  • Customizing the Luma theme to reflect brand and UX goals
  • Working with LESS preprocessing to manage variables and mixins
  • Developing RequireJS modules for modular, asynchronous JavaScript
  • Building KnockoutJS components for dynamic, MVVM-driven UI
  • Implementing traditional Magento frontend patterns with layout XML and templates

Quick Start

  1. Step 1: Create a Luma child theme and enable inheritance
  2. Step 2: Override key LESS variables and build CSS
  3. Step 3: Add a simple RequireJS module and a KnockoutJS component, then wire them in layout

Best Practices

  • Create a proper child theme and define inheritance to preserve upgrades
  • Centralize LESS variables and mixins for consistent styling and responsive patterns
  • Document layout changes with clear XML updates and template overrides
  • Modularize JavaScript with RequireJS and build reusable widgets
  • Test across devices, optimize CSS output, and ensure accessibility

Example Use Cases

  • Branded Luma using a child theme and variable overrides
  • A custom RequireJS module powering a product carousel
  • KnockoutJS component for a dynamic promo banner with data binding
  • XML layout adjustments to move blocks or change container order
  • Custom UI component built with Magento's knockout-based UI library

Frequently Asked Questions

Add this skill to your agents
Sponsor this space

Reach thousands of developers