From fbfe4cb0a701a9a0e2a7e3d59c62ab8c29f307a3 Mon Sep 17 00:00:00 2001 From: nielsr98 <54564567+nielsr98@users.noreply.github.com> Date: Wed, 5 Aug 2020 15:54:21 -0400 Subject: [PATCH] feat(cdk-experimental/combobox): created combobox file skeleton. (#20185) --- .github/CODEOWNERS | 1 + src/cdk-experimental/combobox/BUILD.bazel | 12 +++++++++++ .../combobox/combobox-module.ts | 18 +++++++++++++++++ .../combobox/combobox-panel.ts | 17 ++++++++++++++++ src/cdk-experimental/combobox/combobox.ts | 20 +++++++++++++++++++ src/cdk-experimental/combobox/index.ts | 9 +++++++++ src/cdk-experimental/combobox/public-api.ts | 11 ++++++++++ src/cdk-experimental/config.bzl | 1 + 8 files changed, 89 insertions(+) create mode 100644 src/cdk-experimental/combobox/BUILD.bazel create mode 100644 src/cdk-experimental/combobox/combobox-module.ts create mode 100644 src/cdk-experimental/combobox/combobox-panel.ts create mode 100644 src/cdk-experimental/combobox/combobox.ts create mode 100644 src/cdk-experimental/combobox/index.ts create mode 100644 src/cdk-experimental/combobox/public-api.ts diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 696b7dac3526..4170974ada74 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -126,6 +126,7 @@ # CDK experimental package /src/cdk-experimental/* @jelbourn /src/cdk-experimental/column-resize/** @kseamon @andrewseguin +/src/cdk-experimental/combobox/** @nielsr98 @jelbourn /src/cdk-experimental/dialog/** @jelbourn @crisbeto /src/cdk-experimental/menu/** @jelbourn @andy9775 /src/cdk-experimental/popover-edit/** @kseamon @andrewseguin diff --git a/src/cdk-experimental/combobox/BUILD.bazel b/src/cdk-experimental/combobox/BUILD.bazel new file mode 100644 index 000000000000..083668385f74 --- /dev/null +++ b/src/cdk-experimental/combobox/BUILD.bazel @@ -0,0 +1,12 @@ +load("//tools:defaults.bzl", "ng_module") + +package(default_visibility = ["//visibility:public"]) + +ng_module( + name = "combobox", + srcs = glob( + ["**/*.ts"], + exclude = ["**/*.spec.ts"], + ), + module_name = "@angular/cdk-experimental/combobox", +) diff --git a/src/cdk-experimental/combobox/combobox-module.ts b/src/cdk-experimental/combobox/combobox-module.ts new file mode 100644 index 000000000000..c6827254673c --- /dev/null +++ b/src/cdk-experimental/combobox/combobox-module.ts @@ -0,0 +1,18 @@ +/** + * @license + * Copyright Google LLC All Rights Reserved. + * + * Use of this source code is governed by an MIT-style license that can be + * found in the LICENSE file at https://angular.io/license + */ + +import {NgModule} from '@angular/core'; +import {CdkCombobox} from './combobox'; +import {CdkComboboxPanel} from './combobox-panel'; + +const EXPORTED_DECLARATIONS = [CdkCombobox, CdkComboboxPanel]; +@NgModule({ + exports: EXPORTED_DECLARATIONS, + declarations: EXPORTED_DECLARATIONS, +}) +export class CdkComboboxModule {} diff --git a/src/cdk-experimental/combobox/combobox-panel.ts b/src/cdk-experimental/combobox/combobox-panel.ts new file mode 100644 index 000000000000..7583db2ba574 --- /dev/null +++ b/src/cdk-experimental/combobox/combobox-panel.ts @@ -0,0 +1,17 @@ +/** + * @license + * Copyright Google LLC All Rights Reserved. + * + * Use of this source code is governed by an MIT-style license that can be + * found in the LICENSE file at https://angular.io/license + */ + +import {Directive} from '@angular/core'; + +@Directive({ + selector: 'ng-template[cdkComboboxPanel]', + exportAs: 'cdkComboboxPanel', +}) +export class CdkComboboxPanel { + +} diff --git a/src/cdk-experimental/combobox/combobox.ts b/src/cdk-experimental/combobox/combobox.ts new file mode 100644 index 000000000000..4577c856a256 --- /dev/null +++ b/src/cdk-experimental/combobox/combobox.ts @@ -0,0 +1,20 @@ +/** + * @license + * Copyright Google LLC All Rights Reserved. + * + * Use of this source code is governed by an MIT-style license that can be + * found in the LICENSE file at https://angular.io/license + */ + +import {Directive} from '@angular/core'; + +@Directive({ + selector: '[cdkCombobox]', + exportAs: 'cdkCombobox', + host: { + 'role': 'combobox' + } +}) +export class CdkCombobox { + +} diff --git a/src/cdk-experimental/combobox/index.ts b/src/cdk-experimental/combobox/index.ts new file mode 100644 index 000000000000..676ca90f1ffa --- /dev/null +++ b/src/cdk-experimental/combobox/index.ts @@ -0,0 +1,9 @@ +/** + * @license + * Copyright Google LLC All Rights Reserved. + * + * Use of this source code is governed by an MIT-style license that can be + * found in the LICENSE file at https://angular.io/license + */ + +export * from './public-api'; diff --git a/src/cdk-experimental/combobox/public-api.ts b/src/cdk-experimental/combobox/public-api.ts new file mode 100644 index 000000000000..dadf849fdc9b --- /dev/null +++ b/src/cdk-experimental/combobox/public-api.ts @@ -0,0 +1,11 @@ +/** + * @license + * Copyright Google LLC All Rights Reserved. + * + * Use of this source code is governed by an MIT-style license that can be + * found in the LICENSE file at https://angular.io/license + */ + +export * from './combobox'; +export * from './combobox-panel'; +export * from './combobox-module'; diff --git a/src/cdk-experimental/config.bzl b/src/cdk-experimental/config.bzl index e89fb9e57040..ca3ffb5f404f 100644 --- a/src/cdk-experimental/config.bzl +++ b/src/cdk-experimental/config.bzl @@ -1,6 +1,7 @@ # List of all entry-points of the Angular cdk-experimental package. CDK_EXPERIMENTAL_ENTRYPOINTS = [ "column-resize", + "combobox", "dialog", "menu", "listbox",