Skip to content

Commit 6a66dd6

Browse files
committed
Add api-graph
1 parent ddc74c4 commit 6a66dd6

15 files changed

Lines changed: 147 additions & 2 deletions

lint-staged.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ module.exports = {
1212
'**/*.md': prettierMarkdown,
1313
'packages/**/*.css': ['npm run precommit:biome'],
1414
'packages/api/src/**/*.{mjs,js,ts,tsx}': ['npm run precommit:eslint:api'],
15+
'packages/api-graph/src/**/*.{mjs,js,ts,tsx}': ['npm run precommit:eslint:api-graph'],
1516
'packages/api-middleware/src/**/*.{mjs,js,ts,tsx}': ['npm run precommit:eslint:api-middleware'],
1617
'packages/base/src/**/*.{mjs,js,ts,tsx}': ['npm run precommit:eslint:base'],
1718
'packages/bundle/src/**/*.{mjs,js,ts,tsx}': ['npm run precommit:eslint:bundle'],

package-lock.json

Lines changed: 20 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"./packages/styles",
2828
"./packages/support/cldr-data-downloader",
2929
"./packages/support/cldr-data",
30+
"./packages/api-graph",
3031
"./packages/api-middleware",
3132
"./packages/api",
3233
"./packages/isomorphic-react",
@@ -72,6 +73,7 @@
7273
"precommit": "npm run precommit --if-present --workspaces",
7374
"precommit:biome": "npm run biome -- --no-errors-on-unmatched",
7475
"precommit:eslint:api": "cd packages && cd api && npm run precommit:eslint",
76+
"precommit:eslint:api-graph": "cd packages && cd api-graph && npm run precommit:eslint",
7577
"precommit:eslint:api-middleware": "cd packages && cd api-middleware && npm run precommit:eslint",
7678
"precommit:eslint:base": "cd packages && cd base && npm run precommit:eslint",
7779
"precommit:eslint:bundle": "cd packages && cd bundle && npm run precommit:eslint",
@@ -106,6 +108,7 @@
106108
"precommit:eslint:web-server": "cd packages && cd test && cd web-server && npm run precommit:eslint",
107109
"precommit:typecheck": "concurrently \"npm:precommit:typecheck:*\"",
108110
"precommit:typecheck:api": "cd packages && cd api && npm run precommit:typecheck",
111+
"precommit:typecheck:api-graph": "cd packages && cd api-graph && npm run precommit:typecheck",
109112
"precommit:typecheck:api-middleware": "cd packages && cd api-middleware && npm run precommit:typecheck",
110113
"precommit:typecheck:base": "cd packages && cd base && npm run precommit:typecheck",
111114
"precommit:typecheck:bundle": "cd packages && cd bundle && npm run precommit:typecheck",
@@ -132,6 +135,7 @@
132135
"prepare": "husky",
133136
"start": "cross-env NODE_OPTIONS=--no-deprecation concurrently --kill-others --prefix-colors \"auto\" \"npm:start:*\"",
134137
"start:api": "cd packages && cd api && npm start",
138+
"start:api-graph": "cd packages && cd api-graph && npm start",
135139
"start:api-middleware": "cd packages && cd api-middleware && npm start",
136140
"start:base": "cd packages && cd base && npm start",
137141
"start:bundle": "cd packages && cd bundle && npm start",

packages/api-graph/.eslintrc.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
extends:
2+
- ../../.eslintrc.production.yml
3+
- ../../.eslintrc.react.yml
4+
5+
# This package is compatible with web browser.
6+
env:
7+
browser: true
8+
9+
rules:
10+
# React functional component is better in function style than arrow style.
11+
prefer-arrow-callback: off
12+
13+
# React already deprecated default props.
14+
react/require-default-props: off

packages/api-graph/.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
/*.tgz
2+
/dist/
3+
/node_modules/
4+
/tsup.config.bundled_*.mjs

packages/api-graph/README.md

Whitespace-only changes.

packages/api-graph/package.json

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
{
2+
"name": "@msinternal/botframework-webchat-api-graph",
3+
"version": "0.0.0-0",
4+
"description": "botframework-webchat-api/graph package",
5+
"main": "./dist/botframework-webchat-api-graph.js",
6+
"types": "./dist/botframework-webchat-api-graph.d.ts",
7+
"exports": {
8+
".": {
9+
"import": {
10+
"types": "./dist/botframework-webchat-api-graph.d.mts",
11+
"default": "./dist/botframework-webchat-api-graph.mjs"
12+
},
13+
"require": {
14+
"types": "./dist/botframework-webchat-api-graph.d.ts",
15+
"default": "./dist/botframework-webchat-api-graph.js"
16+
}
17+
}
18+
},
19+
"author": "Microsoft Corporation",
20+
"license": "MIT",
21+
"private": true,
22+
"repository": {
23+
"type": "git",
24+
"url": "git+https://github.com/microsoft/BotFramework-WebChat.git"
25+
},
26+
"bugs": {
27+
"url": "https://github.com/microsoft/BotFramework-WebChat/issues"
28+
},
29+
"files": [
30+
"./dist/**/*",
31+
"./src/**/*",
32+
"*.js"
33+
],
34+
"homepage": "https://github.com/microsoft/BotFramework-WebChat/tree/main/packages/api-graph#readme",
35+
"scripts": {
36+
"build": "npm run --if-present build:pre && npm run build:run && npm run --if-present build:post",
37+
"build:pre": "npm run build:pre:local-dependencies && npm run build:pre:watch",
38+
"build:pre:local-dependencies": "../../scripts/npm/build-local-dependencies.sh",
39+
"build:pre:watch": "../../scripts/npm/build-watch.sh",
40+
"build:run": "tsup",
41+
"bump": "npm run bump:prod && npm run bump:dev && npm run bump:peer && (npm audit fix || exit 0)",
42+
"bump:dev": "../../scripts/npm/bump-dev.sh",
43+
"bump:peer": "../../scripts/npm/bump-peer.sh",
44+
"bump:prod": "../../scripts/npm/bump-prod.sh",
45+
"eslint": "npm run precommit",
46+
"postversion": "node ../../scripts/npm/postversion.sh",
47+
"precommit": "npm run precommit:eslint -- src && npm run precommit:typecheck",
48+
"precommit:eslint": "../../node_modules/.bin/eslint --report-unused-disable-directives --max-warnings 0",
49+
"precommit:typecheck": "tsc --project ./src --emitDeclarationOnly false --esModuleInterop true --noEmit --pretty false",
50+
"preversion": "node ../../scripts/npm/preversion.sh",
51+
"start": "../../scripts/npm/notify-build.sh \"src\""
52+
},
53+
"pinDependencies": {},
54+
"localDependencies": {},
55+
"devDependencies": {
56+
"typescript": "^5.7.3"
57+
},
58+
"peerDependencies": {
59+
"react": ">= 16.8.6"
60+
},
61+
"dependencies": {
62+
"valibot": "1.1.0"
63+
}
64+
}

packages/api-graph/src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { default as useNodeObject } from './private/useNodeObject';
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// Related to https://www.w3.org/TR/json-ld11/#node-objects.
2+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
3+
export default function useNodeObject(_id: string): undefined {
4+
return undefined;
5+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": "@msinternal/botframework-webchat-tsconfig/current"
3+
}

0 commit comments

Comments
 (0)