diff --git a/README.md b/README.md
index be4bee6..c6c0ff3 100644
--- a/README.md
+++ b/README.md
@@ -2,14 +2,7 @@
react dropdown component
-[![NPM version][npm-image]][npm-url]
-[![build status][travis-image]][travis-url]
-[![Test coverage][coveralls-image]][coveralls-url]
-[![Dependencies][david-image]][david-url]
-[![DevDependencies][david-dev-image]][david-dev-url]
-[![npm download][download-image]][download-url]
-[![bundle size][bundlephobia-image]][bundlephobia-url]
-[![dumi][dumi-image]][dumi-url]
+[![NPM version][npm-image]][npm-url] [![build status][travis-image]][travis-url] [![Test coverage][coveralls-image]][coveralls-url] [![Dependencies][david-image]][david-url] [![DevDependencies][david-dev-image]][david-dev-url] [![npm download][download-image]][download-url] [![bundle size][bundlephobia-image]][bundlephobia-url] [![dumi][dumi-image]][dumi-url]
[npm-image]: http://img.shields.io/npm/v/rc-dropdown.svg?style=flat-square
[npm-url]: http://npmjs.org/package/rc-dropdown
@@ -95,7 +88,7 @@ var Dropdown = require('rc-dropdown');
placement |
String |
bottomLeft |
- Position of menu item. There are: topLeft, topCenter, topRight, bottomLeft, bottomCenter, bottomRight |
+ Position of menu item. There are: top, topCenter, topRight, bottomLeft, bottom, bottomRight |
| onVisibleChange |
@@ -166,7 +159,6 @@ npm run coverage
open coverage/ dir
-
## License
rc-dropdown is released under the MIT license.
diff --git a/src/placements.ts b/src/placements.ts
index 6159e27..f3fa8f5 100644
--- a/src/placements.ts
+++ b/src/placements.ts
@@ -1,9 +1,9 @@
const autoAdjustOverflow = {
adjustX: 1,
adjustY: 1,
-}
+};
-const targetOffset = [0, 0]
+const targetOffset = [0, 0];
const placements = {
topLeft: {
@@ -12,7 +12,7 @@ const placements = {
offset: [0, -4],
targetOffset,
},
- topCenter: {
+ top: {
points: ['bc', 'tc'],
overflow: autoAdjustOverflow,
offset: [0, -4],
@@ -30,7 +30,7 @@ const placements = {
offset: [0, 4],
targetOffset,
},
- bottomCenter: {
+ bottom: {
points: ['tc', 'bc'],
overflow: autoAdjustOverflow,
offset: [0, 4],
@@ -42,6 +42,6 @@ const placements = {
offset: [0, 4],
targetOffset,
},
-}
+};
-export default placements
+export default placements;