Không có mô tả

lfabl d9499ab098 Merge branch 'release/1.5.0-pre-alpha.7' 1 tuần trước cách đây
.agents 162095e9b6 Feature: Tooltip start. 2 tuần trước cách đây
.github 438d85b367 X: 1. 3 tuần trước cách đây
.vscode 0a5f90128d Feature: eslint features and CRLF updated. 2 tuần trước cách đây
.yarn d1faf40768 First commit. 5 tháng trước cách đây
bin cf63415c5b Bubgix: Auto install problems fixed. 1 tuần trước cách đây
eslint-local-rules 51e2c49445 Refactor: x lint fix. 2 tuần trước cách đây
example 23a4e6293b Bugfix: Prformance optimization provided. 1 tuần trước cách đây
src 1bb48c1e82 Bugfix: Toast and Snackbar freeze problem fixed. 1 tuần trước cách đây
.editorconfig 0a5f90128d Feature: eslint features and CRLF updated. 2 tuần trước cách đây
.gitattributes 162095e9b6 Feature: Tooltip start. 2 tuần trước cách đây
.gitignore 6ff1922f2e Feature: web build added. 1 tháng trước cách đây
.npmignore 6ff1922f2e Feature: web build added. 1 tháng trước cách đây
.nvmrc d1faf40768 First commit. 5 tháng trước cách đây
.watchmanconfig d1faf40768 First commit. 5 tháng trước cách đây
.yarnrc.yml d9be4fc8ba Feature: monorepo structure completed. 1 tháng trước cách đây
CODE_OF_CONDUCT.md d1faf40768 First commit. 5 tháng trước cách đây
CONTRIBUTING.md d1faf40768 First commit. 5 tháng trước cách đây
LICENSE d1faf40768 First commit. 5 tháng trước cách đây
README.md 7ddf4ee4bd Feature: README and installation guide completed. 1 tuần trước cách đây
TODO.md 6739bbd8e2 Bugfix: General type problems fixed. 2 tuần trước cách đây
babel.config.js 4a4a0f9438 Bugfix: General lint problems fixed. 2 tuần trước cách đây
eslint.config.mjs aa735a6692 Feature: Auto installer system added. 1 tuần trước cách đây
metro-config.js aa735a6692 Feature: Auto installer system added. 1 tuần trước cách đây
package.json cd9e4f4139 Release: v1.5.0-pre-alpha.7 1 tuần trước cách đây
react-native.config.js 8aee1621be Bugfix: rn assets problem fixed. 2 tháng trước cách đây
tsconfig.build.json d1faf40768 First commit. 5 tháng trước cách đây
tsconfig.json cf63415c5b Bubgix: Auto install problems fixed. 1 tuần trước cách đây
turbo.json 8368a4d8a5 Refactor: File structure updated. 1 tháng trước cách đây
version.mjs 8368a4d8a5 Refactor: File structure updated. 1 tháng trước cách đây
webpack-config.js aea1925b5b Bugfix: auto webpack problems fixed. 1 tuần trước cách đây
yarn.lock 2aa3561169 Bugfix: UserShortcot new variant added. 1 tuần trước cách đây

README.md

NİBGAT® | NCore - Mobile

The NCore, NİBGAT® UI - Kit. The NİBGAT®'s UI / Component Library.

🛠 Tooling & Environment Setup (Optional)

NCore UI Kit provides built-in configuration tools to maintain standard coding guidelines and ensure seamless integration across NİBGAT projects.

1. Type & Lint Configuration (Optional)

If you want to use the exact same ESLint rules, TypeScript configs, and VSCode settings used in NCore UI Kit, run the type-kit command in your project root:

npx ncore-type-kit

This command safely merges .vscode/, eslint.config.mjs, eslint-local-rules/, and tsconfig.json (preserves your existing include/exclude options) to your project.

2. Auto Configuration for Webpack & Metro

To automatically inject NCore UI Kit plugins into your existing webpack.config.js and metro.config.js, you can run:

npx ncore-setup

If you only want to configure one specific platform, use:

npx ncore-setup-web     # Only updates webpack.config.js
npx ncore-setup-mobile  # Only updates metro.config.js

3. Manual Webpack Configuration (React Native Web)

When building a web project with React Native Web, you have two options:

Option A: Default NCore Webpack Config (Zero-config) Use this if you are starting a new web project and want a ready-to-use configuration.

// webpack.config.js
const path = require("path");
const HtmlWebpackPlugin = require("html-webpack-plugin");
const ESLintPlugin = require("eslint-webpack-plugin");
const CopyPlugin = require("copy-webpack-plugin");
const webpack = require("webpack");
const { createDefaultWebpackConfig } = require("ncore-ui-kit/webpack-config");

module.exports = createDefaultWebpackConfig({
    appDirectory: path.resolve(__dirname, "./"),
    HtmlWebpackPlugin,
    ESLintPlugin,
    CopyPlugin,
    webpack
});

Option B: Wrap your existing Webpack config If you already have a complex webpack config, you can wrap it to inject necessary polyfills and aliases.

// webpack.config.js
const { withNCoreUIKitWebpack } = require("ncore-ui-kit/webpack-config");
const webpack = require("webpack");

let config = {
    // ... your existing config
};

module.exports = withNCoreUIKitWebpack(config, webpack);

4. Manual Metro Configuration (React Native Mobile)

If you did not use npx ncore-setup and are using this library in a React Native or Expo mobile project, you must manually update your metro.config.js to include the required Node.js core module polyfills (crypto, process, stream).

For Expo Projects:

// metro.config.js
const { getDefaultConfig } = require("expo/metro-config");
const { withNCoreUIKit } = require("ncore-ui-kit/metro-config");

const config = getDefaultConfig(__dirname);
module.exports = withNCoreUIKit(config);

For Bare React Native Projects (CLI):

// metro.config.js
const { getDefaultConfig } = require("@react-native/metro-config");
const { withNCoreUIKit } = require("ncore-ui-kit/metro-config");

const config = getDefaultConfig(__dirname);
module.exports = withNCoreUIKit(config);

Usage

useEffect(() => {
    NCoreUIKitMenu.load({
        siteLogoProps: {
            imageUrl: "https://www.nibgat.com/assets/images/logo.png",
            onPress: () => {
                navigation.navigate("Home");
            },
            imageProps: {
                resizeMode: "stretch"
            },
            imageSpace: "spacingLg",
            isWorkWithAction: true,
            subTitle: "Core Tech",
            title: "NİBGAT®"
        },
        renderFooter: () => {
            return <View
                style={{
                    padding: spaces.spacingMd,
                    flexDirection: "row",
                    alignItems: "center"
                }}
            >
                <View
                    style={{
                        marginRight: spaces.spacingSm,
                        justifyContent: "center",
                        flexDirection: "row",
                        alignItems: "center"
                    }}
                >
                    <Text
                        variant="labelLargeSize"
                    >
                        Palet:
                    </Text>
                    <PaletteSwitcher/>
                </View>
                <View
                    style={{
                        justifyContent: "center",
                        flexDirection: "row",
                        alignItems: "center"
                    }}
                >
                    <Text
                        variant="labelLargeSize"
                    >
                        Tema:
                    </Text>
                    <ThemeSwitcher/>
                </View>
            </View>;
        },
        isAutoClosed: true,
        buttons: [
            {
                redirectMain: "Home",
                isCollapsible: true,
                title: "Ana Sayfa",
                icon: ({
                    color
                }) => <HomeIcon
                    color={colors.content.icon[color]}
                />,
                subButtons: [
                    {
                        title: "Text",
                        redirectMain: "TextPage"
                    }
                ]
            },
            {
                redirectMain: "Text",
                isCollapsible: true,
                title: "Deneme",
                icon: ({
                    color
                }) => <HomeIcon
                    color={colors.content.icon[color]}
                />,
                subButtons: [
                    {
                        title: "Noliii",
                        redirectMain: "Home"
                    }
                ]
            },
            {
                title: "Text",
                redirectMain: "TextPage"
            }
        ],
        navigation: navigation as unknown as NCoreUIKit.Navigation,
        id: "test"
    });