Skip to main content

exodeui_flutter 1.1.4 copy "exodeui_flutter: ^1.1.4" to clipboard
exodeui_flutter: ^1.1.4 copied to clipboard

PlatformAndroid

Official Flutter runtime for the ExodeUI animation engine. Renders .exode and .bexode artboards with physics, state machines, chart components and interactivity.

ExodeUI for Flutter #

ExodeUI Logo

The official Flutter runtime for the ExodeUI Animation Engine.
Render interactive vector animations, physics simulations, state machines, charts, and design systems natively in Flutter.

Pub Version Pub Points ExodeUI Website License


๐Ÿš€ Overview #

ExodeUI is the next-generation Motion Stack and Motion Development Environment (MDE). The exodeui_flutter package delivers hardware-accelerated playback for .exode and .bexode artboards directly inside your Flutter applications on Android, iOS, and macOS.

Export animations straight from the ExodeUI Editor or Figma and run them with pixel-perfect fidelity, Rapier2D physics, and zero handoff friction.


โœจ Features #

  • ๐ŸŽ๏ธ Ultra-Fast Binary Loading (.bexode): Loads in $\sim3\text{ms}$ with 5โ€“10ร— compression compared to JSON.
  • โšก Lightweight Render Pipeline: Sub-millisecond ($0.24\text{ms}$) frame render time; well within the 60fps / 120fps frame budgets.
  • โš›๏ธ Physics & Gravity Engine: Full 2D physics powered by Rapier (gravity, collision boundaries, drag, wind, and force fields).
  • ๐Ÿง  Interactive State Machines: Complex conditional logic, multi-layer transitions, state variables, and event listeners.
  • ๐Ÿ“Š Dynamic Components & Charts: Live real-time updates for Line/Area Graphs, Bar Charts, Pie Charts, and Dropdowns.
  • ๐Ÿ“ฑ Responsive Auto-Layout: Supports all 8 fit modes (contain, cover, fill, etc.) and multi-breakpoint reflow across mobile, tablet, and desktop screens.
  • ๐Ÿ‘† Multi-Touch & Sensor Integration: Native pointer tracking, hover events, wheel velocity, and external scroll synchronization.

๐Ÿ“ฑ Platform Support #

Platform Supported Engine Backend Minimum Requirement
Android โœ… webview_flutter_android API Level 24+ (Android 7.0+)
iOS โœ… webview_flutter_wkwebview iOS 13.0+
macOS โœ… webview_flutter_wkwebview macOS 10.15+ (Catalina)
Web ๐ŸŒ Use the React or Vanilla JS SDK Direct WebGL/Canvas
Windows / Linux ๐Ÿ–ฅ๏ธ Use the React or Vanilla JS SDK Custom Webview host

๐Ÿ“ฆ Installation #

Add exodeui_flutter to your pubspec.yaml:

dependencies:
  exodeui_flutter: ^1.1.0

Run in terminal:

flutter pub get

Platform Setup #

macOS Setup

On macOS, grant outgoing network-client access to WKWebView in macos/Runner/DebugProfile.entitlements and macos/Runner/Release.entitlements:

<key>com.apple.security.network.client</key>
<true/>

๐Ÿ› ๏ธ Usage & Quick Start #

1. Register Artboard Assets #

Export your artboard from exodeui.com and place it in your app's assets/ directory:

flutter:
  assets:
    - assets/hero.bexode   # Recommended binary format
    # or
    - assets/hero.json     # JSON artboard

2. Render Artboard in Widget Tree #

import 'package:flutter/material.dart';
import 'package:exodeui_flutter/exodeui_flutter.dart';

class HeroBanner extends StatelessWidget {
  const HeroBanner({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: ExodeUICanvas(
        bexodeAsset: 'assets/hero.bexode',
        fit: ExodeFit.contain,
        alignment: ExodeAlignment.center,
        autoPlay: true,
        onReady: (controller) {
          debugPrint('Artboard loaded: ${controller.artboardId}');
        },
        onTrigger: (trigger, animation) {
          debugPrint('Trigger fired: $trigger -> $animation');
        },
        onError: (message, stack) {
          debugPrint('ExodeUI error: $message');
        },
      ),
    );
  }
}

3. Alternative Loading Sources #

Load artboards from memory, JSON strings, or network payloads:

// 1. From pre-loaded .bexode binary bytes (e.g. HTTP download)
ExodeUICanvas(bexodeBytes: rawBytes)

// 2. From raw .exode JSON string
ExodeUICanvas(artboardJson: jsonString)

// 3. From decoded Map
ExodeUICanvas(artboard: artboardMap)

// 4. From JSON asset bundle
ExodeUICanvas(exodeAsset: 'assets/scene.json')

๐ŸŽฎ Controller API #

Control playback, fire triggers, inspect inputs, or modify charts dynamically using ExodeUICanvasController:

final controller = ExodeUICanvasController();

// Pass to ExodeUICanvas
ExodeUICanvas(
  bexodeAsset: 'assets/card.bexode',
  controller: controller,
  autoPlay: false,
);

// All commands are safe and queue automatically until the artboard is ready
void onUserAction() async {
  // Playback
  await controller.play();
  await controller.pause();
  await controller.seek(1.5); // Seek to 1.5 seconds

  // Layout & Scaling
  await controller.setLayout(
    fit: ExodeFit.cover,
    alignment: ExodeAlignment.topCenter,
    layoutScaleFactor: 1.2,
  );

  // State Machine Variables
  controller.setInputBool('isHovered', true);
  controller.setInputNumber('score', 98.5);
  controller.setInputText('username', 'Alex');
  final currentScore = await controller.getInput('score');

  // Interactive Triggers
  controller.fireTrigger('onSuccessPulse');

  // Dynamic Chart & Component Updates
  controller.updateGraphData('mainGraph', [10, 25, 40, 80]);
  controller.setDropdownOptions('citySelect', ['New York', 'London', 'Tokyo']);

  // External Scroll Synchronization
  controller.handleScroll(0, 120.0);
}

๐Ÿ”Š Audio #

Timeline clips play with their animations and Play Sound interactions play on events, with no setup needed. From Dart:

controller.playSound('Click', volume: 0.6, pitchVariance: 1);
controller.stopSound();
controller.setAudioMuted(true);   // e.g. your app's sound toggle
controller.setAudioVolume(0.5);

On Android, audio plays immediately. On iOS, WebKit starts audio after the first tap on the canvas.

๐ŸŽ›๏ธ Responsive Fit Modes (ExodeFit) #

Control how vector scenes adapt to different aspect ratios:

Mode Behavior
ExodeFit.contain Scales uniformly to fit entirely inside container without cropping.
ExodeFit.cover Covers container entirely, maintaining aspect ratio and cropping excess.
ExodeFit.fill Stretches to fill container dimensions exactly.
ExodeFit.fitWidth Scales to match width; allows vertical overflow.
ExodeFit.fitHeight Scales to match height; allows horizontal overflow.
ExodeFit.none 1:1 pixel rendering with no scaling applied.
ExodeFit.scaleDown Scales down if container is smaller; never scales up.
ExodeFit.layout Activates ExodeUI auto-layout engine for flex container reflow.

๐Ÿ’ก Comprehensive Callbacks #

Listen to state changes, component events, and custom listeners:

ExodeUICanvas(
  bexodeAsset: 'assets/dashboard.bexode',
  onReady: (controller) => debugPrint('Canvas initialized'),
  onTrigger: (trigger, anim) => debugPrint('Trigger: $trigger -> $anim'),
  onInputUpdate: (values) => debugPrint('Inputs changed: $values'),
  onToggle: (name, checked) => debugPrint('Toggle $name: $checked'),
  onInputChange: (name, text) => debugPrint('Text input $name: $text'),
  onButtonClick: (name, objectId) => debugPrint('Clicked: $name ($objectId)'),
  onGraphPointClick: (point) => debugPrint('Clicked point: $point'),
  onLogicUpdate: (state) => debugPrint('Logic state update: $state'),
  callbacks: {
    // Custom state machine listener name
    'onCelebrationEnd': (name, args) => showConfetti(),
  },
)

๐Ÿงช Testing & Example App #

A complete runnable example is available in the example/ directory:

cd example
flutter create --platforms=ios,android,macos .
flutter pub get
flutter run

To run end-to-end integration tests on a real macOS or iOS device:

flutter test integration_test -d macos

๐Ÿ’ก Overcoming Native Boundaries & Best Practices #

1. Flutter RepaintBoundary & Shader Masking #

Because ExodeUI renders in a hardware-accelerated canvas, you can capture live frames into Flutter's native widget/layer tree at any time using controller.captureImage():

final pngBytes = await controller.captureImage();
if (pngBytes != null) {
  // Convert to Flutter native Image widget
  final image = Image.memory(pngBytes);

  // Apply native Flutter ShaderMask, ColorFilter, or RepaintBoundary
  ShaderMask(
    shaderCallback: (bounds) => myGradient.createShader(bounds),
    child: image,
  );
}

2. App Size & Compression #

While the uncompressed JavaScript engine is ~2.0 MB, it compresses down to ~750 KB in production (.apk, .ipa, or macOS bundle) using standard gzip/brotli packaging.

3. Bypassing Mobile WebView CORS Restrictions #

If your artboards fetch live dynamic data from third-party APIs:

  • Recommended: Bundle the data directly in the .bexode binary payload at export time.
  • Dynamic APIs: Fetch data via Flutter's native http package (which is not subject to WebView browser CORS policies) and inject the payload into the artboard dynamically:
    final response = await http.get(Uri.parse('https://api.example.com/data'));
    controller.setInput('apiData', jsonDecode(response.body));
    


๐Ÿท๏ธ Keywords & Topics #

animation โ€ข motion โ€ข flutter โ€ข exodeui โ€ข vector-graphics โ€ข physics โ€ข rapier โ€ข canvas โ€ข state-machine โ€ข interactive โ€ข micro-interactions โ€ข rive-alternative โ€ข lottie-alternative โ€ข bexode โ€ข ui-design โ€ข figma-to-flutter


๐Ÿ“„ License #

Distributed under the MIT License. See LICENSE for more information. Copyright ยฉ 2026 ExodeUI. All rights reserved.

1
likes
150
points
411
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

Official Flutter runtime for the ExodeUI animation engine. Renders .exode and .bexode artboards with physics, state machines, chart components and interactivity.

Homepage
Repository (GitHub)
View/report issues

Topics

#animation #motion #design #interactive #canvas

License

MIT (license)

Dependencies

flutter, webview_flutter, webview_flutter_android

More

Packages that depend on exodeui_flutter